fix signup box, merge crime & rename crime

This commit is contained in:
Ruby 2026-03-15 19:46:36 +00:00
parent f72c43a9fa
commit 325848c5a9
5 changed files with 17 additions and 22 deletions

View file

@ -81,12 +81,14 @@ export default function AuthModal({
view === 'login' ? 'Log in' : view === 'register' ? 'Create account' : 'Reset password'; view === 'login' ? 'Log in' : view === 'register' ? 'Create account' : 'Reset password';
return ( return (
<div className="fixed inset-0 z-50 flex items-center justify-center" onClick={onClose}> <div
<div className="absolute inset-0 bg-black/50 dark:bg-black/70" /> className="fixed inset-0 z-50 flex items-center justify-center"
<div onMouseDown={(e) => {
className="relative w-full max-w-sm mx-4 bg-white dark:bg-warm-900 rounded-lg shadow-xl border border-warm-200 dark:border-warm-700" if (e.target === e.currentTarget) onClose();
onClick={(e) => e.stopPropagation()} }}
> >
<div className="absolute inset-0 bg-black/50 dark:bg-black/70" onMouseDown={onClose} />
<div className="relative w-full max-w-sm mx-4 bg-white dark:bg-warm-900 rounded-lg shadow-xl border border-warm-200 dark:border-warm-700">
{/* Header */} {/* Header */}
<div className="flex items-center justify-between px-5 pt-5 pb-3"> <div className="flex items-center justify-between px-5 pt-5 pb-3">
<h2 className="text-lg font-semibold text-navy-950 dark:text-white">{title}</h2> <h2 className="text-lg font-semibold text-navy-950 dark:text-white">{title}</h2>
@ -119,7 +121,7 @@ export default function AuthModal({
}`} }`}
onClick={() => switchView('register')} onClick={() => switchView('register')}
> >
Register Create account
</button> </button>
</div> </div>
)} )}

View file

@ -258,7 +258,7 @@ export default function Header({
onClick={onRegisterClick} onClick={onRegisterClick}
className="px-3 py-1.5 rounded bg-teal-600 hover:bg-teal-700 transition-colors text-sm font-medium" className="px-3 py-1.5 rounded bg-teal-600 hover:bg-teal-700 transition-colors text-sm font-medium"
> >
Register Create account
</button> </button>
</> </>
)} )}
@ -271,7 +271,7 @@ export default function Header({
onClick={onRegisterClick} onClick={onRegisterClick}
className="px-4 py-1.5 rounded bg-teal-600 hover:bg-teal-700 transition-colors text-sm font-semibold" className="px-4 py-1.5 rounded bg-teal-600 hover:bg-teal-700 transition-colors text-sm font-semibold"
> >
Sign up Create account
</button> </button>
)} )}

View file

@ -183,7 +183,7 @@ export default function MobileMenu({
}} }}
className="flex-1 px-3 py-2.5 rounded bg-teal-600 hover:bg-teal-700 transition-colors text-sm font-medium text-center" className="flex-1 px-3 py-2.5 rounded bg-teal-600 hover:bg-teal-700 transition-colors text-sm font-medium text-center"
> >
Register Create account
</button> </button>
</div> </div>
)} )}

View file

@ -12,11 +12,10 @@ import {
} from '../components/ui/icons'; } from '../components/ui/icons';
const GROUP_ICONS: Record<string, ComponentType<{ className?: string }>> = { const GROUP_ICONS: Record<string, ComponentType<{ className?: string }>> = {
'Properties in the area': HouseIcon, Properties: HouseIcon,
Transport: RouteIcon, Transport: RouteIcon,
Education: GraduationCapIcon, Education: GraduationCapIcon,
Deprivation: ChartBarIcon, Deprivation: ChartBarIcon,
'Crime summary': ShieldIcon,
Crime: ShieldIcon, Crime: ShieldIcon,
Demographics: UsersIcon, Demographics: UsersIcon,
Amenities: ShoppingBagIcon, Amenities: ShoppingBagIcon,

View file

@ -64,7 +64,7 @@ pub struct EnumFeatureGroup {
pub static FEATURE_GROUPS: &[FeatureGroup] = &[ pub static FEATURE_GROUPS: &[FeatureGroup] = &[
FeatureGroup { FeatureGroup {
name: "Properties in the area", name: "Properties",
features: &[ features: &[
FeatureConfig { FeatureConfig {
name: "Last known price", name: "Last known price",
@ -131,7 +131,7 @@ pub static FEATURE_GROUPS: &[FeatureGroup] = &[
suffix: "", suffix: "",
raw: false, raw: false,
absolute: false, absolute: false,
modes: &[], modes: &["historical"],
linked: "", linked: "",
}, },
FeatureConfig { FeatureConfig {
@ -516,9 +516,8 @@ pub static FEATURE_GROUPS: &[FeatureGroup] = &[
}, },
], ],
}, },
FeatureGroup { FeatureGroup {
name: "Crime summary", name: "Crime",
features: &[ features: &[
FeatureConfig { FeatureConfig {
name: "Serious crime (avg/yr)", name: "Serious crime (avg/yr)",
@ -588,11 +587,6 @@ pub static FEATURE_GROUPS: &[FeatureGroup] = &[
modes: &[], modes: &[],
linked: "", linked: "",
}, },
],
},
FeatureGroup {
name: "Crime",
features: &[
FeatureConfig { FeatureConfig {
name: "Anti-social behaviour (avg/yr)", name: "Anti-social behaviour (avg/yr)",
bounds: Bounds::Percentile { bounds: Bounds::Percentile {
@ -1022,7 +1016,7 @@ pub static FEATURE_GROUPS: &[FeatureGroup] = &[
pub static ENUM_FEATURE_GROUPS: &[EnumFeatureGroup] = &[ pub static ENUM_FEATURE_GROUPS: &[EnumFeatureGroup] = &[
EnumFeatureGroup { EnumFeatureGroup {
name: "Properties in the area", name: "Properties",
features: &[ features: &[
EnumFeatureConfig { EnumFeatureConfig {
name: "Listing status", name: "Listing status",