-
Notifications
You must be signed in to change notification settings - Fork 14.4k
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
fix: Create dataset polish/bug fix #22262
Conversation
Codecov Report
@@ Coverage Diff @@
## master #22262 +/- ##
==========================================
+ Coverage 66.86% 66.90% +0.04%
==========================================
Files 1846 1847 +1
Lines 70510 71241 +731
Branches 7723 8039 +316
==========================================
+ Hits 47144 47665 +521
- Misses 21364 21534 +170
- Partials 2002 2042 +40
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
/testenv up |
@lyndsiWilliams Ephemeral environment spinning up at http://52.24.161.135:8080. Credentials are |
@@ -248,6 +258,9 @@ const DatasetPanel = ({ | |||
const theme = useTheme(); | |||
const hasColumns = columnList?.length > 0 ?? false; | |||
const datasetNames = datasets?.map(dataset => dataset.table_name); | |||
const tablesWithDatasets = datasets?.find( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we rename this to singular? tablesWithDatasets
-> tableWithDatasets
since find
only returns one element?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh yeah that does make more sense, adjusted in this commit
.
/> | ||
) : ( | ||
<StyledCreateDatasetTitle> | ||
{title ?? DEFAULT_TITLE} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we want to render empty string if passed as title
? If not, we should change this to be ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good call! Fixed in this commit
.
fc87b75
to
8d11c74
Compare
columns={tableColumnDefinition} | ||
data={columnList} | ||
pageSizeOptions={pageSizeOptions} | ||
defaultPageSize={25} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we make this a constant at the top?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can do! Done in this commit
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, just update the page min to be a constant at the top
const MANAGE_YOUR_DATABASES_TEXT = t('Manage your databases'); | ||
const HERE_TEXT = t('here'); | ||
|
||
export const emptyStateComponent = (emptyResultsWithSearch: boolean) => ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If this is going to be exported, I think that we should move it out of the SQlEditorLeftBar? Where are the other empty state components stored? THat's where it should be.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good thinking! Done in this commit
.
…mponents/EmptyState
Ephemeral environment shutdown and build artifacts deleted. |
SUMMARY
This PR implements the following polishes:
...
dropdown menu from the top right of the headerediting
prop was added in the header component so that it can be reused when building the edit dataset componentBEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
BEFORE:
AFTER:
TESTING INSTRUCTIONS
http://localhost:9000/dataset/add/?testing
ADDITIONAL INFORMATION