@bytebrand/fe-ui-core-autobahn 1.0.208 → 1.0.210
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/cards/CarCard.tsx +1 -8
- package/cards/CarRow.tsx +1 -5
- package/cards/cardParts.tsx +1363 -1368
- package/cards/index.ts +0 -6
- package/cards/types.ts +182 -182
- package/chrome/Footer.tsx +3 -16
- package/chrome/TopBar.tsx +266 -139
- package/compat/CookieModal/CookieModal.tsx +6 -20
- package/compat/CookieModal/Modal.tsx +3 -6
- package/compat/CookieModal/modals/ManageCookieModal/ManageCookieModal.tsx +15 -43
- package/compat/CookieModal/modals/PreviewCookieModal/PreviewCookieModal.tsx +3 -4
- package/compat/CookieModal/useModal.ts +1 -5
- package/compat/Loader/Loader.tsx +7 -1
- package/compat/MdField/MdField.tsx +4 -28
- package/compat/TimePicker/TimePicker.tsx +2 -12
- package/data/toAutobahnCar.ts +586 -600
- package/iconsvg/IconSVG.tsx +5 -1
- package/locales/de/autobahn.json +857 -891
- package/locales/en/autobahn.json +857 -891
- package/package.json +2 -2
- package/theme/md3.css +11743 -15678
- package/ui/CreditCostNotice.tsx +44 -44
- package/ui/CreditKeyFigures.tsx +244 -244
- package/ui/Dropdown.tsx +10 -29
- package/ui/FormCheckbox.tsx +2 -22
- package/ui/FormField.tsx +1 -2
- package/ui/Icon.tsx +0 -6
- package/ui/Modal.tsx +6 -84
- package/ui/Skeleton.tsx +20 -79
- package/ui/index.ts +94 -96
- package/ui/usePortalMenuPosition.ts +15 -27
- package/utils/index.ts +0 -10
- package/vdp/FinanceCalculator.tsx +1134 -1148
- package/vdp/VdpModules.tsx +4437 -3869
- package/vdp/index.ts +3 -0
- package/vdp/types.ts +17 -7
- package/vehiclesProps/decoratedLightProps.tsx +0 -4
- package/vehiclesProps/decoratedProps.tsx +0 -4
- package/cards/CarCardSkeleton.tsx +0 -103
- package/cards/CarRowSkeleton.tsx +0 -152
- package/chrome/AccountMenuIcon.tsx +0 -109
- package/ui/MfieldCheckIcon.tsx +0 -13
- package/ui/scrollFieldIntoView.ts +0 -41
- package/utils/cookieConsent.ts +0 -84
- package/vehiclesProps/accidentDisclosure.ts +0 -25
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
// FINN handover v0.6 (Daniel, 15.10.2026): for the owners set here, accident and owner facts follow
|
|
2
|
-
// only what the source states — mainData.accidentDamaged false → accident-free, true → accident,
|
|
3
|
-
// empty → not specified; an empty owner count is not shown as "0. Hand". Every other dealer keeps
|
|
4
|
-
// the old display (accident-free unless `damaged`). The app sets the owners once at start.
|
|
5
|
-
let strictOwners: ReadonlyArray<string> = [];
|
|
6
|
-
|
|
7
|
-
export function setStrictConditionOwners(ownerIds: ReadonlyArray<string>): void {
|
|
8
|
-
strictOwners = (ownerIds || []).filter(Boolean);
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
export function isStrictConditionOwner(car: any): boolean {
|
|
12
|
-
const ownerId = car?.metaData?.ownerId;
|
|
13
|
-
return !!ownerId && strictOwners.includes(ownerId);
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export type AccidentStatus = 'accidentFree' | 'accident' | 'notSpecified';
|
|
17
|
-
|
|
18
|
-
// The strict status, or undefined when the car's owner keeps the old display.
|
|
19
|
-
export function strictAccidentStatus(car: any): AccidentStatus | undefined {
|
|
20
|
-
if (!isStrictConditionOwner(car)) return undefined;
|
|
21
|
-
const value = car?.mainData?.accidentDamaged;
|
|
22
|
-
if (value === true) return 'accident';
|
|
23
|
-
if (value === false) return 'accidentFree';
|
|
24
|
-
return 'notSpecified';
|
|
25
|
-
}
|