added domna tech password

This commit is contained in:
Jun-te Kim 2026-04-27 11:59:53 +00:00
parent c3cc123a6f
commit a37fd03202
3 changed files with 12 additions and 21 deletions

View file

@ -35,6 +35,16 @@ export default function AddNew({
router.push(`/portfolio/${portfolioId}/remote-assessment`);
}
function handleBulkUploadClick() {
const pw = window.prompt("Enter password to access bulk upload");
if (pw === null) return;
if (pw === "domnatechteamonly") {
setIsBulkUploadOpen(true);
} else {
window.alert("Incorrect password");
}
}
return (
<>
<BulkUploadComingSoonModal
@ -118,7 +128,7 @@ export default function AddNew({
<MenuItem>
{({ active }) => (
<button
onClick={() => setIsBulkUploadOpen(true)}
onClick={handleBulkUploadClick}
className={cn(
"w-full p-3 rounded-lg text-left flex gap-3 transition-colors",
active && "bg-gray-100"

View file

@ -314,7 +314,7 @@ export default function PropertyTable({
() => {
const init: VisibilityState = {};
OPTIONAL_COLUMN_IDS.forEach((id) => {
init[id] = id === "lexiscore";
init[id] = false;
});
return init;
},

View file

@ -158,7 +158,6 @@ export const OPTIONAL_COLUMN_IDS = [
"totalFloorArea",
"co2Emissions",
"mainfuel",
"lexiscore",
] as const;
export type OptionalColumnId = (typeof OPTIONAL_COLUMN_IDS)[number];
@ -171,7 +170,6 @@ const OPTIONAL_COLUMN_LABELS: Record<OptionalColumnId, string> = {
totalFloorArea: "Floor Area (m²)",
co2Emissions: "CO₂ Emissions",
mainfuel: "Main Fuel",
lexiscore: "Match confidence",
};
export { OPTIONAL_COLUMN_LABELS };
@ -457,23 +455,6 @@ const optionalColumns: ColumnDef<PropertyWithRelations>[] = [
return label ? <Pill>{label}</Pill> : <span className="text-slate-300 text-xs"></span>;
},
},
{
id: "lexiscore",
accessorKey: "lexiscore",
header: () => <div className="text-xs">Match</div>,
cell: ({ row }) => {
const score = row.original.lexiscore;
if (score == null) return <span className="text-slate-300 text-xs"></span>;
const bucket = score >= 0.85 ? "High" : score >= 0.65 ? "Medium" : "Low";
const cls =
bucket === "High"
? "bg-green-50 text-green-700"
: bucket === "Medium"
? "bg-amber-50 text-amber-700"
: "bg-red-50 text-red-700";
return <Pill className={cls}>{bucket}</Pill>;
},
},
];
export const columns: ColumnDef<PropertyWithRelations>[] = [