Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Move and style copyButton, add to active and past detour views #2852

Open
wants to merge 14 commits into
base: main
Choose a base branch
from

Conversation

hannahpurcell
Copy link
Collaborator

@hannahpurcell hannahpurcell commented Oct 11, 2024

Add yourself to the copy-button user group to see this on the active / past detour views, because I haven't yet done the copy logic.

The button will be visible on the View Draft Detour panel without being added to the user group.

Now depends on:

^ only because the copy change will prevent the button from being too cramped on the "View Draft Detour" page

@hannahpurcell hannahpurcell requested a review from a team as a code owner October 11, 2024 20:12
@hannahpurcell hannahpurcell self-assigned this Oct 16, 2024
@@ -89,7 +93,7 @@
}
}

.l-diversion-page-panel__header .c-diversion-panel__back-button {
.l-diversion-page-panel__header .c-diversion-panel__outline-button--back {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: why change the name of this button? IMO the "outline" info doesn't seem necessary?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're totally right. I renamed at one point, assuming I'd use the --back as an extension of outline button, as in these lines, but not needed. (Plus, I see those might need tweaking as well)

Comment on lines +169 to +178
.c-diversion-panel__outline-button {
height: 2rem;
border-radius: 0.2rem;
font-size: 0.875rem;
padding: 0.375rem 0.5rem;

&--copy {
margin: 0.78125rem 0;
}
}
Copy link
Member

@firestack firestack Oct 18, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we need this? this seems like a size="sm" property on the React Bootstrap <Button/>

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh my gosh, I totally reinvented the wheel. Thanks!!

Comment on lines +175 to +177
&--copy {
margin: 0.78125rem 0;
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this margin should be handled via the .align-items-baseline class on the parent flex

}
>
<Button
className="c-diversion-panel__outline-button c-diversion-panel__outline-button--copy icon-link"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Between these two suggestions

I don't think most of the classes are needed?

Suggested change
className="c-diversion-panel__outline-button c-diversion-panel__outline-button--copy icon-link"
className="icon-link"

@firestack firestack assigned hannahpurcell and unassigned firestack Oct 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants