@nextbridgehq/payload-block-builder 0.1.8 → 0.2.0
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/README.md +280 -76
- package/dist/bin/init.js +0 -0
- package/dist/client.cjs +1487 -603
- package/dist/client.d.cts +6 -2
- package/dist/client.d.ts +6 -2
- package/dist/client.js +1438 -530
- package/dist/index.cjs +887 -520
- package/dist/index.d.cts +52 -8
- package/dist/index.d.ts +52 -8
- package/dist/index.js +884 -518
- package/package.json +29 -10
- package/src/block-builder/builder.css +391 -36
- package/src/components/BlockDataField/BlockDataField.css +652 -393
- package/src/components/SchemaBuilderField/SchemaBuilderField.css +361 -361
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
/* ── Block Builder — Light theme ──────────────────────────────────────────── */
|
|
2
2
|
|
|
3
3
|
*, *::before, *::after { box-sizing: border-box; }
|
|
4
4
|
|
|
@@ -22,13 +22,13 @@
|
|
|
22
22
|
--bb-text-muted: #374151;
|
|
23
23
|
--bb-text-subtle: #9ca3af;
|
|
24
24
|
|
|
25
|
-
/* Accent
|
|
25
|
+
/* Accent — Payload light interactive (dark charcoal, mirrors --theme-elevation-1000) */
|
|
26
26
|
--bb-accent: #111827;
|
|
27
27
|
--bb-accent-dark: #000000;
|
|
28
28
|
--bb-accent-subtle: rgba(17, 24, 39, 0.05);
|
|
29
29
|
--bb-accent-border: rgba(17, 24, 39, 0.18);
|
|
30
30
|
|
|
31
|
-
/* Publish green
|
|
31
|
+
/* Publish green — kept only for the Publish button */
|
|
32
32
|
--bb-publish: #22c55e;
|
|
33
33
|
--bb-publish-dark: #16a34a;
|
|
34
34
|
|
|
@@ -41,13 +41,13 @@
|
|
|
41
41
|
--bb-warning: #f59e0b;
|
|
42
42
|
}
|
|
43
43
|
|
|
44
|
-
/*
|
|
44
|
+
/* ── Scrollbars ─────────────────────────────────────────────────────────── */
|
|
45
45
|
::-webkit-scrollbar { width: 5px; height: 5px; }
|
|
46
46
|
::-webkit-scrollbar-track { background: transparent; }
|
|
47
47
|
::-webkit-scrollbar-thumb { background: var(--bb-border-mid); border-radius: 3px; }
|
|
48
48
|
::-webkit-scrollbar-thumb:hover { background: var(--bb-border-strong); }
|
|
49
49
|
|
|
50
|
-
/*
|
|
50
|
+
/* ── Base ───────────────────────────────────────────────────────────────── */
|
|
51
51
|
body {
|
|
52
52
|
background: var(--bb-bg);
|
|
53
53
|
color: var(--bb-text);
|
|
@@ -55,7 +55,7 @@ body {
|
|
|
55
55
|
-webkit-font-smoothing: antialiased;
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
-
/*
|
|
58
|
+
/* ── Full-screen state (loading / error) ────────────────────────────────── */
|
|
59
59
|
.bb-fullscreen {
|
|
60
60
|
height: 100vh;
|
|
61
61
|
display: flex;
|
|
@@ -69,7 +69,7 @@ body {
|
|
|
69
69
|
.bb-fullscreen--error { color: var(--bb-danger); }
|
|
70
70
|
.bb-fullscreen--loading { color: var(--bb-text-subtle); }
|
|
71
71
|
|
|
72
|
-
/*
|
|
72
|
+
/* ── Shell ──────────────────────────────────────────────────────────────── */
|
|
73
73
|
.bb-shell {
|
|
74
74
|
display: flex;
|
|
75
75
|
flex-direction: column;
|
|
@@ -82,7 +82,7 @@ body {
|
|
|
82
82
|
line-height: 1.5;
|
|
83
83
|
}
|
|
84
84
|
|
|
85
|
-
/*
|
|
85
|
+
/* ── Top Bar ────────────────────────────────────────────────────────────── */
|
|
86
86
|
.bb-topbar {
|
|
87
87
|
height: 48px;
|
|
88
88
|
border-bottom: 1px solid var(--bb-border);
|
|
@@ -130,7 +130,7 @@ body {
|
|
|
130
130
|
.bb-topbar__status--ok { color: var(--bb-publish-dark); }
|
|
131
131
|
.bb-topbar__status--error { color: var(--bb-danger); }
|
|
132
132
|
|
|
133
|
-
/*
|
|
133
|
+
/* ── Buttons ────────────────────────────────────────────────────────────── */
|
|
134
134
|
.bb-btn {
|
|
135
135
|
display: inline-flex;
|
|
136
136
|
align-items: center;
|
|
@@ -168,14 +168,14 @@ body {
|
|
|
168
168
|
border-color: var(--bb-border-strong);
|
|
169
169
|
}
|
|
170
170
|
|
|
171
|
-
/*
|
|
171
|
+
/* ── Main layout ────────────────────────────────────────────────────────── */
|
|
172
172
|
.bb-main {
|
|
173
173
|
flex: 1;
|
|
174
174
|
display: flex;
|
|
175
175
|
overflow: hidden;
|
|
176
176
|
}
|
|
177
177
|
|
|
178
|
-
/*
|
|
178
|
+
/* ── Sidebar panel (BlockList, FieldPalette) ────────────────────────────── */
|
|
179
179
|
.bb-sidebar {
|
|
180
180
|
border-right: 1px solid var(--bb-border);
|
|
181
181
|
display: flex;
|
|
@@ -240,7 +240,7 @@ body {
|
|
|
240
240
|
}
|
|
241
241
|
.bb-sidebar__add:hover { background: var(--bb-publish-dark); }
|
|
242
242
|
|
|
243
|
-
/*
|
|
243
|
+
/* ── Block items ────────────────────────────────────────────────────────── */
|
|
244
244
|
.bb-block-item {
|
|
245
245
|
padding: 7px 9px;
|
|
246
246
|
border-radius: 5px;
|
|
@@ -304,7 +304,7 @@ body {
|
|
|
304
304
|
line-height: 1.7;
|
|
305
305
|
}
|
|
306
306
|
|
|
307
|
-
/*
|
|
307
|
+
/* ── Field palette ──────────────────────────────────────────────────────── */
|
|
308
308
|
.bb-palette__search-wrap {
|
|
309
309
|
padding: 8px;
|
|
310
310
|
border-bottom: 1px solid var(--bb-border);
|
|
@@ -391,7 +391,7 @@ body {
|
|
|
391
391
|
.bb-palette__item:hover:not(:disabled) .bb-palette__item__label { color: var(--bb-text); }
|
|
392
392
|
.bb-palette__item:hover:not(:disabled) .bb-palette__item__type { color: var(--bb-text-subtle); }
|
|
393
393
|
|
|
394
|
-
/*
|
|
394
|
+
/* ── Canvas ─────────────────────────────────────────────────────────────── */
|
|
395
395
|
.bb-canvas {
|
|
396
396
|
flex: 1;
|
|
397
397
|
overflow: auto;
|
|
@@ -438,7 +438,7 @@ body {
|
|
|
438
438
|
gap: 6px;
|
|
439
439
|
}
|
|
440
440
|
|
|
441
|
-
/*
|
|
441
|
+
/* ── Field Card ─────────────────────────────────────────────────────────── */
|
|
442
442
|
.bb-field-card-wrap--dragging { opacity: 0.5; }
|
|
443
443
|
|
|
444
444
|
.bb-field-card {
|
|
@@ -519,7 +519,7 @@ body {
|
|
|
519
519
|
color: var(--bb-danger);
|
|
520
520
|
}
|
|
521
521
|
|
|
522
|
-
/*
|
|
522
|
+
/* ── Config Panel ───────────────────────────────────────────────────────── */
|
|
523
523
|
.bb-config {
|
|
524
524
|
width: 280px;
|
|
525
525
|
border-left: 1px solid var(--bb-border);
|
|
@@ -562,7 +562,7 @@ body {
|
|
|
562
562
|
overflow-y: auto;
|
|
563
563
|
}
|
|
564
564
|
|
|
565
|
-
/*
|
|
565
|
+
/* ── Config forms ───────────────────────────────────────────────────────── */
|
|
566
566
|
.bb-form {
|
|
567
567
|
padding: 14px;
|
|
568
568
|
display: flex;
|
|
@@ -717,7 +717,7 @@ body {
|
|
|
717
717
|
}
|
|
718
718
|
.bb-add-option:hover { border-color: var(--bb-border-strong); color: var(--bb-text-muted); }
|
|
719
719
|
|
|
720
|
-
/*
|
|
720
|
+
/* ── Footer / Code Preview ──────────────────────────────────────────────── */
|
|
721
721
|
.bb-footer {
|
|
722
722
|
border-top: 1px solid var(--bb-border);
|
|
723
723
|
flex-shrink: 0;
|
|
@@ -749,7 +749,7 @@ body {
|
|
|
749
749
|
overflow: hidden;
|
|
750
750
|
}
|
|
751
751
|
|
|
752
|
-
/*
|
|
752
|
+
/* ── Code preview syntax ────────────────────────────────────────────────── */
|
|
753
753
|
.code-preview {
|
|
754
754
|
background: #1e293b;
|
|
755
755
|
font-family: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;
|
|
@@ -762,14 +762,287 @@ body {
|
|
|
762
762
|
.token-punct { color: #89ddff; }
|
|
763
763
|
.token-plain { color: #f1f5f9; }
|
|
764
764
|
|
|
765
|
-
/*
|
|
765
|
+
/* ── Panel animation ────────────────────────────────────────────────────── */
|
|
766
766
|
@keyframes panel-enter {
|
|
767
767
|
from { opacity: 0; transform: translateX(8px); }
|
|
768
768
|
to { opacity: 1; transform: translateX(0); }
|
|
769
769
|
}
|
|
770
770
|
.panel-enter { animation: panel-enter 0.15s ease-out; }
|
|
771
771
|
|
|
772
|
-
/*
|
|
772
|
+
/* ── Live Preview ──────────────────────────────────────────────────── */
|
|
773
|
+
.bb-live-preview {
|
|
774
|
+
flex: 1;
|
|
775
|
+
border-left: 1px solid var(--bb-border);
|
|
776
|
+
background: var(--bb-bg);
|
|
777
|
+
display: flex;
|
|
778
|
+
flex-direction: column;
|
|
779
|
+
min-width: 0;
|
|
780
|
+
}
|
|
781
|
+
|
|
782
|
+
.bb-live-preview--empty {
|
|
783
|
+
align-items: center;
|
|
784
|
+
justify-content: center;
|
|
785
|
+
}
|
|
786
|
+
|
|
787
|
+
.bb-live-preview__header {
|
|
788
|
+
height: 40px;
|
|
789
|
+
border-bottom: 1px solid var(--bb-border);
|
|
790
|
+
display: flex;
|
|
791
|
+
align-items: center;
|
|
792
|
+
justify-content: space-between;
|
|
793
|
+
padding: 0 18px;
|
|
794
|
+
background: var(--bb-surface-0);
|
|
795
|
+
flex-shrink: 0;
|
|
796
|
+
}
|
|
797
|
+
.bb-live-preview__title {
|
|
798
|
+
font-size: 11px;
|
|
799
|
+
font-weight: 700;
|
|
800
|
+
letter-spacing: 0.04em;
|
|
801
|
+
color: var(--bb-text-muted);
|
|
802
|
+
}
|
|
803
|
+
.bb-live-preview__meta {
|
|
804
|
+
font-size: 11.5px;
|
|
805
|
+
color: var(--bb-text-subtle);
|
|
806
|
+
}
|
|
807
|
+
|
|
808
|
+
.bb-live-preview__body {
|
|
809
|
+
flex: 1;
|
|
810
|
+
overflow-y: auto;
|
|
811
|
+
padding: 28px 24px;
|
|
812
|
+
}
|
|
813
|
+
|
|
814
|
+
/* Framed "page" surface so the preview reads as a mockup, not a debug list */
|
|
815
|
+
.bb-live-preview__page {
|
|
816
|
+
max-width: 560px;
|
|
817
|
+
margin: 0 auto;
|
|
818
|
+
background: var(--bb-surface-0);
|
|
819
|
+
border: 1px solid var(--bb-border);
|
|
820
|
+
border-radius: 10px;
|
|
821
|
+
padding: 24px;
|
|
822
|
+
box-shadow: 0 1px 3px rgba(17, 24, 39, 0.05);
|
|
823
|
+
display: flex;
|
|
824
|
+
flex-direction: column;
|
|
825
|
+
gap: 18px;
|
|
826
|
+
}
|
|
827
|
+
|
|
828
|
+
.bb-preview-field { display: flex; flex-direction: column; gap: 6px; }
|
|
829
|
+
|
|
830
|
+
.bb-preview-field__head {
|
|
831
|
+
display: flex;
|
|
832
|
+
align-items: flex-start;
|
|
833
|
+
gap: 8px;
|
|
834
|
+
}
|
|
835
|
+
.bb-preview-field__icon {
|
|
836
|
+
display: inline-flex;
|
|
837
|
+
color: var(--bb-text-subtle);
|
|
838
|
+
flex-shrink: 0;
|
|
839
|
+
margin-top: 2px;
|
|
840
|
+
}
|
|
841
|
+
.bb-preview-field__headtext {
|
|
842
|
+
display: flex;
|
|
843
|
+
flex-direction: column;
|
|
844
|
+
gap: 2px;
|
|
845
|
+
min-width: 0;
|
|
846
|
+
flex: 1;
|
|
847
|
+
}
|
|
848
|
+
.bb-preview-field__label {
|
|
849
|
+
font-size: 12.5px;
|
|
850
|
+
font-weight: 600;
|
|
851
|
+
color: var(--bb-text-muted);
|
|
852
|
+
overflow-wrap: anywhere;
|
|
853
|
+
}
|
|
854
|
+
.bb-preview-field__required {
|
|
855
|
+
color: var(--bb-danger);
|
|
856
|
+
margin-left: 3px;
|
|
857
|
+
}
|
|
858
|
+
.bb-preview-field__meta {
|
|
859
|
+
display: flex;
|
|
860
|
+
align-items: center;
|
|
861
|
+
flex-wrap: wrap;
|
|
862
|
+
gap: 6px;
|
|
863
|
+
}
|
|
864
|
+
.bb-preview-field__slug {
|
|
865
|
+
font-size: 10.5px;
|
|
866
|
+
font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace;
|
|
867
|
+
color: var(--bb-text-subtle);
|
|
868
|
+
background: var(--bb-surface-2);
|
|
869
|
+
border: 1px solid var(--bb-border);
|
|
870
|
+
border-radius: 4px;
|
|
871
|
+
padding: 1px 6px;
|
|
872
|
+
word-break: break-all;
|
|
873
|
+
}
|
|
874
|
+
.bb-preview-field__badge {
|
|
875
|
+
font-size: 10px;
|
|
876
|
+
font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace;
|
|
877
|
+
color: var(--bb-text-subtle);
|
|
878
|
+
background: var(--bb-surface-3);
|
|
879
|
+
border: 1px solid var(--bb-border);
|
|
880
|
+
border-radius: 999px;
|
|
881
|
+
padding: 1px 8px;
|
|
882
|
+
flex-shrink: 0;
|
|
883
|
+
}
|
|
884
|
+
|
|
885
|
+
/* Live Preview mock inputs -- deliberately separate from .bb-input (used by
|
|
886
|
+
the real FieldConfig edit panel, which is fixed-height and dims heavily
|
|
887
|
+
when disabled). These need per-type sizing (a textarea must show its rows,
|
|
888
|
+
a select needs its own arrow) and a legible "empty form field" look rather
|
|
889
|
+
than a washed-out disabled one. */
|
|
890
|
+
.bb-preview-input {
|
|
891
|
+
width: 100%;
|
|
892
|
+
height: 36px;
|
|
893
|
+
padding: 0 11px;
|
|
894
|
+
background: var(--bb-surface-2);
|
|
895
|
+
border: 1px solid var(--bb-border-mid);
|
|
896
|
+
border-radius: 6px;
|
|
897
|
+
color: var(--bb-text-subtle);
|
|
898
|
+
font-size: 13px;
|
|
899
|
+
font-family: var(--bb-font);
|
|
900
|
+
box-sizing: border-box;
|
|
901
|
+
}
|
|
902
|
+
.bb-preview-input::placeholder { color: var(--bb-text-subtle); }
|
|
903
|
+
.bb-preview-input:disabled { cursor: default; opacity: 1; }
|
|
904
|
+
/* Native date inputs render their calendar icon dark by default; dim it to
|
|
905
|
+
match the rest of the muted preview UI. */
|
|
906
|
+
.bb-preview-input[type='date']::-webkit-calendar-picker-indicator { opacity: 0.5; }
|
|
907
|
+
|
|
908
|
+
.bb-preview-textarea {
|
|
909
|
+
width: 100%;
|
|
910
|
+
min-height: 74px;
|
|
911
|
+
padding: 9px 11px;
|
|
912
|
+
background: var(--bb-surface-2);
|
|
913
|
+
border: 1px solid var(--bb-border-mid);
|
|
914
|
+
border-radius: 6px;
|
|
915
|
+
color: var(--bb-text-subtle);
|
|
916
|
+
font-size: 13px;
|
|
917
|
+
font-family: var(--bb-font);
|
|
918
|
+
line-height: 1.5;
|
|
919
|
+
resize: none;
|
|
920
|
+
box-sizing: border-box;
|
|
921
|
+
}
|
|
922
|
+
.bb-preview-textarea::placeholder { color: var(--bb-text-subtle); }
|
|
923
|
+
.bb-preview-textarea:disabled { cursor: default; opacity: 1; }
|
|
924
|
+
|
|
925
|
+
.bb-preview-select {
|
|
926
|
+
width: 100%;
|
|
927
|
+
height: 36px;
|
|
928
|
+
padding: 0 34px 0 11px;
|
|
929
|
+
background-color: var(--bb-surface-2);
|
|
930
|
+
border: 1px solid var(--bb-border-mid);
|
|
931
|
+
border-radius: 6px;
|
|
932
|
+
color: var(--bb-text-subtle);
|
|
933
|
+
font-size: 13px;
|
|
934
|
+
font-family: var(--bb-font);
|
|
935
|
+
box-sizing: border-box;
|
|
936
|
+
cursor: default;
|
|
937
|
+
appearance: none;
|
|
938
|
+
-webkit-appearance: none;
|
|
939
|
+
-moz-appearance: none;
|
|
940
|
+
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%239ca3af' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
|
|
941
|
+
background-repeat: no-repeat;
|
|
942
|
+
background-position: right 12px center;
|
|
943
|
+
}
|
|
944
|
+
.bb-preview-select:disabled { opacity: 1; }
|
|
945
|
+
.bb-preview-select option { background: var(--bb-surface-0); color: var(--bb-text); }
|
|
946
|
+
|
|
947
|
+
.bb-preview-checkbox {
|
|
948
|
+
display: flex;
|
|
949
|
+
align-items: flex-start;
|
|
950
|
+
gap: 8px;
|
|
951
|
+
cursor: default;
|
|
952
|
+
}
|
|
953
|
+
.bb-preview-checkbox__input {
|
|
954
|
+
flex-shrink: 0;
|
|
955
|
+
margin-top: 3px;
|
|
956
|
+
width: 15px;
|
|
957
|
+
height: 15px;
|
|
958
|
+
accent-color: var(--bb-text-subtle);
|
|
959
|
+
cursor: default;
|
|
960
|
+
}
|
|
961
|
+
|
|
962
|
+
.bb-preview-placeholder {
|
|
963
|
+
display: flex;
|
|
964
|
+
align-items: center;
|
|
965
|
+
gap: 6px;
|
|
966
|
+
padding: 9px 10px;
|
|
967
|
+
border: 1px dashed var(--bb-border-mid);
|
|
968
|
+
border-radius: 6px;
|
|
969
|
+
color: var(--bb-text-subtle);
|
|
970
|
+
font-size: 12px;
|
|
971
|
+
background: var(--bb-surface-2);
|
|
972
|
+
}
|
|
973
|
+
.bb-preview-placeholder--upload { color: var(--bb-text-muted); }
|
|
974
|
+
|
|
975
|
+
.bb-preview-row {
|
|
976
|
+
display: flex;
|
|
977
|
+
gap: 14px;
|
|
978
|
+
align-items: flex-start;
|
|
979
|
+
}
|
|
980
|
+
.bb-preview-row > * { flex: 1; min-width: 0; }
|
|
981
|
+
|
|
982
|
+
.bb-preview-group {
|
|
983
|
+
border: 1px solid var(--bb-border-mid);
|
|
984
|
+
border-radius: 8px;
|
|
985
|
+
overflow: hidden;
|
|
986
|
+
background: var(--bb-surface-0);
|
|
987
|
+
}
|
|
988
|
+
.bb-preview-group__header {
|
|
989
|
+
display: flex;
|
|
990
|
+
align-items: center;
|
|
991
|
+
gap: 6px;
|
|
992
|
+
padding: 8px 12px;
|
|
993
|
+
background: var(--bb-surface-2);
|
|
994
|
+
border-bottom: 1px solid var(--bb-border-mid);
|
|
995
|
+
}
|
|
996
|
+
.bb-preview-group__header .bb-preview-field__label { color: var(--bb-text); }
|
|
997
|
+
.bb-preview-group__sublabel {
|
|
998
|
+
margin-left: 6px;
|
|
999
|
+
font-size: 11px;
|
|
1000
|
+
font-weight: 400;
|
|
1001
|
+
color: var(--bb-text-subtle);
|
|
1002
|
+
}
|
|
1003
|
+
.bb-preview-group__body {
|
|
1004
|
+
padding: 14px;
|
|
1005
|
+
display: flex;
|
|
1006
|
+
flex-direction: column;
|
|
1007
|
+
gap: 14px;
|
|
1008
|
+
background: var(--bb-surface-2);
|
|
1009
|
+
}
|
|
1010
|
+
|
|
1011
|
+
.bb-preview-tabs__list {
|
|
1012
|
+
display: flex;
|
|
1013
|
+
background: var(--bb-surface-0);
|
|
1014
|
+
border-bottom: 1px solid var(--bb-border-mid);
|
|
1015
|
+
overflow-x: auto;
|
|
1016
|
+
padding: 0 6px;
|
|
1017
|
+
}
|
|
1018
|
+
.bb-preview-tabs__tab {
|
|
1019
|
+
padding: 8px 12px;
|
|
1020
|
+
background: none;
|
|
1021
|
+
border: none;
|
|
1022
|
+
border-bottom: 2px solid transparent;
|
|
1023
|
+
font-size: 12px;
|
|
1024
|
+
font-weight: 500;
|
|
1025
|
+
color: var(--bb-text-subtle);
|
|
1026
|
+
cursor: pointer;
|
|
1027
|
+
white-space: nowrap;
|
|
1028
|
+
transition: color 0.1s;
|
|
1029
|
+
}
|
|
1030
|
+
.bb-preview-tabs__tab:hover { color: var(--bb-text-muted); }
|
|
1031
|
+
.bb-preview-tabs__tab--active {
|
|
1032
|
+
color: var(--bb-text);
|
|
1033
|
+
border-bottom-color: var(--bb-accent);
|
|
1034
|
+
font-weight: 600;
|
|
1035
|
+
}
|
|
1036
|
+
.bb-preview-tabs__path {
|
|
1037
|
+
display: flex;
|
|
1038
|
+
align-items: center;
|
|
1039
|
+
gap: 6px;
|
|
1040
|
+
font-size: 11px;
|
|
1041
|
+
color: var(--bb-text-subtle);
|
|
1042
|
+
padding: 8px 10px 0;
|
|
1043
|
+
}
|
|
1044
|
+
|
|
1045
|
+
/* ── Notification overlay ───────────────────────────────────────────────── */
|
|
773
1046
|
@keyframes bb-notify-in {
|
|
774
1047
|
from { opacity: 0; transform: translateY(-12px) scale(0.97); }
|
|
775
1048
|
to { opacity: 1; transform: translateY(0) scale(1); }
|
|
@@ -903,7 +1176,7 @@ body {
|
|
|
903
1176
|
margin-top: 2px;
|
|
904
1177
|
}
|
|
905
1178
|
|
|
906
|
-
/*
|
|
1179
|
+
/* ── Warning button (restore as new version) ────────────────────────────── */
|
|
907
1180
|
.bb-btn--warning {
|
|
908
1181
|
background: #f59e0b;
|
|
909
1182
|
color: #fff;
|
|
@@ -911,7 +1184,7 @@ body {
|
|
|
911
1184
|
}
|
|
912
1185
|
.bb-btn--warning:hover:not(:disabled) { background: #d97706; border-color: #d97706; }
|
|
913
1186
|
|
|
914
|
-
/*
|
|
1187
|
+
/* ── Read-only banner ───────────────────────────────────────────────────── */
|
|
915
1188
|
.bb-readonly-banner {
|
|
916
1189
|
display: flex;
|
|
917
1190
|
align-items: center;
|
|
@@ -937,16 +1210,16 @@ body {
|
|
|
937
1210
|
}
|
|
938
1211
|
.bb-readonly-banner__btn:hover { color: #92400e; }
|
|
939
1212
|
|
|
940
|
-
/*
|
|
1213
|
+
/* ── Read-only canvas ───────────────────────────────────────────────────── */
|
|
941
1214
|
.bb-canvas--readonly { pointer-events: none; user-select: none; opacity: 0.7; }
|
|
942
1215
|
|
|
943
|
-
/*
|
|
1216
|
+
/* ── Read-only field palette ────────────────────────────────────────────── */
|
|
944
1217
|
.bb-sidebar--readonly {
|
|
945
1218
|
opacity: 0.5;
|
|
946
1219
|
pointer-events: none;
|
|
947
1220
|
}
|
|
948
1221
|
|
|
949
|
-
/*
|
|
1222
|
+
/* ── Read-only config panel overlay ────────────────────────────────────── */
|
|
950
1223
|
.bb-config--readonly { position: relative; }
|
|
951
1224
|
.bb-config__readonly-overlay {
|
|
952
1225
|
position: absolute;
|
|
@@ -970,7 +1243,7 @@ body {
|
|
|
970
1243
|
background: var(--bb-surface-0);
|
|
971
1244
|
}
|
|
972
1245
|
|
|
973
|
-
/*
|
|
1246
|
+
/* ── Version selector (TopBar dropdown) ─────────────────────────────────── */
|
|
974
1247
|
.bb-version-selector {
|
|
975
1248
|
position: relative;
|
|
976
1249
|
flex-shrink: 0;
|
|
@@ -1028,7 +1301,7 @@ body {
|
|
|
1028
1301
|
margin-left: 2px;
|
|
1029
1302
|
}
|
|
1030
1303
|
|
|
1031
|
-
/*
|
|
1304
|
+
/* ── Version dropdown menu ──────────────────────────────────────────────── */
|
|
1032
1305
|
.bb-version-dropdown {
|
|
1033
1306
|
position: absolute;
|
|
1034
1307
|
top: calc(100% + 4px);
|
|
@@ -1089,7 +1362,7 @@ body {
|
|
|
1089
1362
|
flex-shrink: 0;
|
|
1090
1363
|
}
|
|
1091
1364
|
|
|
1092
|
-
/*
|
|
1365
|
+
/* ── Block picker (TopBar) ──────────────────────────────────────────────── */
|
|
1093
1366
|
|
|
1094
1367
|
.bb-topbar__selectors {
|
|
1095
1368
|
display: flex;
|
|
@@ -1156,7 +1429,7 @@ body {
|
|
|
1156
1429
|
white-space: nowrap;
|
|
1157
1430
|
}
|
|
1158
1431
|
|
|
1159
|
-
/*
|
|
1432
|
+
/* ── Inline loading / error bars ────────────────────────────────────────── */
|
|
1160
1433
|
.bb-loading-bar {
|
|
1161
1434
|
padding: 6px 20px;
|
|
1162
1435
|
font-size: 12px;
|
|
@@ -1175,17 +1448,17 @@ body {
|
|
|
1175
1448
|
flex-shrink: 0;
|
|
1176
1449
|
}
|
|
1177
1450
|
|
|
1178
|
-
/*
|
|
1451
|
+
/* ── Main center column (palette + canvas) ──────────────────────────────── */
|
|
1179
1452
|
.bb-main__center {
|
|
1180
1453
|
flex: 1;
|
|
1181
1454
|
display: flex;
|
|
1182
1455
|
overflow: hidden;
|
|
1183
1456
|
}
|
|
1184
1457
|
|
|
1185
|
-
/*
|
|
1458
|
+
/* ── Mobile nav (hidden on desktop) ────────────────────────────────────── */
|
|
1186
1459
|
.bb-mobile-nav { display: none; }
|
|
1187
1460
|
|
|
1188
|
-
/*
|
|
1461
|
+
/* ── Responsive — Tablet (640–1023px) ───────────────────────────────────── */
|
|
1189
1462
|
@media (max-width: 1023px) {
|
|
1190
1463
|
.bb-topbar__selectors {
|
|
1191
1464
|
min-width: 0;
|
|
@@ -1197,7 +1470,7 @@ body {
|
|
|
1197
1470
|
.bb-block-picker__trigger { max-width: 180px; }
|
|
1198
1471
|
}
|
|
1199
1472
|
|
|
1200
|
-
/*
|
|
1473
|
+
/* ── Responsive — Mobile (<640px) ───────────────────────────────────────── */
|
|
1201
1474
|
@media (max-width: 639px) {
|
|
1202
1475
|
/* Topbar: 2-row layout */
|
|
1203
1476
|
.bb-topbar {
|
|
@@ -1264,7 +1537,7 @@ body {
|
|
|
1264
1537
|
/* Buttons: proper 44px touch targets */
|
|
1265
1538
|
.bb-btn { height: 44px; padding: 0 14px; font-size: 13px; }
|
|
1266
1539
|
|
|
1267
|
-
/* Main: panel-tab switching
|
|
1540
|
+
/* Main: panel-tab switching — each panel fills full width when active */
|
|
1268
1541
|
.bb-main__center { width: 100%; }
|
|
1269
1542
|
|
|
1270
1543
|
/* Hide blocks sidebar and config by default on mobile */
|
|
@@ -1280,7 +1553,7 @@ body {
|
|
|
1280
1553
|
.bb-main[data-mobile-panel='blocks'] .bb-main__center { display: none; }
|
|
1281
1554
|
.bb-main[data-mobile-panel='blocks'] .bb-config { display: none; }
|
|
1282
1555
|
|
|
1283
|
-
/* Canvas tab
|
|
1556
|
+
/* Canvas tab — palette hidden, canvas visible */
|
|
1284
1557
|
.bb-sidebar--palette { display: none; }
|
|
1285
1558
|
.bb-main[data-mobile-panel='canvas'] .bb-sidebar--palette { display: none; }
|
|
1286
1559
|
.bb-main[data-mobile-panel='canvas'] .bb-canvas { display: flex; flex: 1; }
|
|
@@ -1361,3 +1634,85 @@ body {
|
|
|
1361
1634
|
}
|
|
1362
1635
|
|
|
1363
1636
|
|
|
1637
|
+
|
|
1638
|
+
/* ── Canvas breadcrumb ─────────────────────────────────────────────────────── */
|
|
1639
|
+
.bb-breadcrumb {
|
|
1640
|
+
display: flex;
|
|
1641
|
+
align-items: center;
|
|
1642
|
+
gap: 8px;
|
|
1643
|
+
min-width: 0;
|
|
1644
|
+
flex-wrap: wrap;
|
|
1645
|
+
}
|
|
1646
|
+
|
|
1647
|
+
.bb-breadcrumb__item {
|
|
1648
|
+
background: none;
|
|
1649
|
+
border: none;
|
|
1650
|
+
padding: 0;
|
|
1651
|
+
font: inherit;
|
|
1652
|
+
cursor: pointer;
|
|
1653
|
+
color: var(--bb-text-subtle);
|
|
1654
|
+
max-width: 180px;
|
|
1655
|
+
overflow: hidden;
|
|
1656
|
+
text-overflow: ellipsis;
|
|
1657
|
+
white-space: nowrap;
|
|
1658
|
+
}
|
|
1659
|
+
|
|
1660
|
+
.bb-breadcrumb__item:hover:not([data-current]) {
|
|
1661
|
+
color: var(--bb-text);
|
|
1662
|
+
text-decoration: underline;
|
|
1663
|
+
}
|
|
1664
|
+
|
|
1665
|
+
.bb-breadcrumb__item[data-current] {
|
|
1666
|
+
color: var(--bb-text);
|
|
1667
|
+
font-weight: 600;
|
|
1668
|
+
cursor: default;
|
|
1669
|
+
}
|
|
1670
|
+
|
|
1671
|
+
.bb-breadcrumb__sep {
|
|
1672
|
+
color: var(--bb-border-strong);
|
|
1673
|
+
user-select: none;
|
|
1674
|
+
}
|
|
1675
|
+
|
|
1676
|
+
/* ── Error boundary ────────────────────────────────────────────────────────── */
|
|
1677
|
+
.bb-error-boundary {
|
|
1678
|
+
padding: 2rem;
|
|
1679
|
+
margin: 1rem;
|
|
1680
|
+
background: var(--theme-error-50, #fef2f2);
|
|
1681
|
+
border: 1px solid var(--theme-error-200, #fecaca);
|
|
1682
|
+
border-radius: 8px;
|
|
1683
|
+
font-family: var(--bb-font);
|
|
1684
|
+
color: var(--theme-error-900, #7f1d1d);
|
|
1685
|
+
}
|
|
1686
|
+
|
|
1687
|
+
.bb-error-boundary__title { margin-top: 0; font-size: 16px; }
|
|
1688
|
+
|
|
1689
|
+
.bb-error-boundary__details { margin-bottom: 1rem; opacity: 0.85; }
|
|
1690
|
+
.bb-error-boundary__details summary { cursor: pointer; font-size: 13px; }
|
|
1691
|
+
|
|
1692
|
+
.bb-error-boundary__trace {
|
|
1693
|
+
white-space: pre-wrap;
|
|
1694
|
+
word-break: break-word;
|
|
1695
|
+
font-size: 12px;
|
|
1696
|
+
margin: 8px 0 0;
|
|
1697
|
+
}
|
|
1698
|
+
|
|
1699
|
+
.bb-error-boundary__actions { display: flex; gap: 8px; flex-wrap: wrap; }
|
|
1700
|
+
|
|
1701
|
+
.bb-error-boundary__btn {
|
|
1702
|
+
padding: 0.5rem 1rem;
|
|
1703
|
+
border: 1px solid var(--theme-error-200, #fecaca);
|
|
1704
|
+
background: transparent;
|
|
1705
|
+
color: inherit;
|
|
1706
|
+
border-radius: 4px;
|
|
1707
|
+
cursor: pointer;
|
|
1708
|
+
font: inherit;
|
|
1709
|
+
font-size: 13px;
|
|
1710
|
+
}
|
|
1711
|
+
|
|
1712
|
+
.bb-error-boundary__btn--primary {
|
|
1713
|
+
background: var(--theme-error-600, #dc2626);
|
|
1714
|
+
border-color: var(--theme-error-600, #dc2626);
|
|
1715
|
+
color: #fff;
|
|
1716
|
+
}
|
|
1717
|
+
|
|
1718
|
+
.bb-error-boundary__hint { font-size: 12px; opacity: 0.75; margin: 12px 0 0; }
|