[offers][fix] fix merge conflicts

pull/501/head
Stuart Long Chay Boon 3 years ago
parent c865897673
commit 08ef869ea3

@ -33,7 +33,6 @@ export default function DashboardProfileCard({
<div className="px-4 py-4 sm:px-6">
<div className="flex items-end justify-between">
<div className="col-span-1 row-span-3">
<<<<<<< HEAD
<h4 className="font-medium">
{getLabelForJobTitleType(title as JobTitleType)}{' '}
{jobType && <>({JobTypeLabel[jobType]})</>}
@ -67,17 +66,6 @@ export default function DashboardProfileCard({
</div>
)}
</div>
=======
<p className="font-bold">
{getLabelForJobTitleType(title as JobTitleType)}
</p>
<p>
{location
? `Company: ${company.name}, ${location.cityName}`
: `Company: ${company.name}`}
</p>
{level && <p>Level: {level}</p>}
>>>>>>> ac2d047d ([offers][feat] integrate location for offer table and profile)
</div>
<div className="col-span-1 row-span-3">
<p className="text-end text-lg font-medium leading-6 text-slate-900">
@ -92,4 +80,4 @@ export default function DashboardProfileCard({
</div>
</div>
);
}
}

@ -289,7 +289,6 @@ export default function OffersSubmissionForm({
steps={breadcrumbSteps}
/>
</div>
<<<<<<< HEAD
<div className="bg-white p-6 sm:p-10">
<FormProvider {...formMethods}>
<form
@ -350,58 +349,8 @@ export default function OffersSubmissionForm({
</form>
</FormProvider>
</div>
=======
<FormProvider {...formMethods}>
<form className="text-sm" onSubmit={handleSubmit(onSubmit)}>
{steps[step]}
<pre>{JSON.stringify(formMethods.watch(), null, 2)}</pre>
{step === 0 && (
<div className="flex justify-end">
<Button
disabled={false}
icon={ArrowRightIcon}
label="Next"
variant="secondary"
onClick={() => {
goToNextStep(step);
gaEvent({
action: 'offers.profile_submission_navigate_next',
category: 'submission',
label: 'Navigate next',
});
}}
/>
</div>
)}
{step === 1 && (
<div className="flex items-center justify-between">
<Button
icon={ArrowLeftIcon}
label="Previous"
variant="secondary"
onClick={() => {
setStep(step - 1);
gaEvent({
action: 'offers.profile_submission_navigation_back',
category: 'submission',
label: 'Navigate back',
});
}}
/>
<Button
disabled={isSubmitting || isSubmitSuccessful}
isLoading={isSubmitting || isSubmitSuccessful}
label="Submit"
type="submit"
variant="primary"
/>
</div>
)}
</form>
</FormProvider>
>>>>>>> a31230f7 ([offers][feat] Use city typeahead for location field)
</div>
</div>
</div>
);
}
}

@ -35,7 +35,6 @@ export default function OfferCard({
}: Props) {
function UpperSection() {
return (
<<<<<<< HEAD
<div className="px-4 py-5 sm:px-6">
<div className="flex justify-between">
<div>
@ -71,17 +70,6 @@ export default function OfferCard({
</div>
)}
</div>
=======
<div className="flex justify-between px-8">
<div className="flex flex-col">
<div className="flex flex-row">
<span>
<BuildingOffice2Icon className="mr-3 h-5" />
</span>
<span className="font-bold">
{location ? `${companyName}, ${location.cityName}` : companyName}
</span>
>>>>>>> ac2d047d ([offers][feat] integrate location for offer table and profile)
</div>
<div className="space-y-2">
{!duration && receivedMonth && (
@ -111,7 +99,6 @@ export default function OfferCard({
}
return (
<<<<<<< HEAD
<div className="border-t border-slate-200 px-4 py-5 sm:px-6">
<dl className="grid grid-cols-2 gap-x-4 gap-y-8 sm:grid-cols-4">
{jobType === JobType.FULLTIME
@ -155,34 +142,6 @@ export default function OfferCard({
<dd className="mt-1 text-sm text-slate-900">{bonus}</dd>
</div>
)}
=======
<>
<HorizontalDivider />
<div className="px-8">
<div className="flex flex-col py-2">
{(totalCompensation || monthlySalary) && (
<div className="flex flex-row">
<span>
<CurrencyDollarIcon className="mr-3 h-5" />
</span>
<span>
<p>
{totalCompensation && `TC: ${totalCompensation}`}
{monthlySalary && `Monthly Salary: ${monthlySalary}`}
</p>
</span>
</div>
)}
{(base || stocks || bonus) && totalCompensation && (
<div className="ml-8 flex flex-row font-light">
<p>
Base / year: {base ?? 'N/A'} Stocks / year:{' '}
{stocks ?? 'N/A'} Bonus / year: {bonus ?? 'N/A'}
</p>
</div>
)}
</div>
>>>>>>> ac2d047d ([offers][feat] integrate location for offer table and profile)
{negotiationStrategy && (
<div className="col-span-2">
<dt className="text-sm font-medium text-slate-500">
@ -210,4 +169,4 @@ export default function OfferCard({
<BottomSection />
</div>
);
}
}

@ -56,4 +56,4 @@ export type OfferTableSortByType =
| '-monthYearReceived'
| '-totalCompensation'
| '-totalYoe'
| '+totalYoe';
| '+totalYoe';

@ -1,17 +0,0 @@
import React from 'react';
import { trpc } from '~/utils/trpc';
function GenerateAnalysis() {
const analysisMutation = trpc.useMutation(['offers.analysis.generate']);
return (
<div>
{JSON.stringify(
analysisMutation.mutate({ profileId: 'cl9lwe9m902k5utskjs52wc0j' }),
)}
</div>
);
}
export default GenerateAnalysis;

@ -1,14 +0,0 @@
import React from 'react';
import { trpc } from '~/utils/trpc';
function GetAnalysis() {
const analysis = trpc.useQuery([
'offers.analysis.get',
{ profileId: 'cl9lwe9m902k5utskjs52wc0j' },
]);
return <div>{JSON.stringify(analysis.data)}</div>;
}
export default GetAnalysis;

@ -1,53 +0,0 @@
import React from 'react';
import { trpc } from '~/utils/trpc';
function Test() {
const data = trpc.useQuery([
'offers.list',
{
currency: 'SGD',
limit: 100,
location: 'Singapore, Singapore',
offset: 0,
sortBy: '-totalCompensation',
yoeCategory: 1,
},
]);
const deleteMutation = trpc.useMutation(['offers.profile.delete']);
const handleDelete = (id: string) => {
deleteMutation.mutate({ profileId: id, token: ' dadaadad' });
};
return (
<ul>
<li>
<b>{JSON.stringify(data.data?.paging)}</b>
</li>
<li>
<ul>
{data.data?.data.map((offer) => {
return (
<li key={offer.id}>
<button
className="text-danger-600"
type="button"
onClick={() => {
handleDelete(offer.profileId);
}}>
DELETE THIS PROFILE AND ALL ITS OFFERS
</button>
<div>{JSON.stringify(offer)}</div>
<br />
</li>
);
})}
</ul>
</li>
</ul>
);
}
export default Test;
Loading…
Cancel
Save