@signal9/era-ui 1.11.0 → 1.11.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/ui/pane/pane-root.svelte +15 -14
- package/package.json +1 -1
|
@@ -84,13 +84,14 @@
|
|
|
84
84
|
// TEMP: show the grab zones while developing. Flip to false to hide them.
|
|
85
85
|
const SHOW_RESIZE_ZONES = true;
|
|
86
86
|
|
|
87
|
-
// Resize handles
|
|
88
|
-
//
|
|
89
|
-
//
|
|
90
|
-
//
|
|
91
|
-
//
|
|
92
|
-
//
|
|
93
|
-
//
|
|
87
|
+
// Resize handles. Every strip protrudes xs-inset-sm (= sp/2, the same inset
|
|
88
|
+
// that gaps the close button from the pane edge) OUTSIDE the pane. n + w are
|
|
89
|
+
// that thin outward-only. s + e straddle (translate ±50%, double thickness)
|
|
90
|
+
// so they also reach xs-inset-sm INWARD — on the right, filling the close-
|
|
91
|
+
// button gap up to the button's edge. Corners are h-md/2 squares filling the
|
|
92
|
+
// four diagonal gaps. `dir` is any of n/s/e/w; a 2-letter dir is a corner.
|
|
93
|
+
// Handles live in a layer aligned to the pane's border box (markup) and are
|
|
94
|
+
// data-pane-control so they never start a pane drag.
|
|
94
95
|
type ResizeDir = 'n' | 's' | 'e' | 'w' | 'ne' | 'nw' | 'se' | 'sw';
|
|
95
96
|
const RESIZE_HANDLES: { dir: ResizeDir; cursor: string; place: string }[] = [
|
|
96
97
|
// edges FIRST so the corners (rendered after) paint on top of them and win
|
|
@@ -101,25 +102,25 @@
|
|
|
101
102
|
{
|
|
102
103
|
dir: 'n',
|
|
103
104
|
cursor: 'cursor-ns-resize',
|
|
104
|
-
place: 'top:0;left:0;right:0;translate:0 -100%;height:
|
|
105
|
+
place: 'top:0;left:0;right:0;translate:0 -100%;height:var(--era-xs-inset-sm)'
|
|
105
106
|
},
|
|
106
107
|
{
|
|
107
108
|
dir: 's',
|
|
108
109
|
cursor: 'cursor-ns-resize',
|
|
109
|
-
place: 'bottom:0;left:0;right:0;translate:0 50%;height:calc(var(--era-
|
|
110
|
+
place: 'bottom:0;left:0;right:0;translate:0 50%;height:calc(var(--era-xs-inset-sm)*2)'
|
|
110
111
|
},
|
|
111
112
|
{
|
|
112
113
|
dir: 'w',
|
|
113
114
|
cursor: 'cursor-ew-resize',
|
|
114
|
-
place: 'left:0;top:0;bottom:0;translate:-100% 0;width:
|
|
115
|
+
place: 'left:0;top:0;bottom:0;translate:-100% 0;width:var(--era-xs-inset-sm)'
|
|
115
116
|
},
|
|
116
117
|
{
|
|
117
|
-
//
|
|
118
|
-
//
|
|
118
|
+
// Rises to top:0 (no inset) so its inward half overlays the close-button
|
|
119
|
+
// row — reaching exactly the button's edge, filling the gap on the left
|
|
120
|
+
// of the pane edge without covering the button.
|
|
119
121
|
dir: 'e',
|
|
120
122
|
cursor: 'cursor-ew-resize',
|
|
121
|
-
place:
|
|
122
|
-
'right:0;top:var(--era-h-sm);bottom:0;translate:50% 0;width:calc(var(--era-h-md)/2)'
|
|
123
|
+
place: 'right:0;top:0;bottom:0;translate:50% 0;width:calc(var(--era-xs-inset-sm)*2)'
|
|
123
124
|
},
|
|
124
125
|
// corners LAST — a square at each corner (diagonal gap filler), painted
|
|
125
126
|
// above the edges so the red grab zone is always on top of the blue.
|