@objectifthunes/whiteboard 0.2.5 → 0.2.7

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.
@@ -514,77 +514,48 @@ select:focus {
514
514
  to { transform: rotate(360deg); }
515
515
  }
516
516
 
517
- /* ── Button ─────────────────────────────────────────── */
517
+ /* ── Button extras ──────────────────────────────────── */
518
518
 
519
- .panel-close-btn {
520
- align-self: flex-start;
521
- color: var(--wb-text-secondary);
522
- border-color: var(--wb-border);
523
- background: var(--wb-white);
524
- }
525
-
526
- .panel-close-btn:hover:not(:disabled) {
527
- background: var(--wb-bg-hover);
528
- }
529
-
530
- .secondary-btn {
531
- color: var(--wb-text-secondary);
532
- border-color: var(--wb-border);
533
- background: var(--wb-white);
534
- }
535
-
536
- .secondary-btn:hover:not(:disabled) {
537
- background: var(--wb-bg-hover);
538
- }
539
-
540
- .danger-btn {
541
- background: var(--wb-primary);
542
- }
543
-
544
- .danger-btn:hover:not(:disabled) {
545
- background: var(--wb-primary-pressed);
546
- }
547
-
548
- .full-width-btn {
519
+ .wb-btn--full-width {
549
520
  width: 100%;
550
521
  }
551
522
 
552
- .icon-only-btn {
553
- min-width: 1.64rem;
554
- min-height: 1.64rem;
555
- padding: 0.2rem;
523
+ .panel-close-btn {
524
+ align-self: flex-start;
556
525
  }
557
526
 
558
527
  /* ── Alert ──────────────────────────────────────────── */
559
528
 
560
- .status-error {
561
- border: 1px solid #fecaca;
562
- border-radius: var(--wb-radius-sm);
563
- padding: 0.42rem 0.54rem;
564
- font-size: var(--wb-fs-md);
565
- color: #991b1b;
566
- background: #fef2f2;
567
- }
568
-
569
- .ui-alert {
570
- border: 1px solid var(--wb-border);
571
- border-radius: var(--wb-radius-sm);
572
- padding: 0.42rem 0.54rem;
573
- font-size: var(--wb-fs-md);
574
- }
575
-
576
- .ui-alert--info {
529
+ .wb-alert--info {
577
530
  color: #1e3a8a;
578
531
  background: #eff6ff;
579
532
  border-color: #bfdbfe;
580
533
  }
581
534
 
582
- .ui-alert--success {
535
+ [data-theme="dark"] .wb-alert--info {
536
+ color: #bfdbfe;
537
+ background: #1e3a8a;
538
+ border-color: #1e40af;
539
+ }
540
+
541
+ .wb-alert--success {
583
542
  color: #166534;
584
543
  background: #ecfdf5;
585
544
  border-color: #bbf7d0;
586
545
  }
587
546
 
547
+ [data-theme="dark"] .wb-alert--success {
548
+ color: #bbf7d0;
549
+ background: #14532d;
550
+ border-color: #15803d;
551
+ }
552
+
553
+ .wb-alert--muted {
554
+ color: var(--wb-text-muted);
555
+ background: var(--wb-surface-muted);
556
+ border-color: var(--wb-border);
557
+ }
558
+
588
559
  /* ── Field ──────────────────────────────────────────── */
589
560
 
590
561
  .field-error {
@@ -608,13 +579,13 @@ select:focus {
608
579
  }
609
580
 
610
581
  .pill.success {
611
- color: #1d4ed8;
612
- background: #eff6ff;
582
+ color: #166534;
583
+ background: #ecfdf5;
613
584
  }
614
585
 
615
586
  .pill.warning {
616
- color: var(--wb-text-tertiary);
617
- background: var(--wb-surface-muted);
587
+ color: #92400e;
588
+ background: #fffbeb;
618
589
  }
619
590
 
620
591
  .pill.danger {
@@ -622,6 +593,21 @@ select:focus {
622
593
  background: #fef2f2;
623
594
  }
624
595
 
596
+ [data-theme="dark"] .pill.success {
597
+ color: #bbf7d0;
598
+ background: #14532d;
599
+ }
600
+
601
+ [data-theme="dark"] .pill.warning {
602
+ color: #fde68a;
603
+ background: #78350f;
604
+ }
605
+
606
+ [data-theme="dark"] .pill.danger {
607
+ color: #fca5a5;
608
+ background: #7f1d1d;
609
+ }
610
+
625
611
  /* ── Chip ───────────────────────────────────────────── */
626
612
 
627
613
  .chip {
@@ -642,13 +628,6 @@ button.chip:hover {
642
628
  background: var(--wb-bg-hover);
643
629
  }
644
630
 
645
- .chip--active {
646
- border-color: #94a3b8;
647
- background: var(--wb-surface-muted);
648
- color: #1e293b;
649
- font-weight: 600;
650
- }
651
-
652
631
  /* ── GeneratingOverlay ──────────────────────────────── */
653
632
 
654
633
  .generating-overlay-wrap {
@@ -707,10 +686,6 @@ button.chip:hover {
707
686
  gap: 0.38rem;
708
687
  }
709
688
 
710
- .panel-scroll {
711
- display: block;
712
- }
713
-
714
689
  .inline-row {
715
690
  display: flex;
716
691
  align-items: center;
@@ -939,13 +914,6 @@ button.chip:hover {
939
914
 
940
915
  /* ── Typography ─────────────────────────────────────── */
941
916
 
942
- .text-truncate {
943
- overflow: hidden;
944
- text-overflow: ellipsis;
945
- white-space: nowrap;
946
- min-width: 0;
947
- }
948
-
949
917
  .text-muted {
950
918
  color: var(--wb-text-muted);
951
919
  }
@@ -1038,11 +1006,6 @@ button.chip:hover {
1038
1006
 
1039
1007
  /* ── PickerGrid / PickerCard ────────────────────────── */
1040
1008
 
1041
- .picker-search {
1042
- display: grid;
1043
- gap: var(--wb-gap-lg);
1044
- }
1045
-
1046
1009
  .picker-grid {
1047
1010
  display: grid;
1048
1011
  gap: 0.4rem;
@@ -1079,16 +1042,6 @@ button.chip:hover {
1079
1042
  cursor: default;
1080
1043
  }
1081
1044
 
1082
- .picker-card-content {
1083
- min-width: 0;
1084
- align-content: start;
1085
- }
1086
-
1087
- .picker-card-thumb {
1088
- width: 100%;
1089
- aspect-ratio: 1 / 1;
1090
- }
1091
-
1092
1045
  /* ── Skeleton ───────────────────────────────────────── */
1093
1046
 
1094
1047
  .skeleton {
@@ -1131,33 +1084,6 @@ button.chip:hover {
1131
1084
  border-radius: var(--wb-radius-sm);
1132
1085
  }
1133
1086
 
1134
- .skeleton-btn--short {
1135
- width: 42%;
1136
- }
1137
-
1138
- .skeleton-btn--back {
1139
- width: 36%;
1140
- }
1141
-
1142
- .skeleton-btn--header-back {
1143
- width: 100%;
1144
- }
1145
-
1146
- .skeleton-btn--tiny {
1147
- width: 78px;
1148
- height: 22px;
1149
- }
1150
-
1151
- .skeleton-btn--story-action {
1152
- width: 82px;
1153
- height: 24px;
1154
- flex: 0 0 auto;
1155
- }
1156
-
1157
- .skeleton-choice {
1158
- height: 36px;
1159
- }
1160
-
1161
1087
  .skeleton-chip {
1162
1088
  width: 58px;
1163
1089
  height: 16px;
@@ -1178,14 +1104,6 @@ button.chip:hover {
1178
1104
  margin-inline: auto;
1179
1105
  }
1180
1106
 
1181
- .skeleton-header-title {
1182
- width: 86%;
1183
- }
1184
-
1185
- .skeleton-header-title--short {
1186
- width: 58%;
1187
- }
1188
-
1189
1107
  .skeleton-line {
1190
1108
  width: 100%;
1191
1109
  height: 10px;
@@ -1216,51 +1134,12 @@ button.chip:hover {
1216
1134
  height: 1.9rem;
1217
1135
  }
1218
1136
 
1219
- .skeleton-style-preview {
1220
- width: 100%;
1221
- max-width: none;
1222
- aspect-ratio: 1 / 1;
1223
- }
1224
-
1225
1137
  .skeleton-canvas {
1226
1138
  width: 100%;
1227
1139
  height: 100%;
1228
1140
  border-radius: 0;
1229
1141
  }
1230
1142
 
1231
- .skeleton-field {
1232
- height: 32px;
1233
- }
1234
-
1235
- .skeleton-coord {
1236
- height: 26px;
1237
- }
1238
-
1239
- .skeleton-meta-line {
1240
- width: 92%;
1241
- }
1242
-
1243
- .skeleton-meta-item {
1244
- width: 62px;
1245
- height: 10px;
1246
- }
1247
-
1248
- .skeleton-meta-dot {
1249
- width: 6px;
1250
- height: 6px;
1251
- border-radius: var(--wb-radius-pill);
1252
- }
1253
-
1254
- .skeleton-meta-item--short {
1255
- width: 38px;
1256
- height: 10px;
1257
- }
1258
-
1259
- .skeleton-page-tab-line {
1260
- width: 74%;
1261
- margin-inline: auto;
1262
- }
1263
-
1264
1143
  @keyframes skeleton-shimmer {
1265
1144
  100% {
1266
1145
  transform: translateX(100%);
@@ -1387,17 +1266,17 @@ button.chip:hover {
1387
1266
  min-width: 1.72rem;
1388
1267
  min-height: 1.72rem;
1389
1268
  padding: 0;
1390
- border: 1px solid color-mix(in srgb, #0f172a 14%, #ffffff);
1269
+ border: 1px solid var(--wb-border);
1391
1270
  border-radius: var(--wb-radius-pill);
1392
1271
  color: var(--wb-text-primary);
1393
- background: color-mix(in srgb, #ffffff 88%, #dbe7f5);
1394
- box-shadow: 0 6px 16px rgba(15, 23, 42, 0.16);
1272
+ background: color-mix(in srgb, var(--wb-surface) 88%, var(--wb-surface-muted));
1273
+ box-shadow: var(--wb-shadow-soft);
1395
1274
  backdrop-filter: blur(5px);
1396
1275
  cursor: pointer;
1397
1276
  }
1398
1277
 
1399
1278
  .overlay-icon-btn:hover:not(:disabled) {
1400
- background: color-mix(in srgb, #ffffff 82%, #d5e4f4);
1279
+ background: color-mix(in srgb, var(--wb-surface) 82%, var(--wb-surface-muted));
1401
1280
  transform: none;
1402
1281
  }
1403
1282
 
@@ -1405,17 +1284,6 @@ button.chip:hover {
1405
1284
  opacity: 0.55;
1406
1285
  }
1407
1286
 
1408
- [data-theme="dark"] .overlay-icon-btn {
1409
- color: var(--wb-text-primary);
1410
- background: color-mix(in srgb, var(--wb-surface) 90%, var(--wb-surface-soft));
1411
- box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
1412
- border-color: var(--wb-border);
1413
- }
1414
-
1415
- [data-theme="dark"] .overlay-icon-btn:hover:not(:disabled) {
1416
- background: color-mix(in srgb, var(--wb-surface-soft) 80%, var(--wb-surface));
1417
- }
1418
-
1419
1287
  .overlay-icon-btn--top-right {
1420
1288
  top: 0.5rem;
1421
1289
  right: 0.5rem;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@objectifthunes/whiteboard",
3
- "version": "0.2.5",
3
+ "version": "0.2.7",
4
4
  "description": "Pan/zoom whiteboard canvas with draggable panels, minimap, snap-to-grid, and zoom controls",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -20,12 +20,6 @@
20
20
  "sideEffects": [
21
21
  "*.css"
22
22
  ],
23
- "scripts": {
24
- "build": "vite build",
25
- "dev": "vite build --watch",
26
- "typecheck": "tsc --noEmit",
27
- "prepack": "pnpm run build"
28
- },
29
23
  "peerDependencies": {
30
24
  "react": ">=18",
31
25
  "react-dom": ">=18",
@@ -40,5 +34,10 @@
40
34
  "vite": "^6.0.0",
41
35
  "vite-plugin-dts": "^4.0.0",
42
36
  "zustand": "^4.5.0"
37
+ },
38
+ "scripts": {
39
+ "build": "vite build",
40
+ "dev": "vite build --watch",
41
+ "typecheck": "tsc --noEmit"
43
42
  }
44
- }
43
+ }