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

[App Search] Convert API Logs page to new page template + empty state polish #102820

Merged
merged 6 commits into from
Jun 22, 2021

Conversation

cee-chen
Copy link
Member

Summary

Follow up to #102170 - converts more App Search pages to the new KibanaPageTemplate. I'm attempting to break up the AS layout conversion into smaller, easier to review chunks.

This PR handles the API Logs view, and moves its empty state to a top-level concern to match other existing pages. It also adds a documentation link for funsies. As always, follow along by commit (and turn off whitespace diffs)

Screencaps

Checklist

+ use new empty state
+ add tests clarifying loading UX
@cee-chen cee-chen requested a review from a team June 21, 2021 20:58
@cee-chen cee-chen added auto-backport Deprecated - use backport:version if exact versions are needed release_note:skip Skip the PR/issue when compiling release notes v7.14.0 labels Jun 21, 2021
expect(wrapper.prop('isLoading')).toEqual(true);
});

it('does not re-render a full-page loading state after initial page load (uses component-level loading state instead)', () => {
Copy link
Member Author

Choose a reason for hiding this comment

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

Note that the component level loading here is the EuiBasicTable's default loading prop. The only time data reloads on this page is when users are paginating between pages of logs, so it makes sense to handle that loading UX at the component level instead of re-flashing a full-page loading state.

The test name was already getting really long though so I didn't want to add all that extra context to it 🤪

href={`${DOCS_PREFIX}/api-reference.html`}
>
{i18n.translate('xpack.enterpriseSearch.appSearch.engine.searchUI.empty.buttonLabel', {
defaultMessage: 'View the API reference',
Copy link
Member Author

Choose a reason for hiding this comment

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

This document link is new, I thought it made sense to provide a link teaching people how to make API calls if needed. Feel free to leave copy feedback

@cee-chen
Copy link
Member Author

Not sure why this CI failed but not going to bother to re-run tests right now, they'll have to rerun anyway later to get latest master / fix router merge conflicts

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
enterpriseSearch 1447 1448 +1

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
enterpriseSearch 2.1MB 2.1MB +3.0B

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @byronhulcher

@kibanamachine
Copy link
Contributor

💚 Backport successful

Status Branch Result
7.x

This backport PR will be merged automatically after passing CI.

kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jun 22, 2021
… polish (elastic#102820)

* Convert API Logs noItemsMessage to its own empty state prompt

- Will be used by new page template

* Convert API Logs view to new page template

+ use new empty state
+ add tests clarifying loading UX

* Update router

* Fix i18n ID
kibanamachine added a commit that referenced this pull request Jun 22, 2021
… polish (#102820) (#102987)

* Convert API Logs noItemsMessage to its own empty state prompt

- Will be used by new page template

* Convert API Logs view to new page template

+ use new empty state
+ add tests clarifying loading UX

* Update router

* Fix i18n ID

Co-authored-by: Constance <constancecchen@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Deprecated - use backport:version if exact versions are needed release_note:skip Skip the PR/issue when compiling release notes v7.14.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants