@flytedan/flytebot-design-system 0.7.2 → 0.8.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/dist/index.cjs +254 -119
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +73 -31
- package/dist/index.d.ts +73 -31
- package/dist/index.js +254 -119
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/styles/components.css +176 -11
package/package.json
CHANGED
package/styles/components.css
CHANGED
|
@@ -3738,27 +3738,192 @@
|
|
|
3738
3738
|
border-color: var(--danger-border);
|
|
3739
3739
|
}
|
|
3740
3740
|
|
|
3741
|
-
/*
|
|
3742
|
-
.fd-
|
|
3743
|
-
|
|
3744
|
-
|
|
3745
|
-
|
|
3746
|
-
|
|
3747
|
-
|
|
3748
|
-
|
|
3741
|
+
/* ============ Custom scrollbar (utility) ============ */
|
|
3742
|
+
/* .fd-scrollbar — the one on-brand thin scrollbar treatment, applicable to any
|
|
3743
|
+
scrollable container (vertical or horizontal). Named distinctly from the
|
|
3744
|
+
unrelated, pre-existing .fd-scroll (the app SHELL's own main scrollable
|
|
3745
|
+
region, styles/components.css's "Misc layout helpers" section — flex:1 +
|
|
3746
|
+
padding, nothing to do with scrollbar appearance) to avoid colliding with
|
|
3747
|
+
it. Originally a one-off on .fd-filestrip; generalized so every scrollable
|
|
3748
|
+
list/panel in the kit (e.g. VirtualList) renders the same custom thumb
|
|
3749
|
+
instead of the browser default. Firefox via scrollbar-width/scrollbar-color,
|
|
3750
|
+
everything else via the ::-webkit-scrollbar pseudo-elements; both read the
|
|
3751
|
+
same border tokens so light/dark theming (see tokens.css's
|
|
3752
|
+
[data-theme="dark"] overrides of --border-strong) is automatic. */
|
|
3753
|
+
.fd-scrollbar {
|
|
3749
3754
|
scrollbar-width: thin;
|
|
3750
3755
|
scrollbar-color: var(--border-strong) transparent;
|
|
3751
3756
|
}
|
|
3752
|
-
.fd-
|
|
3757
|
+
.fd-scrollbar::-webkit-scrollbar {
|
|
3758
|
+
width: 6px;
|
|
3753
3759
|
height: 6px;
|
|
3754
3760
|
}
|
|
3755
|
-
.fd-
|
|
3761
|
+
.fd-scrollbar::-webkit-scrollbar-thumb {
|
|
3756
3762
|
background: var(--border-strong);
|
|
3757
3763
|
border-radius: 99px;
|
|
3758
3764
|
}
|
|
3759
|
-
.fd-
|
|
3765
|
+
.fd-scrollbar::-webkit-scrollbar-thumb:hover {
|
|
3766
|
+
background: var(--text-muted);
|
|
3767
|
+
}
|
|
3768
|
+
.fd-scrollbar::-webkit-scrollbar-track {
|
|
3760
3769
|
background: transparent;
|
|
3761
3770
|
}
|
|
3771
|
+
|
|
3772
|
+
/* ============ Data list (VirtualList / TransferList / EntityRow) ============ */
|
|
3773
|
+
/* Each mounted row is absolutely positioned (top:0 + transform:translateY(index *
|
|
3774
|
+
itemHeight)) inside VirtualList's totalHeight track, so when an item's index
|
|
3775
|
+
changes — a resort, or rows closing a gap after one above them is removed —
|
|
3776
|
+
React reuses the same DOM node (keyed by the caller's keyOf) and it slides to
|
|
3777
|
+
its new slot instead of snapping. transform, not top, for the animated property:
|
|
3778
|
+
compositor-only, no layout thrash even with ~50 rows mounted at once. */
|
|
3779
|
+
.fd-vlist-row {
|
|
3780
|
+
position: absolute;
|
|
3781
|
+
top: 0;
|
|
3782
|
+
left: 0;
|
|
3783
|
+
right: 0;
|
|
3784
|
+
transition: transform var(--dur-base) var(--ease);
|
|
3785
|
+
}
|
|
3786
|
+
.fd-vlist-row-content {
|
|
3787
|
+
/* Shorter than the row's own fixed slot, not 100% of it — the leftover space
|
|
3788
|
+
at the bottom of each slot is what reads as a gap between cards, without
|
|
3789
|
+
touching itemHeight itself (that number is load-bearing for the
|
|
3790
|
+
scroll/virtualization math in VirtualList.tsx, not just visual spacing). */
|
|
3791
|
+
height: calc(100% - 6px);
|
|
3792
|
+
}
|
|
3793
|
+
/* A freshly-added row (e.g. the destination side right after a move) gets a brief
|
|
3794
|
+
fade/scale-in instead of popping in instantly. Scale/opacity only — never
|
|
3795
|
+
`transform: translateY(...)` here, which would fight the row's own positioning
|
|
3796
|
+
transform above; this lives on the row's CONTENT wrapper, one level in. */
|
|
3797
|
+
.fd-vlist-row-enter {
|
|
3798
|
+
animation: fd-vlist-row-in var(--dur-base) var(--ease) both;
|
|
3799
|
+
}
|
|
3800
|
+
@keyframes fd-vlist-row-in {
|
|
3801
|
+
from {
|
|
3802
|
+
opacity: 0;
|
|
3803
|
+
transform: scale(0.96);
|
|
3804
|
+
}
|
|
3805
|
+
to {
|
|
3806
|
+
opacity: 1;
|
|
3807
|
+
transform: scale(1);
|
|
3808
|
+
}
|
|
3809
|
+
}
|
|
3810
|
+
@media (prefers-reduced-motion: reduce) {
|
|
3811
|
+
.fd-vlist-row {
|
|
3812
|
+
transition: none;
|
|
3813
|
+
}
|
|
3814
|
+
.fd-vlist-row-enter {
|
|
3815
|
+
animation: none;
|
|
3816
|
+
}
|
|
3817
|
+
}
|
|
3818
|
+
/* The "whole result set is being replaced" overlay (VirtualList's `refreshing`
|
|
3819
|
+
prop) — a scrim over the full panel with a small centered spinner+label card,
|
|
3820
|
+
while the PREVIOUS rows stay mounted and visible underneath. .fd-vlist-wrap is
|
|
3821
|
+
the non-scrolling positioning root (a sibling of the scrolling .fd-vlist itself)
|
|
3822
|
+
so the scrim always covers the full visible panel regardless of scroll offset. */
|
|
3823
|
+
.fd-vlist-wrap {
|
|
3824
|
+
position: relative;
|
|
3825
|
+
}
|
|
3826
|
+
.fd-vlist-refresh-scrim {
|
|
3827
|
+
position: absolute;
|
|
3828
|
+
inset: 0;
|
|
3829
|
+
display: grid;
|
|
3830
|
+
place-items: center;
|
|
3831
|
+
background: var(--scrim);
|
|
3832
|
+
border-radius: var(--r-md);
|
|
3833
|
+
z-index: 5;
|
|
3834
|
+
}
|
|
3835
|
+
.fd-vlist-refresh-card {
|
|
3836
|
+
display: flex;
|
|
3837
|
+
align-items: center;
|
|
3838
|
+
gap: 8px;
|
|
3839
|
+
padding: 10px 16px;
|
|
3840
|
+
background: var(--surface);
|
|
3841
|
+
border: 1px solid var(--border);
|
|
3842
|
+
border-radius: var(--r-md);
|
|
3843
|
+
box-shadow: var(--e-2);
|
|
3844
|
+
color: var(--text);
|
|
3845
|
+
}
|
|
3846
|
+
|
|
3847
|
+
/* EntityRow — a real card per row (not flat text): distinct surface from the
|
|
3848
|
+
list's own background, hairline border, soft rest elevation, a stronger hover
|
|
3849
|
+
elevation as the drag affordance. Same border/radius/shadow vocabulary Card
|
|
3850
|
+
itself uses (--r-md here rather than Card's --r-lg — a compact list row reads
|
|
3851
|
+
better with the tighter radius; --e-1/--e-2 are the same elevation tokens). */
|
|
3852
|
+
.fd-erow {
|
|
3853
|
+
background: var(--surface-2);
|
|
3854
|
+
border: 1px solid var(--border);
|
|
3855
|
+
border-radius: var(--r-md);
|
|
3856
|
+
box-shadow: var(--e-1);
|
|
3857
|
+
transition:
|
|
3858
|
+
box-shadow var(--dur-fast) var(--ease),
|
|
3859
|
+
border-color var(--dur-fast) var(--ease),
|
|
3860
|
+
transform var(--dur-fast) var(--ease);
|
|
3861
|
+
}
|
|
3862
|
+
.fd-erow:hover {
|
|
3863
|
+
border-color: var(--border-strong);
|
|
3864
|
+
box-shadow: var(--e-2);
|
|
3865
|
+
}
|
|
3866
|
+
.fd-erow[draggable="true"]:active {
|
|
3867
|
+
cursor: grabbing;
|
|
3868
|
+
}
|
|
3869
|
+
/* The dragged card itself, mid-drag (see TransferList's pointer-based custom drag
|
|
3870
|
+
— native HTML5 drag images are a static snapshot, not a live element, so a
|
|
3871
|
+
persistent tilt-and-follow needs real pointer tracking instead). */
|
|
3872
|
+
.fd-erow-dragging {
|
|
3873
|
+
box-shadow: var(--e-2);
|
|
3874
|
+
border-color: var(--border-strong);
|
|
3875
|
+
}
|
|
3876
|
+
/* The gray placeholder left in a dragged row's original slot — reads as an
|
|
3877
|
+
obviously-empty slot, not a still-there-but-faded real row. */
|
|
3878
|
+
.fd-erow-placeholder {
|
|
3879
|
+
height: 100%;
|
|
3880
|
+
border-radius: var(--r-md);
|
|
3881
|
+
background: var(--surface-2);
|
|
3882
|
+
border: 1px dashed var(--border-strong);
|
|
3883
|
+
opacity: 0.6;
|
|
3884
|
+
}
|
|
3885
|
+
|
|
3886
|
+
/* TransferList's full-panel drop overlay — extends the existing subtle
|
|
3887
|
+
dragOverSide border-color change into real visual weight: a dashed blue
|
|
3888
|
+
border and a translucent brand scrim across the WHOLE target side, with
|
|
3889
|
+
a centered card (not bare text) telling the user what dropping here does —
|
|
3890
|
+
the same "small card floating over the list" language the refresh overlay
|
|
3891
|
+
already uses, so the two read as one consistent pattern. */
|
|
3892
|
+
.fd-tlist-drop-overlay {
|
|
3893
|
+
position: absolute;
|
|
3894
|
+
inset: 6px;
|
|
3895
|
+
display: grid;
|
|
3896
|
+
place-items: center;
|
|
3897
|
+
border: 2px dashed var(--brand);
|
|
3898
|
+
border-radius: var(--r-md);
|
|
3899
|
+
background: var(--surface-brand);
|
|
3900
|
+
opacity: 0.92;
|
|
3901
|
+
z-index: 6;
|
|
3902
|
+
pointer-events: none;
|
|
3903
|
+
text-align: center;
|
|
3904
|
+
padding: 16px;
|
|
3905
|
+
}
|
|
3906
|
+
.fd-tlist-drop-card {
|
|
3907
|
+
display: flex;
|
|
3908
|
+
align-items: center;
|
|
3909
|
+
gap: 8px;
|
|
3910
|
+
padding: 10px 16px;
|
|
3911
|
+
background: var(--surface);
|
|
3912
|
+
border: 1px solid var(--border-brand);
|
|
3913
|
+
border-radius: var(--r-md);
|
|
3914
|
+
box-shadow: var(--e-2);
|
|
3915
|
+
color: var(--brand);
|
|
3916
|
+
}
|
|
3917
|
+
|
|
3918
|
+
/* uniform staging strip — one row, scrolls sideways */
|
|
3919
|
+
.fd-filestrip {
|
|
3920
|
+
display: flex;
|
|
3921
|
+
gap: 8px;
|
|
3922
|
+
align-items: center;
|
|
3923
|
+
overflow-x: auto;
|
|
3924
|
+
overflow-y: hidden;
|
|
3925
|
+
padding: 1px 1px 3px;
|
|
3926
|
+
}
|
|
3762
3927
|
.fd-cell {
|
|
3763
3928
|
position: relative;
|
|
3764
3929
|
flex: none;
|