ArcaneGallery class

A themeable masonry gallery of media tiles.

The active stylesheet decides the tile FRAME and the surface: Windows 95 renders titled windows on a teal desktop, shadcn renders clean cards, neubrutalism renders hard-shadow blocks, neon renders neutral frames. Arcane owns the frame, the title/meta placement, and the layout; the consumer fills the media (ArcaneGalleryTile.mediaChild or ArcaneGalleryMedia.src) and the app-specific slots (ArcaneGalleryTile.overlay, ArcaneGalleryTile.footer).

Layout is CSS-grid masonry by default (works with zero JS). Set packing to enable the opt-in ratio-aware packer with squared-off bottoms. It requires the app to include arcane's fallback scripts. Packed galleries can use minimumTileArea and targetTileArea, measured as column span times row span, to keep artwork at a fairer visual weight while aspect ratio chooses its shape. Set draggableTiles to let users reposition tiles within the gallery. Windows 95 uses its visible title bar as the pointer handle; card-style themes use the tile surface. Dragging also requires the fallback scripts. Give the gallery an id and reorderable tiles a stable ArcaneGalleryTile.dragId to retain offsets across complete DOM replacement.

Inheritance

Constructors

ArcaneGallery({String? id, required List<ArcaneGalleryTile> tiles, required String ariaLabel, ArcaneGalleryLayout layout = ArcaneGalleryLayout.masonry, bool packing = false, bool draggableTiles = false, double dragKeyboardStep = 16, double dragInset = 4, double minColumnWidth = 220, int? minimumTileArea, int? targetTileArea, String classes = '', Key? key})
const

Properties

ariaLabel String
final
classes String
final
draggableTiles bool
final
dragInset double
final
dragKeyboardStep double
final
hashCode int
The hash code for this object.
no setterinherited
id String?
Stable DOM/state id for preserving drag offsets across root rerenders.
final
key Key?
Controls how one component replaces another component in the tree.
finalinherited
layout ArcaneGalleryLayout
final
minColumnWidth double
final
minimumTileArea int?
final
packing bool
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
targetTileArea int?
final
tiles List<ArcaneGalleryTile>
final

Methods

build(BuildContext context) Widget
Describes the part of the user interface represented by this component.
override
createElement() Element
Creates a StatelessElement to manage this component's location in the tree.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
shouldRebuild(covariant Component newComponent) bool
Implement this method to determine whether a rebuild can be skipped.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited