mirror of
https://github.com/olehomelchenko/astrolabe.git
synced 2026-08-08 02:02:33 +00:00
UX second pass: icon-only header, pane-toggle cue, schema columns, facet cleanup
This commit is contained in:
@@ -620,24 +620,13 @@ function MarksCard() {
|
||||
);
|
||||
}
|
||||
|
||||
/** A reserved, non-interactive shelf slot for faceting (small multiples) — Phase 4.
|
||||
* Shown so the layout telegraphs where row/column faceting will live. */
|
||||
// TODO: the "later" tag is internal roadmap language shown to users — hide the
|
||||
// affordance until faceting ships, or reword for users (docs/ux-second-pass.md).
|
||||
function FacetSlot({ kind }: { kind: 'column' | 'row' }) {
|
||||
return (
|
||||
<div className={styles.facetSlot} title="Faceting → small multiples (coming later)">
|
||||
<span>+ {kind} facet</span>
|
||||
<span className={styles.facetTag}>later</span>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* The on-chart **Columns** (X) and **Rows** (Y) shelves stacked above the preview,
|
||||
* Tableau-style — position is a property of the chart, so its controls sit on the
|
||||
* chart. Each shelf holds the axis slot plus a reserved faceting placeholder. A Swap
|
||||
* X/Y action flips the two axes.
|
||||
* chart. A Swap X/Y action flips the two axes. The slot rows are shelf-shaped so
|
||||
* Phase 4 faceting can add a second slot per shelf without a layout change, but
|
||||
* no placeholder ships before the feature does (an affordance promising unbuilt
|
||||
* functionality is a promise, not a feature — NN/g #2/#8).
|
||||
*/
|
||||
function OnChartShelves() {
|
||||
const swapXY = useChartBuilderStore((s) => s.swapXY);
|
||||
@@ -653,14 +642,12 @@ function OnChartShelves() {
|
||||
<span className={styles.shelfName}>Columns</span>
|
||||
<div className={styles.shelfSlots}>
|
||||
<ChannelSlot channel="x" hint="Add a field for the X axis" />
|
||||
<FacetSlot kind="column" />
|
||||
</div>
|
||||
</div>
|
||||
<div className={styles.shelfStrip}>
|
||||
<span className={styles.shelfName}>Rows</span>
|
||||
<div className={styles.shelfSlots}>
|
||||
<ChannelSlot channel="y" hint="Add a field for the Y axis" />
|
||||
<FacetSlot kind="row" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user