import * as tailwind_variants from 'tailwind-variants'; import { VariantProps } from 'tailwind-variants'; import * as tailwind_merge from 'tailwind-merge'; import * as i0 from '@angular/core'; import { EventEmitter, OnChanges, OnInit } from '@angular/core'; import * as _lucide_angular from '@lucide/angular'; import { SafeHtml } from '@angular/platform-browser'; /** * Styling for {@link MnCard}, as tailwind-variants slots: `root` is the card element * itself, `accent` the optional bar along its top edge, `header` the heading row and * `title` the `h2` inside it. * * Theme tokens only, so the card holds up in light and dark. The surface reads the * consumer's `--color-base-card` when it defines one (a card ground a step off the * page background) and falls back to `base-100` otherwise, the same fallback device * `mnBadge` uses for its `-text` tokens. */ declare const mnCardVariants: tailwind_variants.TVReturnType<{ /** * Inner padding, and with it the gap between the card's children: a tile needs * less air than a section card, and a section card that had to say `gap-4` on * every use would drift. */ padding: { sm: { root: string; }; md: { root: string; }; lg: { root: string; }; }; /** How the children flow: stacked (the default) or on one line, centred. */ layout: { column: { root: string; }; row: { root: string; }; }; /** * Hover response. `shadow` is a little depth for a card that only sits there; * `lift` promises a destination and belongs on a card that is a link. */ hover: { none: {}; shadow: { root: string; }; lift: { root: string; }; }; /** * Entrance. `rise` plays the consumer's `--animate-rise` keyframes when its theme * defines them (a short rise-in, delayed per card through * {@link MnCard.enterDelayMs}) and is a no-op otherwise; reduced-motion users * never see it. */ enter: { none: {}; rise: { root: string; }; }; /** Corner rounding, in mn-button's radius tokens. */ borderRadius: { none: { root: string; }; xs: { root: string; }; sm: { root: string; }; md: { root: string; }; lg: { root: string; }; xl: { root: string; }; two_xl: { root: string; }; three_xl: { root: string; }; four_xl: { root: string; }; }; /** * Colour of the accent bar and of the heading's icon chip: the same palette as * mn-button and the icon chip. What the colour *means* (a kind, a status, a * module) is the consumer's choice; the card only renders it. */ color: { primary: { accent: string; }; secondary: { accent: string; }; accent: { accent: string; }; success: { accent: string; }; warning: { accent: string; }; danger: { accent: string; }; gray: { accent: string; }; }; }, { root: string; accent: string; header: string; title: string; }, undefined, { /** * Inner padding, and with it the gap between the card's children: a tile needs * less air than a section card, and a section card that had to say `gap-4` on * every use would drift. */ padding: { sm: { root: string; }; md: { root: string; }; lg: { root: string; }; }; /** How the children flow: stacked (the default) or on one line, centred. */ layout: { column: { root: string; }; row: { root: string; }; }; /** * Hover response. `shadow` is a little depth for a card that only sits there; * `lift` promises a destination and belongs on a card that is a link. */ hover: { none: {}; shadow: { root: string; }; lift: { root: string; }; }; /** * Entrance. `rise` plays the consumer's `--animate-rise` keyframes when its theme * defines them (a short rise-in, delayed per card through * {@link MnCard.enterDelayMs}) and is a no-op otherwise; reduced-motion users * never see it. */ enter: { none: {}; rise: { root: string; }; }; /** Corner rounding, in mn-button's radius tokens. */ borderRadius: { none: { root: string; }; xs: { root: string; }; sm: { root: string; }; md: { root: string; }; lg: { root: string; }; xl: { root: string; }; two_xl: { root: string; }; three_xl: { root: string; }; four_xl: { root: string; }; }; /** * Colour of the accent bar and of the heading's icon chip: the same palette as * mn-button and the icon chip. What the colour *means* (a kind, a status, a * module) is the consumer's choice; the card only renders it. */ color: { primary: { accent: string; }; secondary: { accent: string; }; accent: { accent: string; }; success: { accent: string; }; warning: { accent: string; }; danger: { accent: string; }; gray: { accent: string; }; }; }, { root: string; accent: string; header: string; title: string; }, tailwind_variants.TVReturnType<{ /** * Inner padding, and with it the gap between the card's children: a tile needs * less air than a section card, and a section card that had to say `gap-4` on * every use would drift. */ padding: { sm: { root: string; }; md: { root: string; }; lg: { root: string; }; }; /** How the children flow: stacked (the default) or on one line, centred. */ layout: { column: { root: string; }; row: { root: string; }; }; /** * Hover response. `shadow` is a little depth for a card that only sits there; * `lift` promises a destination and belongs on a card that is a link. */ hover: { none: {}; shadow: { root: string; }; lift: { root: string; }; }; /** * Entrance. `rise` plays the consumer's `--animate-rise` keyframes when its theme * defines them (a short rise-in, delayed per card through * {@link MnCard.enterDelayMs}) and is a no-op otherwise; reduced-motion users * never see it. */ enter: { none: {}; rise: { root: string; }; }; /** Corner rounding, in mn-button's radius tokens. */ borderRadius: { none: { root: string; }; xs: { root: string; }; sm: { root: string; }; md: { root: string; }; lg: { root: string; }; xl: { root: string; }; two_xl: { root: string; }; three_xl: { root: string; }; four_xl: { root: string; }; }; /** * Colour of the accent bar and of the heading's icon chip: the same palette as * mn-button and the icon chip. What the colour *means* (a kind, a status, a * module) is the consumer's choice; the card only renders it. */ color: { primary: { accent: string; }; secondary: { accent: string; }; accent: { accent: string; }; success: { accent: string; }; warning: { accent: string; }; danger: { accent: string; }; gray: { accent: string; }; }; }, { root: string; accent: string; header: string; title: string; }, undefined, unknown, unknown, undefined>>; type MnCardVariants = VariantProps; /** * Configuration of one {@link MnCard}. Every field is optional; the defaults give the * compact stacked tile with a soft hover, which is what most cards are. */ type MnCardTypes = { /** Inner padding and child gap. `sm` for tiles, `md` for section cards, `lg` for hero cards. */ padding: MnCardVariants['padding']; /** Stacked children (`column`, the default) or one centred line (`row`). */ layout: MnCardVariants['layout']; /** Hover response: `shadow` (default), `lift` for a card that is a link, or `none`. */ hover: MnCardVariants['hover']; /** Entrance animation: `rise` (default, needs the consumer's `--animate-rise`) or `none`. */ enter: MnCardVariants['enter']; /** Corner rounding. Defaults to `two_xl`. */ borderRadius: MnCardVariants['borderRadius']; /** Colour of the accent bar and the heading's icon chip. Defaults to `primary`. */ color: MnCardVariants['color']; /** Whether to draw the accent bar along the top edge. Defaults to false. */ accent: boolean; }; /** * The card: a rounded surface with a hairline border, a hover response and an * optional accent bar along its top edge. The body is whatever the consumer projects, * so a booking, a competition and a pending-action tile share one look without * sharing a view model. * * It is an attribute as well as an element, like `mnButton` and `mnBadge`: `` * for a plain surface, `` for a card that is a link, * `
` when the landmark matters. Extra classes on the host merge with * the card's own, so sizing it (`min-w-0 flex-1`, `lg:w-80`) is ordinary CSS on the * element, not an input. * * A **section card** passes a {@link heading}: the card then renders the shared header * row, an {@link MnIconChip} beside an `h2`, then whatever trails the title (a badge, a * button). Project the icon with the `cardIcon` attribute and group the trailing content * in one `cardHeaderEnd` container, so the template reads icon, header end, body: * * ```html * * * * Draft * * ...body... * * ``` * * The other members of the family build on this shell: {@link MnStatTile} for one * figure at a glance, and {@link MnProportionBar} for the bar inside a card. */ declare class MnCard { /** Padding, layout, hover, entrance, radius, colour and accent; see {@link MnCardTypes}. */ data: Partial; /** * Section title, as a translation key or a literal. When set, the header row with * the icon chip and `h2` renders above the body. Deliberately not called `title`: a * static `title="..."` on the host would also become a browser tooltip. */ heading?: string; /** * Delay before the entrance animation starts, in milliseconds, so a row of cards * can rise one after another. Ignored when {@link MnCardTypes.enter} is `none`. */ enterDelayMs: number; /** Resolved slot classes for the current configuration. */ get styles(): { root: (slotProps?: ({ color?: "primary" | "secondary" | "accent" | "success" | "warning" | "danger" | "gray" | undefined; padding?: "md" | "sm" | "lg" | undefined; layout?: "column" | "row" | undefined; hover?: "shadow" | "none" | "lift" | undefined; enter?: "rise" | "none" | undefined; borderRadius?: "md" | "xs" | "sm" | "lg" | "xl" | "two_xl" | "none" | "three_xl" | "four_xl" | undefined; } & tailwind_variants.ClassProp) | undefined) => string; accent: (slotProps?: ({ color?: "primary" | "secondary" | "accent" | "success" | "warning" | "danger" | "gray" | undefined; padding?: "md" | "sm" | "lg" | undefined; layout?: "column" | "row" | undefined; hover?: "shadow" | "none" | "lift" | undefined; enter?: "rise" | "none" | undefined; borderRadius?: "md" | "xs" | "sm" | "lg" | "xl" | "two_xl" | "none" | "three_xl" | "four_xl" | undefined; } & tailwind_variants.ClassProp) | undefined) => string; header: (slotProps?: ({ color?: "primary" | "secondary" | "accent" | "success" | "warning" | "danger" | "gray" | undefined; padding?: "md" | "sm" | "lg" | undefined; layout?: "column" | "row" | undefined; hover?: "shadow" | "none" | "lift" | undefined; enter?: "rise" | "none" | undefined; borderRadius?: "md" | "xs" | "sm" | "lg" | "xl" | "two_xl" | "none" | "three_xl" | "four_xl" | undefined; } & tailwind_variants.ClassProp) | undefined) => string; title: (slotProps?: ({ color?: "primary" | "secondary" | "accent" | "success" | "warning" | "danger" | "gray" | undefined; padding?: "md" | "sm" | "lg" | undefined; layout?: "column" | "row" | undefined; hover?: "shadow" | "none" | "lift" | undefined; enter?: "rise" | "none" | undefined; borderRadius?: "md" | "xs" | "sm" | "lg" | "xl" | "two_xl" | "none" | "three_xl" | "four_xl" | undefined; } & tailwind_variants.ClassProp) | undefined) => string; } & { root: (slotProps?: ({ color?: "primary" | "secondary" | "accent" | "success" | "warning" | "danger" | "gray" | undefined; padding?: "md" | "sm" | "lg" | undefined; layout?: "column" | "row" | undefined; hover?: "shadow" | "none" | "lift" | undefined; enter?: "rise" | "none" | undefined; borderRadius?: "md" | "xs" | "sm" | "lg" | "xl" | "two_xl" | "none" | "three_xl" | "four_xl" | undefined; } & tailwind_variants.ClassProp) | undefined) => string; accent: (slotProps?: ({ color?: "primary" | "secondary" | "accent" | "success" | "warning" | "danger" | "gray" | undefined; padding?: "md" | "sm" | "lg" | undefined; layout?: "column" | "row" | undefined; hover?: "shadow" | "none" | "lift" | undefined; enter?: "rise" | "none" | undefined; borderRadius?: "md" | "xs" | "sm" | "lg" | "xl" | "two_xl" | "none" | "three_xl" | "four_xl" | undefined; } & tailwind_variants.ClassProp) | undefined) => string; header: (slotProps?: ({ color?: "primary" | "secondary" | "accent" | "success" | "warning" | "danger" | "gray" | undefined; padding?: "md" | "sm" | "lg" | undefined; layout?: "column" | "row" | undefined; hover?: "shadow" | "none" | "lift" | undefined; enter?: "rise" | "none" | undefined; borderRadius?: "md" | "xs" | "sm" | "lg" | "xl" | "two_xl" | "none" | "three_xl" | "four_xl" | undefined; } & tailwind_variants.ClassProp) | undefined) => string; title: (slotProps?: ({ color?: "primary" | "secondary" | "accent" | "success" | "warning" | "danger" | "gray" | undefined; padding?: "md" | "sm" | "lg" | undefined; layout?: "column" | "row" | undefined; hover?: "shadow" | "none" | "lift" | undefined; enter?: "rise" | "none" | undefined; borderRadius?: "md" | "xs" | "sm" | "lg" | "xl" | "two_xl" | "none" | "three_xl" | "four_xl" | undefined; } & tailwind_variants.ClassProp) | undefined) => string; } & {}; /** The card element's own classes; the consumer's static classes merge with them. */ get hostClasses(): string; /** Staggers the entrance per card. */ get animationDelay(): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * Styling for {@link MnIconChip}: one 10% wash of the colour behind an icon drawn in * the consumer's `--color--text` token when it defines one (the shade it uses * for readable coloured text on a tinted ground) and in the base colour otherwise, the * same device `mnBadge` uses. The radius grows with the box so the corner reads the * same at every size. */ declare const mnIconChipVariants: tailwind_variants.TVReturnType<{ /** * `xs` for compact rows and inline labels, `sm` for list rows, `md` for section-card headers * and stat tiles, `lg` for page headers, `xl` for a lone hero or empty-state icon. */ size: { xs: string; sm: string; md: string; lg: string; xl: string; }; color: { primary: string; secondary: string; accent: string; success: string; warning: string; danger: string; gray: string; }; }, undefined, "inline-flex shrink-0 items-center justify-center", { /** * `xs` for compact rows and inline labels, `sm` for list rows, `md` for section-card headers * and stat tiles, `lg` for page headers, `xl` for a lone hero or empty-state icon. */ size: { xs: string; sm: string; md: string; lg: string; xl: string; }; color: { primary: string; secondary: string; accent: string; success: string; warning: string; danger: string; gray: string; }; }, undefined, tailwind_variants.TVReturnType<{ /** * `xs` for compact rows and inline labels, `sm` for list rows, `md` for section-card headers * and stat tiles, `lg` for page headers, `xl` for a lone hero or empty-state icon. */ size: { xs: string; sm: string; md: string; lg: string; xl: string; }; color: { primary: string; secondary: string; accent: string; success: string; warning: string; danger: string; gray: string; }; }, undefined, "inline-flex shrink-0 items-center justify-center", unknown, unknown, undefined>>; type MnIconChipVariants = VariantProps; /** Configuration of one {@link MnIconChip}. Both fields are optional. */ type MnIconChipTypes = { /** Box size. Defaults to `md`. */ size: MnIconChipVariants['size']; /** Colour of the wash and the icon. Defaults to `primary`. */ color: MnIconChipVariants['color']; }; /** * The tinted square that carries an icon in front of a card title, a stat or a list * row: the one place a colour says "what kind of thing this is". Project the icon as * content; the chip sizes and tints itself and never grows with the row. * * Decorative for assistive technology: the title or label beside it carries the * meaning, so the chip is `aria-hidden` and a screen reader never meets a bare icon. * * ```html * * * * ``` */ declare class MnIconChip { /** Size and colour; see {@link MnIconChipTypes}. */ data: Partial; /** The chip's own classes; the consumer's static classes merge with them. */ get hostClasses(): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** Configuration of one {@link MnStatTile}. */ type MnStatTileTypes = { /** Colour of the chip; the number itself stays in the base text colour. Defaults to `primary`. */ color: MnIconChipVariants['color']; }; /** * One fact at a glance: a tinted icon chip, a muted label and a large tabular number, * on the {@link MnCard} shell, in a tile that shares a row with its siblings as * `flex-1`. Project the icon as content; project a badge or a short note into the * `trailing` slot when the number needs a qualifier. * * ```html *
* * * *
* ``` */ declare class MnStatTile { /** Caption under the number, as a translation key or a literal. */ label: string; /** The figure, already formatted for display. */ value: string | number; /** Colour of the chip; see {@link MnStatTileTypes}. */ data: Partial; /** Grows to share its row and never forces the row wider than its siblings. */ readonly hostClasses = "flex flex-1 basis-40 min-w-0"; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** One coloured run of a {@link MnProportionBar}: how much of the whole it covers, and in which colour. */ type MnProportionSegment = { /** Amount in the same unit as the other segments and the total. */ value: number; /** Colour of this run; `gray` for the part that has no answer yet. */ color: NonNullable; /** * Draw the run as a pale tint of its colour instead of solid. For a part that is on its way but * not there yet, next to a solid run of the same colour: spots asked about but not answered, * payments announced but not received. */ soft?: boolean; }; /** Configuration of one {@link MnProportionBar}. */ type MnProportionBarTypes = { /** Track thickness: `sm` inside dense rows, `md` (default) under a section title. */ height: 'sm' | 'md'; }; /** A segment resolved to a rendered width. */ type MnRenderedProportionSegment = { /** Percentage of the track this run covers. */ widthPct: number; /** Fill class for the run. */ fillClass: string; }; /** * The proportional bar every turnout, budget, capacity and collection figure draws: * a rounded track with one coloured run per segment, widths from the values. Empty * segments are skipped so a zero never leaves a hairline. Announced as one image with * the caller's label, because the numbers it visualises are always written out next * to it. * * ```html * * * ``` */ declare class MnProportionBar { /** The coloured runs, in draw order from the left. */ segments: MnProportionSegment[]; /** The whole the segments are measured against; defaults to their sum. */ total?: number | null; /** Accessible name for the bar as a whole, as a translation key or a literal. */ ariaLabel: string; /** Track thickness; see {@link MnProportionBarTypes}. */ data: Partial; /** Resolves the accessible name against the app's bundle. */ private readonly lang; /** The translated accessible name. */ get label(): string; /** Every class on the track element. */ get trackClass(): string; /** The denominator actually used: the explicit total when positive, else the segment sum. */ private get denominator(); /** Segments with a width, empty ones dropped. */ get rendered(): MnRenderedProportionSegment[]; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * A single crumb in the breadcrumb trail. * * A crumb becomes a link when it carries an {@link href}; otherwise it renders * as a button that only emits {@link MnBreadcrumbs.crumbClick} / runs * {@link onClick}. The library stays router-agnostic — an app wires SPA * navigation through `onClick`/`crumbClick`, or lets the `href` anchor navigate. */ type MnBreadcrumbItem = { /** Translation key or literal label for the crumb. */ label: string; /** Optional link target; when set the crumb renders as an `
`. */ href?: string; /** Optional callback invoked on click (fires alongside `crumbClick`). */ onClick?: () => void; }; /** * Data source for {@link MnBreadcrumbs}. * * When {@link items} holds crumbs the component renders a linkable trail whose * **last** item is the current page (never a link). When `items` is empty the * component degrades to a single "Back" control: it navigates to * {@link backHref} when given, otherwise steps back through browser history. */ type MnBreadcrumbsData = { /** Ordered crumbs root → current. Empty ⇒ the "Back" fallback renders instead. */ items: MnBreadcrumbItem[]; /** Fallback "Back" target. Set ⇒ renders ``; unset ⇒ `history.back()`. */ backHref?: string; /** Translation key or literal for the "Back" label. Defaults to `'back'`. */ backLabel?: string; /** Visual scale. Defaults to `'md'`. */ size?: 'sm' | 'md'; /** * What the trail does on a narrow screen (below `sm`). Defaults to `'parent'`: * the crumbs give way to the parent crumb alone, drawn as a back control, * because a hierarchy read on a phone is a way up rather than a map, and an * uncollapsed trail wraps over three lines above the title it belongs to. * `'never'` keeps every crumb at every width, for a page where the trail * itself is the content. */ collapse?: 'parent' | 'never'; }; /** * A flexible breadcrumb trail. * * Given crumbs it renders a linkable trail (`root › … › current`) where the last * crumb is the current page and is never a link. Given no crumbs it degrades to * a single "Back" control — the two are mutually exclusive. * * The one thing a width decides is how much of the trail shows: below `sm` the * crumbs give way to the parent crumb alone, drawn as a back control, unless * `data.collapse` is `'never'`. That measures nothing — both renderings sit in * the DOM and a Tailwind breakpoint hides one — and there is deliberately no * scroll machinery: on a phone a hierarchy is a way up rather than a map, and a * trail that scrolls sideways buries the one link anybody reaches for. * * Navigation stays router- and history-agnostic where possible: a crumb (or the * Back control) with an `href` renders a plain `` and navigates natively; * otherwise clicks emit outputs for the app to handle. Only the Back fallback * with no `href` reaches for `history.back()`. */ declare class MnBreadcrumbs { /** Lucide icons the template renders. */ protected readonly icons: Record<"ChevronLeft" | "ChevronRight", _lucide_angular.LucideIconData>; /** Trail crumbs and Back-fallback configuration. */ data: MnBreadcrumbsData; /** Emits the crumb that was clicked (non-current crumbs only). */ crumbClick: EventEmitter; /** Emits when the fallback "Back" control is activated. */ back: EventEmitter; /** Conventional key an app defines to translate the Back control's label. */ private static readonly BACK_LABEL_KEY; /** Conventional key an app defines to name the navigation landmark. */ private static readonly NAV_LABEL_KEY; /** Resolves this component's own labels against the app's bundle. */ private readonly lang; /** Resolved tailwind-variants slot functions for the current size. */ get styles(): { root: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; list: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; link: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; current: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; separator: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; back: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; collapsed: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; } & { root: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; list: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; link: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; current: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; separator: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; back: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; collapsed: (slotProps?: ({ size?: "md" | "sm" | undefined; collapsible?: boolean | undefined; } & tailwind_variants.ClassProp) | undefined) => string; } & {}; /** Whether the parent crumb replaces the trail below `sm`. */ get collapsesToParent(): boolean; /** * The crumb one level above the current page, or `null` when the trail stays * whole: a single crumb has nowhere to go up to, and `'never'` asks for every * crumb at every width. */ get parentCrumb(): MnBreadcrumbItem | null; /** * Accessible name of the `