@dloizides/ui-nav 1.26.2 → 1.28.0

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/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.28.0
4
+
5
+ - INVOICE-5 "Edit invoices before sending, shared background and menu hover" (AC-UI-3, AC-UI-6): `AppShell` draws `theme.backdrop` (the `@dloizides/theme-web` 1.5.0 `resolveBackdrop` shape, typed here as `AppShellBackdrop`): its colour and web image on the root, and for `horizon` a brand band behind header and nav that the content overlaps by `overlap.compact` (< 768 px) or `overlap.wide`. No `theme.backdrop` keeps today's flat background.
6
+
7
+ ## 1.27.0
8
+
9
+ - INVOICE-5 "Edit invoices before sending, shared background and menu hover" (AC-UI-2, AC-UI-6): `NavBar` takes `hoverFeedback` (`NavHoverFeedback`: `default`, `tint-pill`, `underline`, `lift`, `sliding-highlight`); the new phone `BottomTabBar` takes `tabFeedback` (`TabFeedback`: `default`, `indicator-pill`, `dim-spring`, `sliding-bar`, `icon-lift`). Timings come from the `@dloizides/ui-motion` tokens (<= 300 ms); reduced motion keeps every option still. `default` keeps today's look, so existing apps do not change.
10
+
3
11
  ## 1.26.2
4
12
 
5
13
  - KEFI-LAUNCH-1 "Do every open Kefi task before the public launch": a long account name no longer overlaps the `Topbar` center slot at 360 px. The center slot keeps its content width (`flexShrink: 0`); only the account name gives way. The overlap dates from 1.24.0, when the slot was added.
package/dist/index.d.mts CHANGED
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { ViewStyle } from 'react-native';
2
+ import { ViewStyle, StyleProp } from 'react-native';
3
3
  import { UiTheme } from '@dloizides/ui-feedback';
4
4
  import { DropdownVariant } from '@dloizides/ui-layout';
5
5
  import { resolveAccessibleRoutes, RoleRouteTable, RoleRoute } from '@dloizides/auth-web';
@@ -363,6 +363,14 @@ interface TopbarProps {
363
363
  }
364
364
  declare const Topbar: ({ left, center, language, notificationSlot, user, account, logout, containerStyle, }: TopbarProps) => React.ReactElement;
365
365
 
366
+ declare enum NavHoverFeedback {
367
+ Default = "default",
368
+ TintPill = "tint-pill",
369
+ Underline = "underline",
370
+ Lift = "lift",
371
+ SlidingHighlight = "sliding-highlight"
372
+ }
373
+
366
374
  /**
367
375
  * NavBar — the config-driven HORIZONTAL top navigation bar. It is the top-bar
368
376
  * counterpart to `Sidebar`: it renders the SAME caller-supplied `NavItem[]`
@@ -445,6 +453,7 @@ interface NavBarProps {
445
453
  * theme. Style-only: every colour still flows through the theme — no per-app fork.
446
454
  */
447
455
  barTheme?: UiTheme;
456
+ hoverFeedback?: NavHoverFeedback;
448
457
  }
449
458
  /**
450
459
  * `NavBar` — the horizontal top bar. When `barTheme` is supplied it re-provisions
@@ -1076,6 +1085,21 @@ interface NavOverflowMenuProps {
1076
1085
  }
1077
1086
  declare const NavOverflowMenu: ({ items, pathname, onNavigate, colors, label, hint, testID, variant, }: NavOverflowMenuProps) => React.ReactElement;
1078
1087
 
1088
+ interface AppShellBackdropBand {
1089
+ color: string;
1090
+ text: string;
1091
+ overlap: {
1092
+ compact: number;
1093
+ wide: number;
1094
+ };
1095
+ }
1096
+ interface AppShellBackdrop {
1097
+ color: string;
1098
+ image: string | null;
1099
+ imageSize: string | null;
1100
+ band: AppShellBackdropBand | null;
1101
+ }
1102
+
1079
1103
  /**
1080
1104
  * Default testIDs for `@dloizides/ui-nav`. Kept as a small central map (mirrors
1081
1105
  * `@dloizides/ui-layout`'s `LAYOUT_TEST_IDS`) so the app-agnostic chrome exposes
@@ -1123,6 +1147,7 @@ declare const APP_SHELL_SUFFIX: {
1123
1147
  readonly loading: "-loading";
1124
1148
  readonly error: "-error";
1125
1149
  readonly forbidden: "-forbidden";
1150
+ readonly band: "-backdrop-band";
1126
1151
  };
1127
1152
 
1128
1153
  /**
@@ -1598,4 +1623,25 @@ declare const NAV_ICON_SIZE = 14;
1598
1623
  /** Chevron icon size for expandable sections. */
1599
1624
  declare const CHEVRON_ICON_SIZE = 12;
1600
1625
 
1601
- export { ACTIVE_BORDER_RADIUS, ACTIVE_TINT_OPACITY, APP_SHELL_SUFFIX, type AccountPlan, type AccountState, AppShell, type AppShellProps, type AppShellWidth, BASE_INDENT, CHEVRON_ICON_SIZE, CollapsedRail, type CollapsedRailProps, type CollapsedRailRange, type CommandItem, CommandPalette, type CommandPaletteLabels, type CommandPaletteProps, CommandPaletteTrigger, type CommandPaletteTriggerProps, DEFAULT_COLLAPSED_RAIL_MAX, DEFAULT_SEARCH_BREAKPOINT, DarkModeControl, type DarkModeControlProps, type DarkModeOption, type DarkModeVariant, HOVER_TINT_OPACITY, NAV_ICON_SIZE, NAV_LINK_GAP, NAV_ROW_RADIUS, NAV_TEST_IDS, Nav, NavBar, type NavBarProps, NavExpandableItem, type NavExpandableItemProps, type NavItem, type NavOrientation, NavOverflowMenu, type NavOverflowMenuProps, type NavProps, NavShell, type NavShellCollapsedRail, type NavShellLayout, type NavShellProps, type NavShellSideRail, type NavShellTopBar, type NavUser, PillNav, type PillNavProps, PillNavVariant, RAIL_FULL_BREAKPOINT, type RailMode, type ResolveRailModeArgs, type SearchAffordance, type ShellMessage, Sidebar, SidebarChevron, type SidebarChevronProps, type SidebarPaletteTriggerConfig, type SidebarProps, SidebarSearch, type SidebarSearchConfig, type SidebarSearchLabels, type SidebarSearchProps, Topbar, type TopbarAction, type TopbarProps, type TopbarUser, accessibleNavItems, collapsedRailStyles, darkModeStyles, expandableStyles, filterCommands, filterNavItems, isFilterActive, isRouteActive, navStyles, pillNavStyles, resolveActiveRoute, resolveContentMaxWidth, resolvePillMenuLabel, resolveRailMode, resolveSearchAffordance, roleRoutesToNavItems, searchTokens, useCommandPaletteHotkey, useContentMaxWidth };
1626
+ declare enum TabFeedback {
1627
+ Default = "default",
1628
+ IndicatorPill = "indicator-pill",
1629
+ DimSpring = "dim-spring",
1630
+ SlidingBar = "sliding-bar",
1631
+ IconLift = "icon-lift"
1632
+ }
1633
+
1634
+ interface BottomTabBarProps {
1635
+ items: NavItem[];
1636
+ pathname: string;
1637
+ onNavigate: (route: string) => void;
1638
+ tabFeedback?: TabFeedback;
1639
+ navigateHint?: (label: string) => string;
1640
+ regionLabel?: string;
1641
+ containerStyle?: StyleProp<ViewStyle>;
1642
+ testID?: string;
1643
+ }
1644
+ /** Phone tab bar; `tabFeedback` picks the press feedback, `Default` adds no motion. */
1645
+ declare const BottomTabBar: ({ items, pathname, onNavigate, tabFeedback, navigateHint, regionLabel, containerStyle, testID, }: BottomTabBarProps) => React.ReactElement;
1646
+
1647
+ export { ACTIVE_BORDER_RADIUS, ACTIVE_TINT_OPACITY, APP_SHELL_SUFFIX, type AccountPlan, type AccountState, AppShell, type AppShellBackdrop, type AppShellBackdropBand, type AppShellProps, type AppShellWidth, BASE_INDENT, BottomTabBar, type BottomTabBarProps, CHEVRON_ICON_SIZE, CollapsedRail, type CollapsedRailProps, type CollapsedRailRange, type CommandItem, CommandPalette, type CommandPaletteLabels, type CommandPaletteProps, CommandPaletteTrigger, type CommandPaletteTriggerProps, DEFAULT_COLLAPSED_RAIL_MAX, DEFAULT_SEARCH_BREAKPOINT, DarkModeControl, type DarkModeControlProps, type DarkModeOption, type DarkModeVariant, HOVER_TINT_OPACITY, NAV_ICON_SIZE, NAV_LINK_GAP, NAV_ROW_RADIUS, NAV_TEST_IDS, Nav, NavBar, type NavBarProps, NavExpandableItem, type NavExpandableItemProps, NavHoverFeedback, type NavItem, type NavOrientation, NavOverflowMenu, type NavOverflowMenuProps, type NavProps, NavShell, type NavShellCollapsedRail, type NavShellLayout, type NavShellProps, type NavShellSideRail, type NavShellTopBar, type NavUser, PillNav, type PillNavProps, PillNavVariant, RAIL_FULL_BREAKPOINT, type RailMode, type ResolveRailModeArgs, type SearchAffordance, type ShellMessage, Sidebar, SidebarChevron, type SidebarChevronProps, type SidebarPaletteTriggerConfig, type SidebarProps, SidebarSearch, type SidebarSearchConfig, type SidebarSearchLabels, type SidebarSearchProps, TabFeedback, Topbar, type TopbarAction, type TopbarProps, type TopbarUser, accessibleNavItems, collapsedRailStyles, darkModeStyles, expandableStyles, filterCommands, filterNavItems, isFilterActive, isRouteActive, navStyles, pillNavStyles, resolveActiveRoute, resolveContentMaxWidth, resolvePillMenuLabel, resolveRailMode, resolveSearchAffordance, roleRoutesToNavItems, searchTokens, useCommandPaletteHotkey, useContentMaxWidth };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { ViewStyle } from 'react-native';
2
+ import { ViewStyle, StyleProp } from 'react-native';
3
3
  import { UiTheme } from '@dloizides/ui-feedback';
4
4
  import { DropdownVariant } from '@dloizides/ui-layout';
5
5
  import { resolveAccessibleRoutes, RoleRouteTable, RoleRoute } from '@dloizides/auth-web';
@@ -363,6 +363,14 @@ interface TopbarProps {
363
363
  }
364
364
  declare const Topbar: ({ left, center, language, notificationSlot, user, account, logout, containerStyle, }: TopbarProps) => React.ReactElement;
365
365
 
366
+ declare enum NavHoverFeedback {
367
+ Default = "default",
368
+ TintPill = "tint-pill",
369
+ Underline = "underline",
370
+ Lift = "lift",
371
+ SlidingHighlight = "sliding-highlight"
372
+ }
373
+
366
374
  /**
367
375
  * NavBar — the config-driven HORIZONTAL top navigation bar. It is the top-bar
368
376
  * counterpart to `Sidebar`: it renders the SAME caller-supplied `NavItem[]`
@@ -445,6 +453,7 @@ interface NavBarProps {
445
453
  * theme. Style-only: every colour still flows through the theme — no per-app fork.
446
454
  */
447
455
  barTheme?: UiTheme;
456
+ hoverFeedback?: NavHoverFeedback;
448
457
  }
449
458
  /**
450
459
  * `NavBar` — the horizontal top bar. When `barTheme` is supplied it re-provisions
@@ -1076,6 +1085,21 @@ interface NavOverflowMenuProps {
1076
1085
  }
1077
1086
  declare const NavOverflowMenu: ({ items, pathname, onNavigate, colors, label, hint, testID, variant, }: NavOverflowMenuProps) => React.ReactElement;
1078
1087
 
1088
+ interface AppShellBackdropBand {
1089
+ color: string;
1090
+ text: string;
1091
+ overlap: {
1092
+ compact: number;
1093
+ wide: number;
1094
+ };
1095
+ }
1096
+ interface AppShellBackdrop {
1097
+ color: string;
1098
+ image: string | null;
1099
+ imageSize: string | null;
1100
+ band: AppShellBackdropBand | null;
1101
+ }
1102
+
1079
1103
  /**
1080
1104
  * Default testIDs for `@dloizides/ui-nav`. Kept as a small central map (mirrors
1081
1105
  * `@dloizides/ui-layout`'s `LAYOUT_TEST_IDS`) so the app-agnostic chrome exposes
@@ -1123,6 +1147,7 @@ declare const APP_SHELL_SUFFIX: {
1123
1147
  readonly loading: "-loading";
1124
1148
  readonly error: "-error";
1125
1149
  readonly forbidden: "-forbidden";
1150
+ readonly band: "-backdrop-band";
1126
1151
  };
1127
1152
 
1128
1153
  /**
@@ -1598,4 +1623,25 @@ declare const NAV_ICON_SIZE = 14;
1598
1623
  /** Chevron icon size for expandable sections. */
1599
1624
  declare const CHEVRON_ICON_SIZE = 12;
1600
1625
 
1601
- export { ACTIVE_BORDER_RADIUS, ACTIVE_TINT_OPACITY, APP_SHELL_SUFFIX, type AccountPlan, type AccountState, AppShell, type AppShellProps, type AppShellWidth, BASE_INDENT, CHEVRON_ICON_SIZE, CollapsedRail, type CollapsedRailProps, type CollapsedRailRange, type CommandItem, CommandPalette, type CommandPaletteLabels, type CommandPaletteProps, CommandPaletteTrigger, type CommandPaletteTriggerProps, DEFAULT_COLLAPSED_RAIL_MAX, DEFAULT_SEARCH_BREAKPOINT, DarkModeControl, type DarkModeControlProps, type DarkModeOption, type DarkModeVariant, HOVER_TINT_OPACITY, NAV_ICON_SIZE, NAV_LINK_GAP, NAV_ROW_RADIUS, NAV_TEST_IDS, Nav, NavBar, type NavBarProps, NavExpandableItem, type NavExpandableItemProps, type NavItem, type NavOrientation, NavOverflowMenu, type NavOverflowMenuProps, type NavProps, NavShell, type NavShellCollapsedRail, type NavShellLayout, type NavShellProps, type NavShellSideRail, type NavShellTopBar, type NavUser, PillNav, type PillNavProps, PillNavVariant, RAIL_FULL_BREAKPOINT, type RailMode, type ResolveRailModeArgs, type SearchAffordance, type ShellMessage, Sidebar, SidebarChevron, type SidebarChevronProps, type SidebarPaletteTriggerConfig, type SidebarProps, SidebarSearch, type SidebarSearchConfig, type SidebarSearchLabels, type SidebarSearchProps, Topbar, type TopbarAction, type TopbarProps, type TopbarUser, accessibleNavItems, collapsedRailStyles, darkModeStyles, expandableStyles, filterCommands, filterNavItems, isFilterActive, isRouteActive, navStyles, pillNavStyles, resolveActiveRoute, resolveContentMaxWidth, resolvePillMenuLabel, resolveRailMode, resolveSearchAffordance, roleRoutesToNavItems, searchTokens, useCommandPaletteHotkey, useContentMaxWidth };
1626
+ declare enum TabFeedback {
1627
+ Default = "default",
1628
+ IndicatorPill = "indicator-pill",
1629
+ DimSpring = "dim-spring",
1630
+ SlidingBar = "sliding-bar",
1631
+ IconLift = "icon-lift"
1632
+ }
1633
+
1634
+ interface BottomTabBarProps {
1635
+ items: NavItem[];
1636
+ pathname: string;
1637
+ onNavigate: (route: string) => void;
1638
+ tabFeedback?: TabFeedback;
1639
+ navigateHint?: (label: string) => string;
1640
+ regionLabel?: string;
1641
+ containerStyle?: StyleProp<ViewStyle>;
1642
+ testID?: string;
1643
+ }
1644
+ /** Phone tab bar; `tabFeedback` picks the press feedback, `Default` adds no motion. */
1645
+ declare const BottomTabBar: ({ items, pathname, onNavigate, tabFeedback, navigateHint, regionLabel, containerStyle, testID, }: BottomTabBarProps) => React.ReactElement;
1646
+
1647
+ export { ACTIVE_BORDER_RADIUS, ACTIVE_TINT_OPACITY, APP_SHELL_SUFFIX, type AccountPlan, type AccountState, AppShell, type AppShellBackdrop, type AppShellBackdropBand, type AppShellProps, type AppShellWidth, BASE_INDENT, BottomTabBar, type BottomTabBarProps, CHEVRON_ICON_SIZE, CollapsedRail, type CollapsedRailProps, type CollapsedRailRange, type CommandItem, CommandPalette, type CommandPaletteLabels, type CommandPaletteProps, CommandPaletteTrigger, type CommandPaletteTriggerProps, DEFAULT_COLLAPSED_RAIL_MAX, DEFAULT_SEARCH_BREAKPOINT, DarkModeControl, type DarkModeControlProps, type DarkModeOption, type DarkModeVariant, HOVER_TINT_OPACITY, NAV_ICON_SIZE, NAV_LINK_GAP, NAV_ROW_RADIUS, NAV_TEST_IDS, Nav, NavBar, type NavBarProps, NavExpandableItem, type NavExpandableItemProps, NavHoverFeedback, type NavItem, type NavOrientation, NavOverflowMenu, type NavOverflowMenuProps, type NavProps, NavShell, type NavShellCollapsedRail, type NavShellLayout, type NavShellProps, type NavShellSideRail, type NavShellTopBar, type NavUser, PillNav, type PillNavProps, PillNavVariant, RAIL_FULL_BREAKPOINT, type RailMode, type ResolveRailModeArgs, type SearchAffordance, type ShellMessage, Sidebar, SidebarChevron, type SidebarChevronProps, type SidebarPaletteTriggerConfig, type SidebarProps, SidebarSearch, type SidebarSearchConfig, type SidebarSearchLabels, type SidebarSearchProps, TabFeedback, Topbar, type TopbarAction, type TopbarProps, type TopbarUser, accessibleNavItems, collapsedRailStyles, darkModeStyles, expandableStyles, filterCommands, filterNavItems, isFilterActive, isRouteActive, navStyles, pillNavStyles, resolveActiveRoute, resolveContentMaxWidth, resolvePillMenuLabel, resolveRailMode, resolveSearchAffordance, roleRoutesToNavItems, searchTokens, useCommandPaletteHotkey, useContentMaxWidth };