Lay the studio out as v3e did: compact view list, panels as cards, view lists in the left column

This commit is contained in:
piexel committed 2026-11-10 20:56:34 +01:00
1 parent eb801acd86
commit bce3142517
15 files changed
+138 -91

No files matched your search

@@ -78,7 +78,7 @@ export function EntryBrowser({ title, entries, current, onSelect, fileActions, c
</div>
)
return (
<section data-entry-browser className={cn('flex min-h-0 flex-col border-b', className)}>
<section data-entry-browser className={cn('flex min-h-0 flex-col', className)}>
<header className="px-4 pt-2.5 pb-2.5">
<div className="flex items-center gap-1">
<h2 className="min-w-0 flex-1 truncate text-[13px] font-semibold">{title}</h2>
+14 -7
View File
@@ -18,6 +18,7 @@ import { SceneStudio } from './SceneStudio'
import { WorldStudio3D } from './WorldStudio3D'
import { isTypingInto, shortcutRows, viewOfShortcutId, windowShortcutFor, type ShortcutAction } from './shortcuts'
import { ShortcutSettings } from './ShortcutSettings'
import { Panel, SidebarPanel, SidebarSlot } from './Sidebar'
import { StatusBar } from './StatusBar'
import { StudioToolbar } from './StudioToolbar'
import { useBindings } from './useBindings'
@@ -66,6 +67,7 @@ export function MapStudio({ client, world, theme, onDisconnect }: MapStudioProps
const [packRevision, setPackRevision] = useState(0)
const [sceneSummary, setSceneSummary] = useState<string | null>(null)
const [sceneProgress, setSceneProgress] = useState<number | null>(null)
const [sidebarSlot, setSidebarSlot] = useState<HTMLElement | null>(null)
const loadSceneViews = useCallback(() => client.sceneViews(), [client])
const loadPatternViews = useCallback(() => client.patternViews(), [client])
const sceneViews = useModuleViews(loadSceneViews, packRevision)
@@ -225,10 +227,14 @@ export function MapStudio({ client, world, theme, onDisconnect }: MapStudioProps
onSettings={() => setSettingsOpen(true)}
onDisconnect={onDisconnect}
/>
<div className="flex min-h-0 flex-1">
<ViewList views={views} current={viewId} onSelect={selectView}>
{viewId === 'regions' && regions.length > 1 && <RegionPreviewList regions={regions} current={layer.preview} onSelect={selectPreview} />}
</ViewList>
<SidebarSlot.Provider value={sidebarSlot}>
<div className="flex min-h-0 flex-1 gap-1.5 p-1.5">
<ViewList views={views} current={viewId} onSelect={selectView} slotRef={setSidebarSlot} />
{viewId === 'regions' && regions.length > 1 && (
<SidebarPanel className="flex-1 overflow-y-auto p-1.5">
<RegionPreviewList regions={regions} current={layer.preview} onSelect={selectPreview} />
</SidebarPanel>
)}
{sceneView !== null ? (
<SceneStudio client={client} view={sceneView} packRevision={packRevision} onSummary={setSceneSummary} tell={tell} />
) : patternView !== null ? (
@@ -241,7 +247,7 @@ export function MapStudio({ client, world, theme, onDisconnect }: MapStudioProps
<NoiseStudio client={client} packRevision={packRevision} onSummary={setSceneSummary} tell={tell} />
) : (
<>
<div className="relative min-w-0 flex-1">
<div className="relative min-w-0 flex-1 overflow-hidden rounded-lg">
<MapCanvas
client={client}
world={world}
@@ -273,7 +279,7 @@ export function MapStudio({ client, world, theme, onDisconnect }: MapStudioProps
</div>
)}
</div>
<aside className="flex w-[250px] shrink-0 flex-col border-l bg-card">
<Panel className="w-[250px]">
{inspectsPicks && (
<PickInspector
title={previewName ?? view.label}
@@ -287,10 +293,11 @@ export function MapStudio({ client, world, theme, onDisconnect }: MapStudioProps
shares={shares}
selection={{ highlight, onSelect: (subject) => setHighlight((current) => (sameSubject(current, subject) ? null : subject)) }}
/>
</aside>
</Panel>
</>
)}
</div>
</SidebarSlot.Provider>
<StatusBar viewLabel={statusLabel(view.label, previewName, showsMap ? null : sceneSummary)} status={showsMap ? status : null} notice={notice} usage={usage} progress={showsMap ? null : sceneProgress} />
<HelpDialog open={helpOpen} onOpenChange={setHelpOpen} views={views} />
<ShortcutSettings open={settingsOpen} onOpenChange={setSettingsOpen} views={views} />
+1 -1
View File
@@ -23,7 +23,7 @@ export function NodePane({ editor, entryKey, selected, onSelect }: NodePaneProps
useEditorKeys(editor, selected, locked, showAllRef, onSelect)
return (
<section className="flex min-h-0 flex-[9] flex-col border-t">
<section className="flex min-h-0 flex-[9] flex-col overflow-hidden rounded-lg bg-card">
<header className="flex h-9 shrink-0 items-center gap-2 border-b bg-card px-3">
<h2 className="text-[12px] font-semibold">Nodes</h2>
<span className="min-w-0 truncate text-[11.5px] text-secondary-text">{state?.file ?? entryKey}</span>
@@ -15,6 +15,7 @@ import { focusAround, type TerrainStyle } from '../scene/terrainStream'
import { hexColor } from './colors'
import { SceneViewport } from './SceneViewport'
import { TiledCanvas } from './TiledCanvas'
import { Panel, SidebarPanel } from './Sidebar'
import { useTerrainStream } from './useTerrainStream'
type NoiseDisplay = 'flat' | 'terrain'
@@ -83,7 +84,7 @@ export function NoiseStudio({ client, packRevision, onSummary, tell }: NoiseStud
return (
<>
<div className="relative min-w-0 flex-1">
<div className="relative min-w-0 flex-1 overflow-hidden rounded-lg">
<TiledCanvas
create={createView}
viewRef={controllerRef}
@@ -110,15 +111,17 @@ export function NoiseStudio({ client, packRevision, onSummary, tell }: NoiseStud
</div>
{display === 'flat' && status !== null && source !== null && <div className={cn(PILL, 'right-3 bottom-3 tabular-nums')}>{readout(status, source)}</div>}
</div>
<aside className="flex w-[250px] shrink-0 flex-col border-l bg-card">
<SidebarPanel className="flex-1">
<header className="px-4 pt-2.5 pb-2.5">
<h2 className="text-[13px] font-semibold">Noise</h2>
<p className="text-[11.5px] text-secondary-text">{NUMBER.format(sources.length)} sources</p>
</header>
<SourceList sources={sources} current={source?.id ?? null} onSelect={setChosenId} />
</SidebarPanel>
<Panel className="w-[250px]">
<SeedField seed={seed} usesSeed={source?.usesSeed ?? true} onChange={setSeed} />
<PaletteList current={paletteId} source={source} scale={scale} onSelect={setPaletteId} />
<SourceList sources={sources} current={source?.id ?? null} onSelect={setChosenId} />
</aside>
</Panel>
</>
)
}
@@ -11,6 +11,7 @@ import { BlockModels } from '../scene/blockModels'
import { BridgeAssets } from '../scene/BridgeAssets'
import { hexColor } from './colors'
import { EntryBrowser } from './EntryBrowser'
import { Panel, SidebarPanel } from './Sidebar'
import { TiledCanvas } from './TiledCanvas'
const DEFAULT_NAMESPACE_PREFIX = 'minecraft:'
@@ -61,7 +62,7 @@ export function PatternStudio({ client, view, packRevision, onSummary, tell }: P
return (
<>
<div className="relative min-w-0 flex-1">
<div className="relative min-w-0 flex-1 overflow-hidden rounded-lg">
<TiledCanvas create={createView} viewRef={viewRef} className="absolute inset-0 size-full cursor-grab active:cursor-grabbing" />
<div className="absolute top-3 left-3 flex items-center gap-1 rounded-md border border-overlay-border bg-card/90 p-1 text-[12px] tabular-nums">
{entry !== null && entry.depths > 1 && (
@@ -83,11 +84,13 @@ export function PatternStudio({ client, view, packRevision, onSummary, tell }: P
</div>
{status !== null && entry !== null && <div className={cn(PILL, 'right-3 bottom-3 tabular-nums')}>{readout(status)}</div>}
</div>
<aside className="flex w-[250px] shrink-0 flex-col border-l bg-card">
<EntryBrowser className="flex-[6]" title={view.label} entries={entries} current={entry?.key ?? null} onSelect={(key) => setChosen({ key, depth: 0 })} />
<SidebarPanel className="flex-1">
<EntryBrowser className="flex-1" title={view.label} entries={entries} current={entry?.key ?? null} onSelect={(key) => setChosen({ key, depth: 0 })} />
</SidebarPanel>
<Panel className="w-[250px]">
<EntryFacts entry={entry} />
<Legend blocks={legend} />
</aside>
</Panel>
</>
)
}
@@ -16,6 +16,7 @@ import { savedTileSource, type SavedLayer } from '../scene/savedTileSource'
import { TerrainAtlas } from '../scene/terrainAtlas'
import { focusAround, type TerrainStyle } from '../scene/terrainStream'
import { SceneViewport } from './SceneViewport'
import { SidebarPanel } from './Sidebar'
import { useTerrainStream } from './useTerrainStream'
const NUMBER = new Intl.NumberFormat('en-US')
@@ -85,7 +86,7 @@ export function SavedWorldStudio({ client, world, onSummary, onProgress, tell }:
return (
<>
<div className="relative min-w-0 flex-1">
<div className="relative min-w-0 flex-1 overflow-hidden rounded-lg">
<SceneViewport content={content} framing={content} />
<div className="absolute top-3 left-3 flex items-center gap-2">
<ToggleGroup
@@ -113,7 +114,7 @@ export function SavedWorldStudio({ client, world, onSummary, onProgress, tell }:
{reading && chosen !== null && <div className={PILL}>Reading {chosen.name}</div>}
{!reading && chosen !== null && start === null && <div className={PILL}>Nothing finished is saved in {chosen.name}</div>}
</div>
<aside className="flex w-[250px] shrink-0 flex-col border-l bg-card">
<SidebarPanel className="flex-1">
<header className="px-4 pt-2.5 pb-2.5">
<h2 className="text-[13px] font-semibold">Saved worlds</h2>
<p className="text-[11.5px] text-secondary-text">{NUMBER.format(worlds.length)} on the server</p>
@@ -121,7 +122,7 @@ export function SavedWorldStudio({ client, world, onSummary, onProgress, tell }:
<ScrollArea className="min-h-0 flex-1 border-t">
<WorldList worlds={worlds} current={chosen?.id ?? null} onSelect={setChosenId} />
</ScrollArea>
</aside>
</SidebarPanel>
</>
)
}
+16 -14
View File
@@ -2,7 +2,6 @@ import { ChevronLeft, ChevronRight } from 'lucide-react'
import { useEffect, useMemo, useRef, useState } from 'react'
import { Button } from '@/components/ui/button'
import { ScrollArea } from '@/components/ui/scroll-area'
import { cn } from '@/lib/utils'
import type { BridgeClient } from '../bridge/BridgeClient'
import { NO_PART, type JsonPath, type SceneEntry, type SceneViewInfo } from '../bridge/types'
import { parsedText } from '../editor/jsonValues'
@@ -21,6 +20,7 @@ import { EntryBrowser } from './EntryBrowser'
import { useEntryFiles } from './EntryFileDialogs'
import { NodeInspector } from './NodeInspector'
import { NodePane } from './NodePane'
import { Panel, SidebarPanel } from './Sidebar'
import { SceneViewport, type PickedSurface } from './SceneViewport'
const NUMBER = new Intl.NumberFormat('en-US')
@@ -103,7 +103,18 @@ export function SceneStudio({ client, view, packRevision, onSummary, tell }: Sce
return (
<>
<div className="flex min-w-0 flex-1 flex-col">
<SidebarPanel className="flex-1">
<EntryBrowser
className="flex-1"
title={view.label}
entries={entries}
current={entry?.key ?? null}
onSelect={(key) => setChosen({ key, variant: 0 })}
fileActions={view.creatable ? files.actions : undefined}
/>
{files.dialogs}
</SidebarPanel>
<div className="flex min-w-0 flex-1 flex-col gap-1.5">
<SceneArea
entry={entry}
variant={variant}
@@ -124,23 +135,14 @@ export function SceneStudio({ client, view, packRevision, onSummary, tell }: Sce
/>
)}
</div>
<aside className={cn('flex shrink-0 flex-col border-l bg-card', view.editable ? 'w-[300px]' : 'w-[250px]')}>
<EntryBrowser
className={selected === null ? 'flex-[7]' : 'flex-[3]'}
title={view.label}
entries={entries}
current={entry?.key ?? null}
onSelect={(key) => setChosen({ key, variant: 0 })}
fileActions={view.creatable ? files.actions : undefined}
/>
{files.dialogs}
<Panel className={view.editable ? 'w-[300px]' : 'w-[250px]'}>
{view.baked && entry !== null && <BakeMeter timing={bakeTiming} />}
{selected !== null && editor.state !== null ? (
<NodeInspector key={JSON.stringify(selected.path)} node={selected} state={editor.state} values={values} suggestions={suggestions} onEdit={editor.edit} />
) : (
<BlockList scene={scene} farLeavesOnly={farLeavesOnly} onFarLeavesOnly={setFarLeavesOnly} />
)}
</aside>
</Panel>
</>
)
}
@@ -158,7 +160,7 @@ interface SceneAreaProps {
function SceneArea({ entry, variant, shown, status, onVariant, onPick }: SceneAreaProps): React.JSX.Element {
return (
<div className="relative min-h-0 flex-[11]">
<div className="relative min-h-0 flex-[11] overflow-hidden rounded-lg">
<SceneViewport content={shown?.mesh.content ?? null} framing={shown?.scene} onPick={onPick} />
{entry !== null && entry.variants > 1 && (
<div className="absolute top-3 left-3 flex items-center gap-1 rounded-md border border-overlay-border bg-card/90 p-1 text-[12px] tabular-nums">
@@ -0,0 +1,20 @@
import { createContext, useContext } from 'react'
import { createPortal } from 'react-dom'
import { cn } from '@/lib/utils'
/** Where a view puts its own lists: under the views in the left column, as in v3e. */
export const SidebarSlot = createContext<HTMLElement | null>(null)
/** One card in the left column under the views, filled by the view that is shown. */
export function SidebarPanel({ className, children }: { className?: string; children: React.ReactNode }): React.JSX.Element | null {
const slot = useContext(SidebarSlot)
if (slot === null) {
return null
}
return createPortal(<section className={cn('flex min-h-0 flex-col overflow-hidden rounded-lg bg-card', className)}>{children}</section>, slot)
}
/** A card in the shell: the panels sit apart on the window background instead of sharing borders. */
export function Panel({ className, children }: { className?: string; children: React.ReactNode }): React.JSX.Element {
return <aside className={cn('flex shrink-0 flex-col overflow-hidden rounded-lg bg-card', className)}>{children}</aside>
}
+1 -1
View File
@@ -20,7 +20,7 @@ const NUMBER = new Intl.NumberFormat('en-US')
export function StatusBar({ viewLabel, status, notice, usage, progress }: StatusBarProps): React.JSX.Element {
const drawing = status !== null && status.tilesReady < status.tilesTotal
return (
<footer className="flex h-6 shrink-0 items-center gap-6 border-t bg-card px-3 text-[11.5px] text-secondary-text tabular-nums">
<footer className="flex h-6 shrink-0 items-center gap-6 px-3 text-[11.5px] text-secondary-text tabular-nums">
<span className="truncate">
{viewLabel}
{status !== null && (
@@ -29,10 +29,11 @@ interface StudioToolbarProps {
const THEME_ICONS: Record<ThemeChoice, ReactNode> = { system: <Monitor />, light: <Sun />, dark: <Moon /> }
const THEME_NAMES: Record<ThemeChoice, string> = { system: 'Theme: system', light: 'Theme: light', dark: 'Theme: dark' }
const TEXT_BUTTON = "h-7 gap-1.5 px-2 text-[12.5px] font-normal [&_svg:not([class*='size-'])]:size-3.5"
export function StudioToolbar(props: StudioToolbarProps): React.JSX.Element {
return (
<header className="flex h-10 shrink-0 items-center gap-1 border-b bg-card px-2">
<header className="flex h-10 shrink-0 items-center gap-1 px-2">
<span className="px-1.5 pr-3 text-[14px] font-semibold">{props.title}</span>
{props.mapTools && <MapTools {...props} />}
@@ -41,16 +42,16 @@ export function StudioToolbar(props: StudioToolbarProps): React.JSX.Element {
{props.world.world}
</span>
<IconHint hint={THEME_NAMES[props.theme.choice]}>
<Button variant="ghost" size="icon-sm" onClick={props.theme.next}>
{THEME_ICONS[props.theme.choice]}
<Button variant="ghost" size="sm" className={TEXT_BUTTON} onClick={props.theme.next}>
{THEME_ICONS[props.theme.choice]} Theme
</Button>
</IconHint>
<ToolButton action="help" hint="Show every mouse and key shortcut" onClick={props.onHelp}>
<CircleHelp />
</ToolButton>
<IconHint hint="Change the studio's keys">
<Button variant="ghost" size="icon-sm" onClick={props.onSettings}>
<Settings />
<Button variant="ghost" size="sm" className={TEXT_BUTTON} onClick={props.onSettings}>
<Settings /> Settings
</Button>
</IconHint>
<IconHint hint="Back to the world list">
+45 -43
View File
@@ -1,72 +1,74 @@
import { AudioWaveform, Box, Gem, Globe, HardDrive, Layers, Map as MapIcon, Mountain, Shapes, Sprout, Trees, Waves, type LucideIcon } from 'lucide-react'
import { Kbd } from '@/components/ui/kbd'
import { ScrollArea } from '@/components/ui/scroll-area'
import { cn } from '@/lib/utils'
import type { ViewInfo } from '../bridge/types'
import { viewShortcutId } from './shortcuts'
import { useKeyText } from './useBindings'
const VIEW_ICONS: Record<string, LucideIcon> = {
biomes: Trees,
regions: MapIcon,
height: Mountain,
world3d: Globe,
savedWorld: HardDrive,
noise: AudioWaveform,
landBiomes: Sprout,
seaBiomes: Waves,
caveBiomes: Gem,
'iris:objects': Box,
'iris:objects/procedural': Shapes,
'iris:terrain/palettes': Layers
interface ViewLook {
icon: LucideIcon
/** The icon's colour, from v3e's view palette. */
tint: string
}
const VIEW_LOOKS: Record<string, ViewLook> = {
biomes: { icon: Trees, tint: 'text-[#5fb865]' },
regions: { icon: MapIcon, tint: 'text-[#548af7]' },
height: { icon: Mountain, tint: 'text-[#c08552]' },
world3d: { icon: Globe, tint: 'text-[#4fb6c6]' },
savedWorld: { icon: HardDrive, tint: 'text-[#8c9099]' },
landBiomes: { icon: Sprout, tint: 'text-[#a3b84f]' },
seaBiomes: { icon: Waves, tint: 'text-[#4fb6c6]' },
caveBiomes: { icon: Gem, tint: 'text-[#9c7bd6]' },
'iris:terrain/palettes': { icon: Layers, tint: 'text-[#d9a23f]' },
'iris:objects': { icon: Box, tint: 'text-[#548af7]' },
'iris:objects/procedural': { icon: Shapes, tint: 'text-[#d8709a]' },
noise: { icon: AudioWaveform, tint: 'text-[#f75464]' }
}
const FALLBACK_LOOK: ViewLook = { icon: MapIcon, tint: 'text-secondary-text' }
interface ViewListProps {
views: ViewInfo[]
current: string
onSelect(view: string): void
/** What the current view adds below the views, such as the regions it can preview. */
children?: React.ReactNode
/** Receives the element the shown view fills with its own lists, under the views. */
slotRef(element: HTMLElement | null): void
}
/** The views the server offers, in its groups, each with what it shows and its key. */
export function ViewList({ views, current, onSelect, children }: ViewListProps): React.JSX.Element {
/** The left column: the views the server offers in their groups, then the shown view's own lists. */
export function ViewList({ views, current, onSelect, slotRef }: ViewListProps): React.JSX.Element {
const groups = [...new Set(views.map((view) => view.groupLabel))]
return (
<aside className="w-60 shrink-0 border-r bg-card">
<ScrollArea className="h-full">
<nav className="flex flex-col gap-3 p-2">
{groups.map((group) => (
<section key={group}>
<h2 className="px-2 pt-1 pb-1.5 text-[11px] font-semibold text-muted-foreground">{group}</h2>
{views
.filter((view) => view.groupLabel === group)
.map((view) => (
<ViewRow key={view.id} view={view} selected={view.id === current} onSelect={() => onSelect(view.id)} />
))}
</section>
))}
{children}
</nav>
</ScrollArea>
</aside>
<div className="flex w-60 shrink-0 flex-col gap-1.5">
<nav className="flex shrink-0 flex-col gap-2 overflow-y-auto rounded-lg bg-card p-1.5">
{groups.map((group) => (
<section key={group}>
<h2 className="px-2 pt-1 pb-1 text-[10.5px] font-semibold tracking-wider text-muted-foreground uppercase">{group}</h2>
{views
.filter((view) => view.groupLabel === group)
.map((view) => (
<ViewRow key={view.id} view={view} selected={view.id === current} onSelect={() => onSelect(view.id)} />
))}
</section>
))}
</nav>
<div ref={slotRef} className="flex min-h-0 flex-1 flex-col gap-1.5 empty:hidden" />
</div>
)
}
function ViewRow({ view, selected, onSelect }: { view: ViewInfo; selected: boolean; onSelect(): void }): React.JSX.Element {
const Icon = VIEW_ICONS[view.id] ?? MapIcon
const { icon: Icon, tint } = VIEW_LOOKS[view.id] ?? FALLBACK_LOOK
const keyText = useKeyText()(viewShortcutId(view.id))
return (
<button
onClick={onSelect}
className={cn('flex w-full items-start gap-2.5 rounded-md px-2 py-1.5 text-left', selected ? 'bg-selection' : 'hover:bg-accent')}
title={view.description}
className={cn('flex h-[26px] w-full items-center gap-2 rounded-md px-2 text-left', selected ? 'bg-selection' : 'hover:bg-accent')}
>
<Icon className="mt-0.5 size-4 shrink-0 text-secondary-text" />
<span className="min-w-0 flex-1">
<span className="block font-medium">{view.label}</span>
<span className="block text-[11.5px] leading-snug text-secondary-text">{view.description}</span>
</span>
{keyText !== '' && <Kbd className="mt-0.5">{keyText}</Kbd>}
<Icon className={cn('size-3.5 shrink-0', tint)} />
<span className="min-w-0 flex-1 truncate">{view.label}</span>
{keyText !== '' && <Kbd className="h-4 min-w-4 border border-input/60 bg-transparent text-[10px] uppercase">{keyText}</Kbd>}
</button>
)
}
@@ -12,6 +12,7 @@ import { Legend } from './Legend'
import { PickInspector } from './PickInspector'
import { SceneViewport } from './SceneViewport'
import { usePickInspection } from './usePickInspection'
import { Panel } from './Sidebar'
import { useGroundInView, useTerrainStream } from './useTerrainStream'
const NUMBER = new Intl.NumberFormat('en-US')
@@ -67,7 +68,7 @@ export function WorldStudio3D({ client, world, mapArea, packRevision, onSummary,
return (
<>
<div className="relative min-w-0 flex-1">
<div className="relative min-w-0 flex-1 overflow-hidden rounded-lg">
<SceneViewport content={content} framing={content} />
<ToggleGroup
type="single"
@@ -93,13 +94,13 @@ export function WorldStudio3D({ client, world, mapArea, packRevision, onSummary,
</div>
)}
</div>
<aside className="flex w-[250px] shrink-0 flex-col border-l bg-card">
<Panel className="w-[250px]">
{inspectsPicks ? (
<PickInspector title={coloring === 'regions' ? 'Regions' : 'Biomes'} inspection={inspection} />
) : (
<Legend title="Heights in view" shares={heightShares} emptyText="Looking at the ground…" className="flex-1" />
)}
</aside>
</Panel>
</>
)
}
@@ -75,7 +75,8 @@ describe('shortcuts', () => {
it('shows the first key of a shortcut', () => {
expect(keyTextOf('redo', {})).toBe('Ctrl+Y')
expect(keyTextOf('redo', { redo: ['ctrl+shift+z'] })).toBe('Ctrl+Shift+Z')
expect(keyTextOf(viewShortcutId('noise'), {})).toBe('')
expect(keyTextOf(viewShortcutId('noise'), {})).toBe('N')
expect(keyTextOf(viewShortcutId('some:module/view'), {})).toBe('')
})
it('matches the node editor keys by the live bindings', () => {
+8 -2
View File
@@ -64,14 +64,20 @@ export const SHORTCUTS: ShortcutDefinition[] = [
{ id: 'showAllNodes', label: 'Show every node', group: 'Node editor', chords: ['f', 'Home'] }
]
/** The key of each view; 4 stays free for the 3D world, as in v3e. */
/** The key of each view, as in v3e. */
const VIEW_KEYS: Record<string, Chord> = {
biomes: '1',
regions: '2',
height: '3',
world3d: '4',
landBiomes: '5',
seaBiomes: '6',
caveBiomes: '7'
caveBiomes: '7',
'iris:terrain/palettes': 'p',
'iris:objects': 'o',
'iris:objects/procedural': 't',
noise: 'n',
savedWorld: 'w'
}
export const MOUSE_HINTS: { gesture: string; label: string }[] = [
+2 -2
View File
@@ -19,7 +19,7 @@
--secondary-text: #6c707e;
--accent: #dfe1e5;
--accent-foreground: #000000;
--selection: #d4e2ff;
--selection: #d3d5db;
--destructive: #db3b4b;
--warning: #c27d04;
--success: #208a3c;
@@ -48,7 +48,7 @@
--secondary-text: #9da0a8;
--accent: #393b40;
--accent-foreground: #dfe1e5;
--selection: #2e436e;
--selection: #43454a;
--destructive: #f75464;
--warning: #f2c55c;
--success: #5fb865;