@mideind/netskrafl-react 3.4.3 → 3.4.5

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.
@@ -405,6 +405,7 @@ div.netskrafl-container {
405
405
  --board-cell-border-color: white;
406
406
  --board-tile-line-height-lg: 30px;
407
407
  --tab-background: #f3f3f6;
408
+ --tab-active-background: var(--container-bg-color);
408
409
  --rack-slot-background: #f3f3f6;
409
410
  --header-background: #dde1e4;
410
411
  --two-letter-background: hsl(from var(--malfridur-green) h 20% 90%);
@@ -418,6 +419,12 @@ div.netskrafl-container {
418
419
  --dialog-overlay-opacity: 50%;
419
420
  --tilecount-background: white;
420
421
  --chat-accent-color: var(--header-color);
422
+ --chat-local-background: color-mix(in oklch, var(--human-color) 20%, white);
423
+ --chat-remote-background: color-mix(
424
+ in oklch,
425
+ var(--autoplayer-color) 25%,
426
+ white
427
+ );
421
428
  --board-help-background: var(--board-background);
422
429
  --button-background: var(--board-background);
423
430
  --oddlist-background: var(--board-background);
@@ -479,6 +486,16 @@ div.netskrafl-container {
479
486
  --dialog-overlay-opacity: 72%;
480
487
  --tilecount-background: var(--color-neutral-400);
481
488
  --chat-accent-color: var(--color-secondary-500);
489
+ --chat-local-background: color-mix(
490
+ in oklch,
491
+ var(--human-color) 70%,
492
+ var(--color-neutral-100)
493
+ );
494
+ --chat-remote-background: color-mix(
495
+ in oklch,
496
+ var(--autoplayer-color) 80%,
497
+ var(--color-neutral-100)
498
+ );
482
499
  --board-help-background: var(--board-background);
483
500
  --button-background: var(--color-neutral-300);
484
501
  --chat-background: color-mix(
@@ -494,6 +511,11 @@ div.netskrafl-container {
494
511
  var(--color-neutral-200) 50%,
495
512
  var(--color-neutral-300)
496
513
  );
514
+ --tab-active-background: color-mix(
515
+ in oklch,
516
+ var(--color-neutral-200) 50%,
517
+ var(--color-neutral-300)
518
+ );
497
519
  --rack-slot-background: var(--color-neutral-100);
498
520
  --header-background: color-mix(
499
521
  in oklch,
@@ -503,7 +525,11 @@ div.netskrafl-container {
503
525
  --oddlist-background: var(--board-background);
504
526
  --evenlist-background: var(--color-neutral-50);
505
527
  --tab-movelist-background: var(--color-neutral-300);
506
- --list-header-background: var(--color-neutral-200);
528
+ --list-header-background: color-mix(
529
+ in oklch,
530
+ var(--color-malfridurPalette-200) 40%,
531
+ var(--color-neutral-200)
532
+ );
507
533
  --toggler-background: var(--color-neutral-300);
508
534
  --toggler-border: var(--color-neutral-500);
509
535
 
@@ -520,7 +546,7 @@ div.netskrafl-container {
520
546
  /* Text, links and header colors - lightened for dark backgrounds */
521
547
  --header-color: var(--color-secondary-300);
522
548
  --header-hover-color: var(--color-secondary-400);
523
- --humangrad-color: var(--color-secondary-500);
549
+ --humangrad-color: var(--color-secondary-600);
524
550
  --scorewrapper-background: var(--color-secondary-300);
525
551
  --player-btn-color: var(--color-neutral-900);
526
552
  --tab-text-color: var(--foreground);
@@ -634,10 +660,13 @@ div.netskrafl-container.legacy-colors {
634
660
  /* Container and UI backgrounds */
635
661
  --container-bg-color: #fff1dc;
636
662
  --tab-background: #f4f4f4;
663
+ --tab-active-background: var(--container-bg-color);
637
664
  --rack-slot-background: #b5bdc4;
638
665
  --stats-item-background: #ece8e0;
639
666
  --header-background: #d6d1c4;
640
667
  --chat-background: #f4cda0;
668
+ --chat-local-background: var(--board-background);
669
+ --chat-remote-background: var(--logo-primary-light);
641
670
  --light-header-color: #fcf0cd;
642
671
  --list-header-background: #fcf0cd;
643
672
  --two-letter-background: #b9dbcf;
@@ -994,10 +1023,10 @@ div.netskrafl-container.legacy-colors div.chall-time.selected {
994
1023
  background-color: var(--human-color);
995
1024
  }
996
1025
 
997
- /* Help tabs links - use darker blue for better readability on white */
1026
+ /* Help tabs links - use link-hover-color for the retro/legacy theme */
998
1027
 
999
1028
  div.netskrafl-container.legacy-colors div.help-tabs .ui-tabs-panel a:link,div.netskrafl-container.legacy-colors div.help-tabs .ui-tabs-panel a:visited {
1000
- color: #2266aa;
1029
+ color: var(--link-hover-color);
1001
1030
  }
1002
1031
 
1003
1032
  div.netskrafl-container.legacy-colors table.bag-content tr td {
@@ -1203,7 +1232,7 @@ div.netskrafl-container {
1203
1232
  .netskrafl-container .ui-tabs .ui-tabs-nav li.ui-tabs-active {
1204
1233
  margin-bottom: -1px;
1205
1234
  padding-bottom: 0px;
1206
- background-color: var(--container-bg-color);
1235
+ background-color: var(--tab-active-background);
1207
1236
  }
1208
1237
 
1209
1238
  .netskrafl-container .ui-tabs .ui-tabs-panel {
@@ -1213,7 +1242,7 @@ div.netskrafl-container {
1213
1242
  padding-right: 6px;
1214
1243
  padding-top: 4px;
1215
1244
  padding-bottom: 4px;
1216
- background-color: var(--container-bg-color);
1245
+ background-color: var(--tab-active-background);
1217
1246
  }
1218
1247
 
1219
1248
  .netskrafl-container .ui-widget {
@@ -1283,13 +1312,13 @@ div.netskrafl-container {
1283
1312
 
1284
1313
  .netskrafl-container .ui-state-active,
1285
1314
  .netskrafl-container .ui-widget-content .ui-state-active {
1286
- background-color: var(--container-bg-color);
1315
+ background-color: var(--tab-active-background);
1287
1316
  font-weight: bold;
1288
1317
  color: var(--tab-active-text-color);
1289
1318
  }
1290
1319
 
1291
1320
  .netskrafl-container .ui-widget-header .ui-state-active {
1292
- background-color: var(--container-bg-color);
1321
+ background-color: var(--tab-active-background);
1293
1322
  font-weight: bold;
1294
1323
  color: var(--tab-active-text-color);
1295
1324
  }
@@ -1878,6 +1907,10 @@ div.netskrafl-tile.dragging.no-drop {
1878
1907
  border-color: oklch(58% 0.13 25);
1879
1908
  }
1880
1909
 
1910
+ [data-theme="dark"] input.userid::placeholder {
1911
+ color: var(--color-neutral-600);
1912
+ }
1913
+
1881
1914
  div.netskrafl-tile.dragging.legacy-colors {
1882
1915
  /* Legacy color scheme: hardcode values since CSS variables are out of
1883
1916
  scope when the tile is a child of the document body during dragging */
@@ -2690,7 +2723,7 @@ div.netskrafl-tile.dragging div.letterscore {
2690
2723
  top: 0;
2691
2724
  padding-top: 34px;
2692
2725
  left: 0;
2693
- height: 464px;
2726
+ height: 474px;
2694
2727
  width: 100%;
2695
2728
  font-size: 16px;
2696
2729
  line-height: 16px;
@@ -3446,6 +3479,7 @@ div.netskrafl-tile.dragging div.letterscore {
3446
3479
  display: inline-block;
3447
3480
  width: 140px;
3448
3481
  min-width: 140px;
3482
+ flex-shrink: 0;
3449
3483
  overflow: hidden;
3450
3484
  }
3451
3485
 
@@ -3465,6 +3499,7 @@ div.netskrafl-tile.dragging div.letterscore {
3465
3499
  display: inline-block;
3466
3500
  width: 400px;
3467
3501
  min-width: 400px;
3502
+ flex-shrink: 0;
3468
3503
  overflow: hidden;
3469
3504
  }
3470
3505
 
@@ -3483,6 +3518,7 @@ div.netskrafl-tile.dragging div.letterscore {
3483
3518
  display: inline-block;
3484
3519
  width: 40px;
3485
3520
  max-width: 40px;
3521
+ flex-shrink: 0;
3486
3522
  text-align: center;
3487
3523
  margin-right: 6px;
3488
3524
  }
@@ -3592,7 +3628,53 @@ div.netskrafl-tile.dragging div.letterscore {
3592
3628
  }
3593
3629
 
3594
3630
  .netskrafl-container div.user-cat#user-search {
3631
+ /* On mobile, show only the search icon; the input is hidden */
3632
+ display: block;
3633
+ position: absolute;
3634
+ top: 28px;
3635
+ right: 6px;
3636
+ background-color: var(--header-color);
3637
+ color: white;
3638
+ border-radius: 5px;
3639
+ padding: 1px;
3640
+ }
3641
+
3642
+ .netskrafl-container div.user-cat#user-search span.glyphicon-search {
3643
+ font-size: 20px;
3644
+ }
3645
+
3646
+ .netskrafl-container div.user-cat#user-search span:hover {
3647
+ /* Override the general hover style on mobile */
3648
+ color: white;
3649
+ background-color: transparent;
3650
+ }
3651
+
3652
+ .netskrafl-container div.user-cat#user-search input#search-id {
3653
+ /* Hidden on mobile until search is activated */
3595
3654
  display: none;
3655
+ color: var(--text-color);
3656
+ }
3657
+
3658
+ .netskrafl-container div.user-cat#user-search.search-active {
3659
+ /* Indicate active search mode via a different background color */
3660
+ background-color: var(--toggler-selected);
3661
+ }
3662
+
3663
+ .netskrafl-container div.user-cat#user-search.search-active input#search-id {
3664
+ /* When search is active on mobile, show the input anchored to the left,
3665
+ centered vertically within the headings area */
3666
+ display: inline-block;
3667
+ position: absolute;
3668
+ right: 52px;
3669
+ top: 50%;
3670
+ transform: translateY(-50%);
3671
+ width: calc(375px - 84px);
3672
+ }
3673
+
3674
+ .netskrafl-container div#initials:has(#user-search.search-active) #user-headings {
3675
+ /* Hide the category buttons when mobile search is active,
3676
+ but keep their layout space */
3677
+ visibility: hidden;
3596
3678
  }
3597
3679
 
3598
3680
  .netskrafl-container div#chall-form {
@@ -3822,12 +3904,13 @@ div.netskrafl-tile.dragging div.letterscore {
3822
3904
  top: 0;
3823
3905
  left: 0;
3824
3906
  width: 100%;
3907
+ /* Total height: 474px */
3825
3908
  height: 450px;
3909
+ padding-top: 12px;
3910
+ padding-bottom: 12px;
3826
3911
  background-color: var(--tab-games-background);
3827
3912
  overflow: auto;
3828
3913
  z-index: 2;
3829
- padding-top: 12px;
3830
- padding-bottom: 12px;
3831
3914
  border-radius: 4px 4px 0 0;
3832
3915
  }
3833
3916
 
@@ -4307,7 +4390,7 @@ div.highlight1.netskrafl-blanktile {
4307
4390
  top: 0px;
4308
4391
  left: 0px;
4309
4392
  width: 100%;
4310
- height: 466px;
4393
+ height: 474px;
4311
4394
  background-color: var(--chat-background);
4312
4395
  z-index: 1;
4313
4396
  border-radius: 4px 4px 0 0;
@@ -4356,11 +4439,11 @@ div.highlight1.netskrafl-blanktile {
4356
4439
  }
4357
4440
 
4358
4441
  .netskrafl-container div.chat-msg.local {
4359
- background-color: var(--board-background);
4442
+ background-color: var(--chat-local-background);
4360
4443
  }
4361
4444
 
4362
4445
  .netskrafl-container div.chat-msg.remote {
4363
- background-color: var(--logo-primary-light);
4446
+ background-color: var(--chat-remote-background);
4364
4447
  }
4365
4448
 
4366
4449
  .netskrafl-container div.chat-msg img {
@@ -5127,15 +5210,15 @@ div.highlight1.netskrafl-blanktile {
5127
5210
  padding: 6px 10px 4px 6px;
5128
5211
  margin: 0;
5129
5212
  z-index: 5;
5130
- color: #5699a5;
5131
- background-color: white;
5213
+ color: var(--tab-text-color);
5214
+ background-color: var(--header-color);
5132
5215
  border-radius: 5px;
5133
5216
  cursor: pointer;
5134
5217
  }
5135
5218
 
5136
5219
  .netskrafl-container div.userid:hover {
5137
- background-color: var(--humangrad-color);
5138
- color: white;
5220
+ background-color: var(--header-hover-color);
5221
+ color: var(--tab-text-color);
5139
5222
  }
5140
5223
 
5141
5224
  .netskrafl-container div.listitem {
@@ -5215,10 +5298,6 @@ div.highlight1.netskrafl-blanktile {
5215
5298
  vertical-align: middle;
5216
5299
  }
5217
5300
 
5218
- .netskrafl-container div.user-cat#user-search {
5219
- float: right;
5220
- }
5221
-
5222
5301
  .netskrafl-container div.user-cat span {
5223
5302
  font-size: 16px;
5224
5303
  cursor: pointer;
@@ -5244,6 +5323,7 @@ div.highlight1.netskrafl-blanktile {
5244
5323
  padding-top: 6px;
5245
5324
  padding-bottom: 6px;
5246
5325
  top: 0;
5326
+ left: 2px;
5247
5327
  }
5248
5328
 
5249
5329
  .netskrafl-container span.versus-cat span {
@@ -5472,7 +5552,7 @@ div.highlight1.netskrafl-blanktile {
5472
5552
  }
5473
5553
 
5474
5554
  .netskrafl-container #userlist span.glyphicon.glyphicon-star {
5475
- color: var(--header-color);
5555
+ color: var(--option-selected);
5476
5556
  }
5477
5557
 
5478
5558
  .netskrafl-container #userlist span.glyphicon.glyphicon-hand-right,
@@ -5531,8 +5611,10 @@ div.highlight1.netskrafl-blanktile {
5531
5611
  display: none;
5532
5612
  position: absolute;
5533
5613
  top: 220px;
5534
- left: 140px;
5535
- width: 600px;
5614
+ left: 50%;
5615
+ transform: translateX(-50%);
5616
+ width: max-content;
5617
+ max-width: 90%;
5536
5618
  z-index: 10;
5537
5619
  text-align: center;
5538
5620
  }
@@ -6546,9 +6628,14 @@ div.netskrafl-container input[type="checkbox"] {
6546
6628
  ========================================================================== */
6547
6629
 
6548
6630
  @media all and (min-width: 667px) and (max-width: 1023px) and (
6549
- orientation: landscape
6550
- ) {
6551
- /* Mobile screen, landscape mode (width >= 667px AND landscape orientation) */
6631
+ max-height: 667px
6632
+ ) and (orientation: landscape) {
6633
+ /* Mobile screens in landscape (width 667–1023px, max-height 667px, landscape orientation) */
6634
+ .netskrafl-container .ui-helper-reset {
6635
+ /* Controls the height of the tab row; 50px is too tall for limited
6636
+ vertical space in landscape */
6637
+ line-height: 40px;
6638
+ }
6552
6639
  div.netskrafl-container {
6553
6640
  container-type: inline-size;
6554
6641
  }
@@ -6621,8 +6708,10 @@ div.netskrafl-container input[type="checkbox"] {
6621
6708
  top: 8px;
6622
6709
  padding-top: 1px;
6623
6710
  background-color: transparent;
6624
- transform: scale(0.92);
6625
- transform: scale(clamp(0.92, calc((100dvh - 16px) / 408px), 1));
6711
+ /* 0.88 is the scale required on an iPhone SE to fit the board
6712
+ vertically */
6713
+ transform: scale(0.88);
6714
+ transform: scale(clamp(0.88, calc((100dvh - 16px) / 408px), 1));
6626
6715
  transform-origin: right top;
6627
6716
  }
6628
6717
  .netskrafl-container div.rightcol {
@@ -6743,15 +6832,29 @@ div.netskrafl-container input[type="checkbox"] {
6743
6832
  left: 90px;
6744
6833
  }
6745
6834
  .netskrafl-container div#own-stats {
6746
- height: 16px;
6835
+ height: 32px;
6836
+ margin-top: 6px;
6837
+ margin-bottom: 6px;
6838
+ }
6839
+ .netskrafl-container div.stats-fig {
6840
+ margin-top: 0;
6841
+ height: 22px;
6842
+ line-height: 22px;
6747
6843
  }
6748
6844
  .netskrafl-container p#own-best {
6749
6845
  left: auto;
6750
6846
  right: 6px;
6751
6847
  top: 0px;
6752
6848
  text-align: right;
6753
- font-size: 0.85em;
6754
- line-height: 1.4em;
6849
+ font-size: 13px;
6850
+ line-height: 17px;
6851
+ margin-top: 8px;
6852
+ }
6853
+ .netskrafl-container div#own-toggler {
6854
+ top: -2px;
6855
+ }
6856
+ .netskrafl-container div.toggler span.glyphicon {
6857
+ top: 2px;
6755
6858
  }
6756
6859
  .netskrafl-container div #chall-sent,
6757
6860
  .netskrafl-container div #chall-received {
@@ -6785,29 +6888,47 @@ div.netskrafl-container input[type="checkbox"] {
6785
6888
  }
6786
6889
  .netskrafl-container div#tabs > div[role="tabpanel"],
6787
6890
  .netskrafl-container div#main-tabs > div[role="tabpanel"] {
6788
- height: calc(100vh - 152px);
6789
- height: calc(100dvh - 152px);
6790
- max-height: 326px;
6891
+ height: calc(100vh - 142px);
6892
+ height: calc(100dvh - 142px);
6893
+ max-height: 336px;
6894
+ }
6895
+ .netskrafl-container div#initials {
6896
+ margin-top: 6px;
6897
+ margin-bottom: 6px;
6898
+ height: 32px;
6899
+ }
6900
+ .netskrafl-container div.user-cat#user-headings {
6901
+ line-height: 28px;
6902
+ }
6903
+ .netskrafl-container div.user-cat#user-search {
6904
+ top: 6px;
6905
+ }
6906
+ .netskrafl-container div.user-cat#user-search.search-active input#search-id {
6907
+ width: calc(667px - 84px);
6791
6908
  }
6792
6909
  .netskrafl-container div #userlist,
6793
6910
  .netskrafl-container div #elolist {
6794
- height: calc(100vh - 204px);
6795
- height: calc(100dvh - 204px);
6796
- max-height: 396px;
6911
+ height: calc(100vh - 180px);
6912
+ height: calc(100dvh - 180px);
6913
+ max-height: 420px;
6797
6914
  }
6798
6915
  .netskrafl-container div #gamelist {
6799
- height: calc(100vh - 150px);
6800
- height: calc(100dvh - 150px);
6801
- max-height: 468px;
6916
+ height: calc(100vh - 136px);
6917
+ height: calc(100dvh - 136px);
6918
+ max-height: 482px;
6802
6919
  }
6803
6920
  .netskrafl-container div #recentlist,
6804
6921
  .netskrafl-container div #usr-recent {
6805
- height: calc(100vh - 204px);
6806
- height: calc(100dvh - 204px);
6807
- max-height: 396px;
6922
+ height: calc(100vh - 180px);
6923
+ height: calc(100dvh - 180px);
6924
+ max-height: 420px;
6925
+ }
6926
+ .netskrafl-container span#numgames,
6927
+ .netskrafl-container span#numchallenges {
6928
+ margin-top: 12px;
6808
6929
  }
6809
6930
  .netskrafl-container div#elo-toggler {
6810
- top: 6px;
6931
+ top: 2px;
6811
6932
  }
6812
6933
  .netskrafl-container div#tabs-1 span.list-ts-short,
6813
6934
  .netskrafl-container div#tabs-1 span.list-manual,
@@ -8054,7 +8175,25 @@ div.netskrafl-container input[type="checkbox"] {
8054
8175
  line-height: 32px;
8055
8176
  }
8056
8177
  .netskrafl-container div.user-cat#user-search {
8057
- display: block;
8178
+ top: 18px;
8179
+ right: 22px;
8180
+ background-color: transparent;
8181
+ color: inherit;
8182
+ padding: 0;
8183
+ border-radius: 0;
8184
+ }
8185
+ .netskrafl-container div.user-cat#user-search span.glyphicon-search {
8186
+ font-size: 16px;
8187
+ }
8188
+ .netskrafl-container div.user-cat#user-search span:hover,
8189
+ .netskrafl-container div.user-cat#user-search:focus-within span.glyphicon-search {
8190
+ color: white;
8191
+ background-color: var(--header-hover-color);
8192
+ border-radius: 5px;
8193
+ }
8194
+ .netskrafl-container div.user-cat#user-search input#search-id {
8195
+ /* Always visible on desktop */
8196
+ display: inline-block;
8058
8197
  }
8059
8198
  .netskrafl-container div#chall-form {
8060
8199
  position: absolute;
@@ -8281,6 +8420,9 @@ div.netskrafl-container input[type="checkbox"] {
8281
8420
  margin-right: 160px;
8282
8421
  font-size: inherit;
8283
8422
  }
8423
+ .netskrafl-container div#initials {
8424
+ margin-top: 2px;
8425
+ }
8284
8426
  .netskrafl-container div.stats-box {
8285
8427
  width: auto;
8286
8428
  position: static;