Fix issue where share solution is shown without submitting

pull/8173/head
Kamran Ahmed 2 weeks ago
parent 5cc4b834d1
commit e0da1e4f0e
  1. 48
      src/components/Projects/StatusStepper/ProjectStepper.tsx

@ -287,28 +287,32 @@ export function ProjectStepper(props: ProjectStepperProps) {
number={2} number={2}
/> />
<span className="text-gray-600 sm:hidden">&middot;</span> {activeStep > 1 && (
<button <>
className={cn( <span className="text-gray-600 sm:hidden">&middot;</span>
'flex items-center gap-2 text-sm sm:hidden', <button
isCopied ? 'text-green-500' : 'text-gray-600', className={cn(
)} 'flex items-center gap-2 text-sm sm:hidden',
onClick={() => { isCopied ? 'text-green-500' : 'text-gray-600',
copyText(projectSolutionUrl); )}
}} onClick={() => {
> copyText(projectSolutionUrl);
{isCopied ? ( }}
<> >
<CheckIcon additionalClasses="h-3 w-3" /> {isCopied ? (
URL Copied <>
</> <CheckIcon additionalClasses="h-3 w-3" />
) : ( URL Copied
<> </>
<Share className="h-3 w-3 stroke-[2.5px]" /> ) : (
Share your Solution <>
</> <Share className="h-3 w-3 stroke-[2.5px]" />
)} Share your Solution
</button> </>
)}
</button>
</>
)}
</div> </div>
<StepperStepSeparator isActive={activeStep > 1} /> <StepperStepSeparator isActive={activeStep > 1} />
<MilestoneStep <MilestoneStep

Loading…
Cancel
Save