mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-12-01 08:53:13 +00:00
Merge dev into feat/tours and port Tours onto MikroORM
dev now runs on MikroORM, so the positional migrations, seeds.ts and DatabaseService the Tours server side was built on are gone. Behaviour is unchanged; persistence moves onto dev's architecture: - one MikroORM migration for tour_types, tours and tour_waypoints, idempotent so instances that ran the old positional steps keep their data; the hike tour type is seeded inside it, the addon row in the AddonSeeder - entities and repositories for the three tables, tours domain on repositories and UnitOfWork - tour facet joins in places, assignments and days re-applied on the repository code Fixes found while porting: - GPX import checks addon, trip access and permission in the handler instead of guards, so a refused upload gets a 403/404 instead of a connection reset - copying a trip copies its tours and waypoints - a tour cannot be moved onto a day that already has it - updateTour checks existence inside its transaction Adds tours e2e tests and rewrites the tours unit tests onto the migrated test database.
This commit is contained in:
@@ -14,9 +14,12 @@ import { renderIconMarkup } from './iconMarkup'
|
||||
|
||||
type IconComponent = Parameters<typeof createElement>[0]
|
||||
|
||||
// `Icon` is lucide's generic base component, not an icon: it renders whatever
|
||||
// `iconNode` it is handed and throws without one.
|
||||
const ICONS = Object.entries(lucide).filter(
|
||||
([name, value]) =>
|
||||
/^[A-Z]/.test(name) &&
|
||||
name !== 'Icon' &&
|
||||
typeof value === 'object' &&
|
||||
value !== null &&
|
||||
(value as { $$typeof?: symbol }).$$typeof === Symbol.for('react.forward_ref')
|
||||
|
||||
Reference in New Issue
Block a user