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

Friendlier post-setup page #3318

Merged
merged 4 commits into from
May 9, 2022
Merged

Friendlier post-setup page #3318

merged 4 commits into from
May 9, 2022

Conversation

johnnyaug
Copy link
Contributor

@johnnyaug johnnyaug commented May 5, 2022

Before:
image

After
image

@johnnyaug johnnyaug added the include-changelog PR description should be included in next release changelog label May 5, 2022
Copy link
Contributor

@itaidavid itaidavid left a comment

Choose a reason for hiding this comment

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

Thanks for this upgrade. New page looks much better :-)
Approving as not to block, but if you need someone to review js code, I would wait for another approval

Copy link
Contributor

@itaiad200 itaiad200 left a comment

Choose a reason for hiding this comment

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

Thanks for this improvement. Mainly questions and minor comments.

<Alert variant="warning">
<div className={"ml-2 row mt-4"}>
<div className={"col-3"}>Access Key ID:</div>
<div className={"col-7"}><code>{setupData.access_key_id}</code> &#160;&#160;<ClipboardButton className={"copy-button"} variant="outline-dark" text={setupData.access_key_id} tooltip="Copy"/></div>
Copy link
Contributor

Choose a reason for hiding this comment

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

Why not push the variant="outline-dark" to the css if it's shared between the 2 usages?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The variant is a react attribute, you can't apply it using CSS

{' '}
<Button variant="link" onClick={() => router.push({pathname: "/auth/login", query: {next}})}>Go To Login</Button>
<div className={"mt-4"} style={{textAlign: "center"}}>
<Button className={"p-2 pl-3 pr-3 after-setup-btn"} onClick={() => window.open("/auth/login", "_blank")}>Go To Login</Button>
Copy link
Contributor

Choose a reason for hiding this comment

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

This changes the current behaviour by creating a new tab, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, good catch! I was thinking it's better that to have the credentials still available in the previous tab.

);
}
return (
<Row>
<Col md={{offset: 2, span: 8}}>
<Card className="setup-widget">
<Card className="setup-widget">
Copy link
Contributor

Choose a reason for hiding this comment

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

Undo

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Also not related here - but it's an indentation fix.

Comment on lines -317 to +323
.table .tree-entry-row .change-entry-row-actions .btn-link,
.actions-runs-list .table tbody tr td .clipboard-copy button,
.actions-runs-list .table tbody tr td .run-filter .link {
.table .tree-entry-row .change-entry-row-actions .btn-link {
visibility: hidden;
font-size: 0.7rem;
}
.table .change-entry-row:hover .change-entry-row-actions .btn-link,
.table .tree-entry-row:hover .change-entry-row-actions .btn-link,
.table .tree-entry-row:focus .change-entry-row-actions .btn-link,
.actions-runs-list .table tbody tr:hover td .clipboard-copy button ,
.actions-runs-list .table tbody tr:focus td .clipboard-copy button ,
.actions-runs-list .table tbody tr:hover td .run-filter .link ,
.actions-runs-list .table tbody tr:focus td .run-filter .link {
.table .tree-entry-row:focus .change-entry-row-actions .btn-link {
Copy link
Contributor

Choose a reason for hiding this comment

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

Are these changes related?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not really, just a cleanup.

@@ -218,7 +218,7 @@ export const TooltipButton = ({ onClick, variant, children, tooltip, className="
);
};

export const ClipboardButton = ({ text, variant, onSuccess, icon = <ClippyIcon/>, onError, tooltip = "Copy to clipboard"}) => {
export const ClipboardButton = ({ text, variant, onSuccess, icon = <ClippyIcon/>, onError, tooltip = "Copy to clipboard", ...rest}) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't understand where you're passing the ...rest.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I use it to on the internal button itself. The goal is for the attributes from to be passed to the internal button. For example, when using className - pass it to the underlying button.

<Card className="mt-5">
<Card.Body className={"after-setup-card"}>
<h5>Configure lakectl</h5>
<div>Use the command-line tool to perform Git-like operations on your data. Save the configuration file under <code>~/.lakectl.yaml</code>:</div>
Copy link
Contributor

Choose a reason for hiding this comment

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

Minor: path is valid for POSIX only.

@johnnyaug johnnyaug merged commit 52348fd into master May 9, 2022
@johnnyaug johnnyaug deleted the feature/friendly_post_setup branch May 9, 2022 15:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
include-changelog PR description should be included in next release changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants