Skip to content

chore(OUK): Upgrade version, fix migration issues#690

Draft
misi-bp wants to merge 8 commits into
mainfrom
684/upgrade-ouk-mui
Draft

chore(OUK): Upgrade version, fix migration issues#690
misi-bp wants to merge 8 commits into
mainfrom
684/upgrade-ouk-mui

Conversation

@misi-bp

@misi-bp misi-bp commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Description

Upgrades the lungo frontend from Open UI Kit (OUK) 1.6 to 2.1 and updates call sites for OUK 2’s breaking API changes, while keeping MUI at ^7.0.1 so the app stays on the same Material UI major/minor line that OUK 2 declares and bundles against. We intentionally did not upgrade MUI to v8/v9: OUK 2.1.0 depends on @mui/material ^7.0.1, and aligning on that version avoids duplicate MUI installs, conflicting Theme types, and compat shims (overrides, icon aliases, palette augmentations) that a higher MUI version would require.

Dependency changes

  • @open-ui-kit/core: ^1.6.0^2.1.0
  • @mui/material / @mui/icons-material: remain ^7.0.1 (resolved to 7.3.x; deduped with OUK)
  • @testing-library/dom: ^10.4.1 added to devDependencies. Explicitly listing @testing-library/dom documents and guarantees the peer dependency that @testing-library/react v16 needs at test time, so fresh npm install runs stay reliable instead of depending on implicit hoisting or peer-resolution quirks.

OUK 2 migration

  • Theme mode: OUK 2 replaces isDarkMode / defaultDarkMode with ThemeMode + mode / setMode. Added useAppThemeMode as a thin wrapper for boolean helpers (isDarkMode, setIsDarkMode, toggleTheme) used across navigation, chat, and persistence.
  • Modals: Modal / ModalContent / ModalTitleDialog / DialogContent / DialogTitle in badge, policy, OASF, and info modals.
  • Dropdown options: OUK no longer exports DropdownOption; added src/types/dropdownOption.ts for suggested-prompts menu typing.
  • ListItemButton: Removed invalid type="button" props where OUK 2’s typings no longer accept them.

Naming and structure

  • Renamed project-specific theme files/symbols to neutral names (CompactTheme, compactThemeOptions, useAppThemeMode, app-shell panel id, theme-mode storage key with legacy read fallback).
  • Split railBackgroundImage into transportRailBackground.ts so TransportRail.tsx only exports a component (fixes react-refresh/only-export-components / Fast Refresh lint).

Verification

  • npm run check (lint, format, typecheck, 133 tests) passes
  • npm run build passes

Issue Link

#684

Type of Change

  • Bugfix
  • New Feature
  • Breaking Change
  • Refactor
  • Documentation
  • Other (please describe)

Checklist

  • I have read the contributing guidelines
  • Existing issues have been referenced (where applicable)
  • I have verified this change is not present in other open pull requests
  • Functionality is documented
  • All code style checks pass
  • New code contribution is covered by automated tests
  • All new and existing tests pass

misi-bp added 8 commits July 2, 2026 10:37
Signed-off-by: misi-bp <mkaloczy@cisco.com>
Signed-off-by: misi-bp <mkaloczy@cisco.com>
Signed-off-by: misi-bp <mkaloczy@cisco.com>
Signed-off-by: misi-bp <mkaloczy@cisco.com>
Signed-off-by: misi-bp <mkaloczy@cisco.com>
Signed-off-by: misi-bp <mkaloczy@cisco.com>
…ective

Signed-off-by: misi-bp <mkaloczy@cisco.com>
Signed-off-by: misi-bp <mkaloczy@cisco.com>
@misi-bp misi-bp requested a review from a team as a code owner July 2, 2026 09:19
@misi-bp misi-bp assigned misi-bp and unassigned misi-bp Jul 2, 2026
@misi-bp misi-bp marked this pull request as draft July 2, 2026 09:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant