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

fix ScopedHistory.createHref to prepend location with scoped history basePath #62407

Merged
merged 14 commits into from
Apr 11, 2020

Conversation

pgayvallet
Copy link
Contributor

Summary

Fix #62016

  • Change ScopedHistory.createHref default behavior to add the scoped history's path path to the location
  • add an option to directly call parent's history createHref without this behavior.

Checklist

@pgayvallet pgayvallet added Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc Feature:New Platform v8.0.0 release_note:skip Skip the PR/issue when compiling release notes v7.8 labels Apr 3, 2020
@pgayvallet pgayvallet requested a review from a team as a code owner April 3, 2020 08:36
@pgayvallet pgayvallet added this to Pending Review in kibana-core [DEPRECATED] via automation Apr 3, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-platform (Team:Platform)

Comment on lines 225 to 234
public createHref = (location: LocationDescriptorObject<HistoryLocationState>): Href => {
public createHref = (
location: LocationDescriptorObject<HistoryLocationState>,
prependBasePath: boolean = true
): Href => {
this.verifyActive();
return this.parentHistory.createHref(location);
return this.parentHistory.createHref(
prependBasePath ? this.prependBasePath(location) : location
);
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 think that in some case, plugins might want to be able to use createHref to create href pointing outside of their basePath, so I added this optional parameter.

Being optional, it preserves the History interface

@@ -268,8 +268,18 @@ describe('ScopedHistory', () => {
const gh = createMemoryHistory();
gh.push('/app/wow');
const h = new ScopedHistory(gh, '/app/wow');
expect(h.createHref({ pathname: '' })).toEqual(`/`);
expect(h.createHref({ pathname: '' })).toEqual(`/app/wow`);
Copy link
Contributor

Choose a reason for hiding this comment

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

I'd also expect:

expect(h.createHref({})).toEqual(`/app/wow`);

but looks like returns ''.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

prependBasePath was returning undefined when location.pathname was undefined. Changed it to return basepath instead in 460abe1

expect(h.createHref({ pathname: '/new-page', search: '?alpha=true' })).toEqual(
`/app/wow/new-page?alpha=true`
);
Copy link
Contributor

@Dosant Dosant Apr 6, 2020

Choose a reason for hiding this comment

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

I started working on #58137 and used this pr.
Looks like in real world the basename would have a trailing slash. (at least this is the case for my example plugin)
so for this test it would be instead of

const h = new ScopedHistory(gh, '/app/wow');

it would be:

const h = new ScopedHistory(gh, '/app/wow/');

And then this test would fail with: /app/wow//new-page?alpha=true (2 slashes)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You are right. This was caused by

  private prependBasePathToString(path: string): string {
    path = path.startsWith('/') ? path.slice(1) : path;
    return path.length ? `${this.basePath}/${path}` : this.basePath;
  }

Where ${this.basePath}/${path} always inserts a / between the paths.

Fixed in 460abe1

@rayafratkina rayafratkina added v7.8.0 and removed v7.8 labels Apr 6, 2020
onClick: () => history.push('/'),
onClick: () => history.push(''),
Copy link
Contributor Author

Choose a reason for hiding this comment

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

prependBasePathToString was incorrectly removing the trailing /, as this is fixed, I adapted the test plugins instead or changing every waitForUrlToBe('/app/foo'); to waitForUrlToBe('/app/foo/'); in test/plugin_functional/test_suites/core_plugins/applications.ts

@Dosant
Copy link
Contributor

Dosant commented Apr 7, 2020

Gave it another try with state syncing utils examples and works great. Didn't notice anything else 👍

@pgayvallet
Copy link
Contributor Author

pgayvallet commented Apr 7, 2020

@Dosant I think I will need to revert the change from your #62407 (comment) comment.

expect(h.createHref({})).toEqual(/app/wow);

It introduced a regression in part of the code using history.push for a location without a pathname to only change the actual search part of the url.

<EuiLink
data-test-subj="hostnameCellLink"
href={'?' + urlFromQueryParams({ ...queryParams, selected_host: id }).search}
onClick={(ev: React.MouseEvent) => {
ev.preventDefault();
history.push(urlFromQueryParams({ ...queryParams, selected_host: id }));
}}
>
{hostname}
</EuiLink>

history.push / history.createHref can accept a location without pathname, and that would create an url composed only of the search for example

history.create({ search: 'foo=bar'}) == '/?foo=bar'

changing that to

history.create({ search: 'foo=bar'}) == '/app/wow?foo=bar'

may not be such a good idea, or at least it's a breaking change in our ScopeHistory API.

@joshdover WDYT? Are the usage in kibana/x-pack/plugins/endpoint/public/applications/endpoint/view/hosts/index.tsx supposed correct, or should they specify a pathname?

@pgayvallet pgayvallet requested a review from a team as a code owner April 7, 2020 21:02
@joshdover
Copy link
Contributor

joshdover commented Apr 7, 2020

@joshdover WDYT? Are the usage in kibana/x-pack/plugins/endpoint/public/applications/endpoint/view/hosts/index.tsx supposed correct, or should they specify a pathname?

I believe this usage is valid, at least when comparing to using a raw History instance:

const history = createBrowserHistory({ basename: "/app/wow" });
history.push({ pathname: "/page2" });
history.push({ search: "foo=bar" });
console.log(history.location);
// => {search: "?foo=bar", pathname: "/page2", hash: ""}

I think we should be aiming to make the behavior of ScopedHistory match regular History as much as possible. If we look at how raw History works:

const history = createBrowserHistory({ basename: '/app/wow' });
console.log(history.createHref({ search: 'foo=bar' }))
// => /app/wow/?foo=bar 

We see that it does include the configured 'basename', even if no pathname is specified. I think it makes sense that createHref should always return full absolute paths, so even if pathname is undefined, we should still receive the entire path including Kibana's basePath and the appBasePath.

However, for history.push and history.replace it seems we should reuse the current pathname when none is specified by the caller:

  public push = (
    pathOrLocation: Path | LocationDescriptorObject<HistoryLocationState>,
    state?: HistoryLocationState
  ): void => {
    this.verifyActive();
    if (typeof pathOrLocation === 'string') {
      this.parentHistory.push(this.prependBasePath(pathOrLocation), state);
    } else {
+     pathOrLocation = {
+       pathname: this.location.pathname,
+       ...pathOrLocation
+     };
      this.parentHistory.push(this.prependBasePath(pathOrLocation));
    }
  };

  /**
   * Replaces the current location in the history stack. Does not remove forward or backward entries.
   *
   * @param pathOrLocation a string or location descriptor
   * @param state
   */
  public replace = (
    pathOrLocation: Path | LocationDescriptorObject<HistoryLocationState>,
    state?: HistoryLocationState
  ): void => {
    this.verifyActive();
    if (typeof pathOrLocation === 'string') {
      this.parentHistory.replace(this.prependBasePath(pathOrLocation), state);
    } else {
+     pathOrLocation = {
+       pathname: this.location.pathname,
+       ...pathOrLocation
+     };
      this.parentHistory.replace(this.prependBasePath(pathOrLocation));
    }

Does that adequately solve both cases?

@pgayvallet pgayvallet removed the request for review from a team April 7, 2020 21:32
@pgayvallet
Copy link
Contributor Author

After a quick slack discussion with @joshdover we decided to revert the change on prependBasePath to avoid impacting push and replace, and to inject the basepath in createHref instead when pathname is not specified. This should address the issue regarding createHref without introducing breaking change on the other methods that are remaining as close as possible as History implementation

public createHref = (location: LocationDescriptorObject<HistoryLocationState>): Href => {
public createHref = (
location: LocationDescriptorObject<HistoryLocationState>,
prependBasePath: boolean = true
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: could we use an options object for this to make adding things in the future non-breaking?

Suggested change
prependBasePath: boolean = true
{ prependBasePath = true }: { prependBasePath?: boolean } = {}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

👍 Don't even know why I didn't do it that way in the first place. Will do.

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

History

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

@pgayvallet pgayvallet merged commit bd159c7 into elastic:master Apr 11, 2020
kibana-core [DEPRECATED] automation moved this from Pending Review to Done (7.8) Apr 11, 2020
pgayvallet added a commit to pgayvallet/kibana that referenced this pull request Apr 11, 2020
…basePath (elastic#62407)

* fix createHref to prepend with scoped history basePath + add option to exclude it.

* fix prependBasePath behavior

* fix test plugins urls

* add pathname to endpoint url builder methods

* Revert "add pathname to endpoint url builder methods"

This reverts commit 7604932

* adapt createHref instead of prependBasePath

* use object options for createHref

* update generated doc
pgayvallet added a commit that referenced this pull request Apr 11, 2020
…basePath (#62407) (#63311)

* fix createHref to prepend with scoped history basePath + add option to exclude it.

* fix prependBasePath behavior

* fix test plugins urls

* add pathname to endpoint url builder methods

* Revert "add pathname to endpoint url builder methods"

This reverts commit 7604932

* adapt createHref instead of prependBasePath

* use object options for createHref

* update generated doc
majagrubic pushed a commit to majagrubic/kibana that referenced this pull request Apr 16, 2020
…basePath (elastic#62407)

* fix createHref to prepend with scoped history basePath + add option to exclude it.

* fix prependBasePath behavior

* fix test plugins urls

* add pathname to endpoint url builder methods

* Revert "add pathname to endpoint url builder methods"

This reverts commit 7604932

* adapt createHref instead of prependBasePath

* use object options for createHref

* update generated doc
majagrubic pushed a commit that referenced this pull request Apr 22, 2020
* Attempt at deangularization, nr.2

* Remove padding in fullscreen

* Fixing failing functional test

* Fixing remaining functional test

* Fixing typescript errors

* Fixing filter bar not being visible in fullscreen

* Fixing filter bar not being visible in fullscreen

* Rebasing against master

* Fixing a small leftover

* Fix order of functions

* Fixing linting error

* Changing noPadding to a custom class

* Use filterManagers to handle filters

* Rename class

* Attempt at deangularization, nr.2

* Remove padding in fullscreen

* Fixing failing functional test

* Fixing remaining functional test

* Fixing typescript errors

* Fixing filter bar not being visible in fullscreen

* Fixing filter bar not being visible in fullscreen

* Rebasing against master

* Fixing a small leftover

* Fix order of functions

* Fixing linting error

* [APM] Agent config select box doesn't work on IE (#63236)

* adding value property to select options

* fixing test

* Use globe icon for "ext" span type on service map (#63205)

Both "external" and "ext" can be returned and should have the same icon.

* Move shared vislib components into Charts plugin (#62957)

* Closes #56310

Move shared vislib components into Charts plugin

* Fixed imports in tests

* Changed i18n IDs to match charts namespace

* Renamed ColorSchemaVislibParams to ColorSchemaParams, added enums and got rid of useValidation function

* Renamed ColorSchemaVislibParams to ColorSchemaParams and got rid of useValidation function

* Fixed merge conflict

* Replaced enums with objects again

* Make uptime alert flyout test a little more resilient (#62702)

* [SIEM] [Cases] Unit tests for case UI components (#63005)

* Endpoint: Remove unused `lib` module (#63248)

* [Lens] Fix error in query from generated suggestion (#63018)

* [Lens] Fix error in query from generated suggestion

* Update from review comments

* Fix test

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

* Resolver/node svg 2 html (#62958)

* Remove some SVG in Resolver nodes and replace with HTML

* [Reporting] convert all server unit tests to TypeScript (#62873)

* [Reporting] convert all server unit tests to TypeScript

* fix ts

* revert unrelated change

* [SIEM] Link ML Rule card CTA to license_management (#63210)

* Link ML Rule card CTA to license_management

Taking the user directly to the license management page within kibana
(where they could immediately start a trial subscription) is much more
actionable than taking them to the subscriptions marketing page.

* Revert translation key change

Neither of these is totally accurate, and there've already been
translations written for the old one.

* Correctly type ILM's optional dependencies as optional (#63255)

And guard against their absence.

* [Telemetry] use prod keys (#63263)

* update chromedriver dependency to 81.0.0 (#63266)

* task/mac-eventing-form (#62999)

adds mac events form for endpoint policy details
Co-authored-by: oatkiller <robert.austin@elastic.co>

* bc6 rule import april 9 (#63152)

* bc6 rule import april 9

Increased the lookback of the ML rules

* re-import

with LF chars

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

* Added UI for pre-configured connectors. (#63074)

* Added UI for pre-configured connectors.

* fixed due to comments

* Fixed jest tests

* Fixed due to comments and added some functional tests

* test fix

* Fixed failed checks

* Fixed functional tests failing

* TaskManager tasks scheduled without attempting to run (#62078)

* TaskManager tasks scheduled without attempting to run

* Removing unused import

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

* Changed alerting wrong param name for help xpack.encrypted_saved_objects.encryptionKey to xpack.encryptedSavedObjects.encryptionKey (#63307)

* fix ScopedHistory.createHref to prepend location with scoped history basePath (#62407)

* fix createHref to prepend with scoped history basePath + add option to exclude it.

* fix prependBasePath behavior

* fix test plugins urls

* add pathname to endpoint url builder methods

* Revert "add pathname to endpoint url builder methods"

This reverts commit 7604932

* adapt createHref instead of prependBasePath

* use object options for createHref

* update generated doc

* fixing custom link popover size and hiding scroll (#63240)

* Changing noPadding to a custom class

* Use filterManagers to handle filters

* Rename class

* Applying some changes

* Reverting search_bar code changes

* Removing some stuff that was causing functional tests to fail

* Removing refresh dashboard container which was causing errors during navigation

* Do not destroy dashboardContainer

* Adding updateSavedQueryId method

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Cauê Marcondes <55978943+cauemarcondes@users.noreply.github.com>
Co-authored-by: Nathan L Smith <nathan.smith@elastic.co>
Co-authored-by: DianaDerevyankina <54894989+DianaDerevyankina@users.noreply.github.com>
Co-authored-by: Brian Seeders <brian.seeders@elastic.co>
Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
Co-authored-by: Robert Austin <robert.austin@elastic.co>
Co-authored-by: Wylie Conlon <william.conlon@elastic.co>
Co-authored-by: Brent Kimmel <bkimmel@users.noreply.github.com>
Co-authored-by: Tim Sullivan <tsullivan@users.noreply.github.com>
Co-authored-by: Ryland Herrick <ryalnd@gmail.com>
Co-authored-by: CJ Cenizal <cj@cenizal.com>
Co-authored-by: Ahmad Bamieh <ahmadbamieh@gmail.com>
Co-authored-by: Dmitry Lemeshko <dzmitry.lemechko@elastic.co>
Co-authored-by: Candace Park <56409205+parkiino@users.noreply.github.com>
Co-authored-by: The SpaceCake Project <randomuserid@users.noreply.github.com>
Co-authored-by: Yuliia Naumenko <jo.naumenko@gmail.com>
Co-authored-by: Brandon Kobel <brandon.kobel@elastic.co>
Co-authored-by: Pierre Gayvallet <pierre.gayvallet@elastic.co>
majagrubic pushed a commit to majagrubic/kibana that referenced this pull request Apr 22, 2020
* Attempt at deangularization, nr.2

* Remove padding in fullscreen

* Fixing failing functional test

* Fixing remaining functional test

* Fixing typescript errors

* Fixing filter bar not being visible in fullscreen

* Fixing filter bar not being visible in fullscreen

* Rebasing against master

* Fixing a small leftover

* Fix order of functions

* Fixing linting error

* Changing noPadding to a custom class

* Use filterManagers to handle filters

* Rename class

* Attempt at deangularization, nr.2

* Remove padding in fullscreen

* Fixing failing functional test

* Fixing remaining functional test

* Fixing typescript errors

* Fixing filter bar not being visible in fullscreen

* Fixing filter bar not being visible in fullscreen

* Rebasing against master

* Fixing a small leftover

* Fix order of functions

* Fixing linting error

* [APM] Agent config select box doesn't work on IE (elastic#63236)

* adding value property to select options

* fixing test

* Use globe icon for "ext" span type on service map (elastic#63205)

Both "external" and "ext" can be returned and should have the same icon.

* Move shared vislib components into Charts plugin (elastic#62957)

* Closes elastic#56310

Move shared vislib components into Charts plugin

* Fixed imports in tests

* Changed i18n IDs to match charts namespace

* Renamed ColorSchemaVislibParams to ColorSchemaParams, added enums and got rid of useValidation function

* Renamed ColorSchemaVislibParams to ColorSchemaParams and got rid of useValidation function

* Fixed merge conflict

* Replaced enums with objects again

* Make uptime alert flyout test a little more resilient (elastic#62702)

* [SIEM] [Cases] Unit tests for case UI components (elastic#63005)

* Endpoint: Remove unused `lib` module (elastic#63248)

* [Lens] Fix error in query from generated suggestion (elastic#63018)

* [Lens] Fix error in query from generated suggestion

* Update from review comments

* Fix test

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

* Resolver/node svg 2 html (elastic#62958)

* Remove some SVG in Resolver nodes and replace with HTML

* [Reporting] convert all server unit tests to TypeScript (elastic#62873)

* [Reporting] convert all server unit tests to TypeScript

* fix ts

* revert unrelated change

* [SIEM] Link ML Rule card CTA to license_management (elastic#63210)

* Link ML Rule card CTA to license_management

Taking the user directly to the license management page within kibana
(where they could immediately start a trial subscription) is much more
actionable than taking them to the subscriptions marketing page.

* Revert translation key change

Neither of these is totally accurate, and there've already been
translations written for the old one.

* Correctly type ILM's optional dependencies as optional (elastic#63255)

And guard against their absence.

* [Telemetry] use prod keys (elastic#63263)

* update chromedriver dependency to 81.0.0 (elastic#63266)

* task/mac-eventing-form (elastic#62999)

adds mac events form for endpoint policy details
Co-authored-by: oatkiller <robert.austin@elastic.co>

* bc6 rule import april 9 (elastic#63152)

* bc6 rule import april 9

Increased the lookback of the ML rules

* re-import

with LF chars

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

* Added UI for pre-configured connectors. (elastic#63074)

* Added UI for pre-configured connectors.

* fixed due to comments

* Fixed jest tests

* Fixed due to comments and added some functional tests

* test fix

* Fixed failed checks

* Fixed functional tests failing

* TaskManager tasks scheduled without attempting to run (elastic#62078)

* TaskManager tasks scheduled without attempting to run

* Removing unused import

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

* Changed alerting wrong param name for help xpack.encrypted_saved_objects.encryptionKey to xpack.encryptedSavedObjects.encryptionKey (elastic#63307)

* fix ScopedHistory.createHref to prepend location with scoped history basePath (elastic#62407)

* fix createHref to prepend with scoped history basePath + add option to exclude it.

* fix prependBasePath behavior

* fix test plugins urls

* add pathname to endpoint url builder methods

* Revert "add pathname to endpoint url builder methods"

This reverts commit 7604932

* adapt createHref instead of prependBasePath

* use object options for createHref

* update generated doc

* fixing custom link popover size and hiding scroll (elastic#63240)

* Changing noPadding to a custom class

* Use filterManagers to handle filters

* Rename class

* Applying some changes

* Reverting search_bar code changes

* Removing some stuff that was causing functional tests to fail

* Removing refresh dashboard container which was causing errors during navigation

* Do not destroy dashboardContainer

* Adding updateSavedQueryId method

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Cauê Marcondes <55978943+cauemarcondes@users.noreply.github.com>
Co-authored-by: Nathan L Smith <nathan.smith@elastic.co>
Co-authored-by: DianaDerevyankina <54894989+DianaDerevyankina@users.noreply.github.com>
Co-authored-by: Brian Seeders <brian.seeders@elastic.co>
Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
Co-authored-by: Robert Austin <robert.austin@elastic.co>
Co-authored-by: Wylie Conlon <william.conlon@elastic.co>
Co-authored-by: Brent Kimmel <bkimmel@users.noreply.github.com>
Co-authored-by: Tim Sullivan <tsullivan@users.noreply.github.com>
Co-authored-by: Ryland Herrick <ryalnd@gmail.com>
Co-authored-by: CJ Cenizal <cj@cenizal.com>
Co-authored-by: Ahmad Bamieh <ahmadbamieh@gmail.com>
Co-authored-by: Dmitry Lemeshko <dzmitry.lemechko@elastic.co>
Co-authored-by: Candace Park <56409205+parkiino@users.noreply.github.com>
Co-authored-by: The SpaceCake Project <randomuserid@users.noreply.github.com>
Co-authored-by: Yuliia Naumenko <jo.naumenko@gmail.com>
Co-authored-by: Brandon Kobel <brandon.kobel@elastic.co>
Co-authored-by: Pierre Gayvallet <pierre.gayvallet@elastic.co>
majagrubic pushed a commit that referenced this pull request Apr 22, 2020
* Attempt at deangularization, nr.2

* Remove padding in fullscreen

* Fixing failing functional test

* Fixing remaining functional test

* Fixing typescript errors

* Fixing filter bar not being visible in fullscreen

* Fixing filter bar not being visible in fullscreen

* Rebasing against master

* Fixing a small leftover

* Fix order of functions

* Fixing linting error

* Changing noPadding to a custom class

* Use filterManagers to handle filters

* Rename class

* Attempt at deangularization, nr.2

* Remove padding in fullscreen

* Fixing failing functional test

* Fixing remaining functional test

* Fixing typescript errors

* Fixing filter bar not being visible in fullscreen

* Fixing filter bar not being visible in fullscreen

* Rebasing against master

* Fixing a small leftover

* Fix order of functions

* Fixing linting error

* [APM] Agent config select box doesn't work on IE (#63236)

* adding value property to select options

* fixing test

* Use globe icon for "ext" span type on service map (#63205)

Both "external" and "ext" can be returned and should have the same icon.

* Move shared vislib components into Charts plugin (#62957)

* Closes #56310

Move shared vislib components into Charts plugin

* Fixed imports in tests

* Changed i18n IDs to match charts namespace

* Renamed ColorSchemaVislibParams to ColorSchemaParams, added enums and got rid of useValidation function

* Renamed ColorSchemaVislibParams to ColorSchemaParams and got rid of useValidation function

* Fixed merge conflict

* Replaced enums with objects again

* Make uptime alert flyout test a little more resilient (#62702)

* [SIEM] [Cases] Unit tests for case UI components (#63005)

* Endpoint: Remove unused `lib` module (#63248)

* [Lens] Fix error in query from generated suggestion (#63018)

* [Lens] Fix error in query from generated suggestion

* Update from review comments

* Fix test

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

* Resolver/node svg 2 html (#62958)

* Remove some SVG in Resolver nodes and replace with HTML

* [Reporting] convert all server unit tests to TypeScript (#62873)

* [Reporting] convert all server unit tests to TypeScript

* fix ts

* revert unrelated change

* [SIEM] Link ML Rule card CTA to license_management (#63210)

* Link ML Rule card CTA to license_management

Taking the user directly to the license management page within kibana
(where they could immediately start a trial subscription) is much more
actionable than taking them to the subscriptions marketing page.

* Revert translation key change

Neither of these is totally accurate, and there've already been
translations written for the old one.

* Correctly type ILM's optional dependencies as optional (#63255)

And guard against their absence.

* [Telemetry] use prod keys (#63263)

* update chromedriver dependency to 81.0.0 (#63266)

* task/mac-eventing-form (#62999)

adds mac events form for endpoint policy details
Co-authored-by: oatkiller <robert.austin@elastic.co>

* bc6 rule import april 9 (#63152)

* bc6 rule import april 9

Increased the lookback of the ML rules

* re-import

with LF chars

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

* Added UI for pre-configured connectors. (#63074)

* Added UI for pre-configured connectors.

* fixed due to comments

* Fixed jest tests

* Fixed due to comments and added some functional tests

* test fix

* Fixed failed checks

* Fixed functional tests failing

* TaskManager tasks scheduled without attempting to run (#62078)

* TaskManager tasks scheduled without attempting to run

* Removing unused import

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

* Changed alerting wrong param name for help xpack.encrypted_saved_objects.encryptionKey to xpack.encryptedSavedObjects.encryptionKey (#63307)

* fix ScopedHistory.createHref to prepend location with scoped history basePath (#62407)

* fix createHref to prepend with scoped history basePath + add option to exclude it.

* fix prependBasePath behavior

* fix test plugins urls

* add pathname to endpoint url builder methods

* Revert "add pathname to endpoint url builder methods"

This reverts commit 7604932

* adapt createHref instead of prependBasePath

* use object options for createHref

* update generated doc

* fixing custom link popover size and hiding scroll (#63240)

* Changing noPadding to a custom class

* Use filterManagers to handle filters

* Rename class

* Applying some changes

* Reverting search_bar code changes

* Removing some stuff that was causing functional tests to fail

* Removing refresh dashboard container which was causing errors during navigation

* Do not destroy dashboardContainer

* Adding updateSavedQueryId method

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Cauê Marcondes <55978943+cauemarcondes@users.noreply.github.com>
Co-authored-by: Nathan L Smith <nathan.smith@elastic.co>
Co-authored-by: DianaDerevyankina <54894989+DianaDerevyankina@users.noreply.github.com>
Co-authored-by: Brian Seeders <brian.seeders@elastic.co>
Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
Co-authored-by: Robert Austin <robert.austin@elastic.co>
Co-authored-by: Wylie Conlon <william.conlon@elastic.co>
Co-authored-by: Brent Kimmel <bkimmel@users.noreply.github.com>
Co-authored-by: Tim Sullivan <tsullivan@users.noreply.github.com>
Co-authored-by: Ryland Herrick <ryalnd@gmail.com>
Co-authored-by: CJ Cenizal <cj@cenizal.com>
Co-authored-by: Ahmad Bamieh <ahmadbamieh@gmail.com>
Co-authored-by: Dmitry Lemeshko <dzmitry.lemechko@elastic.co>
Co-authored-by: Candace Park <56409205+parkiino@users.noreply.github.com>
Co-authored-by: The SpaceCake Project <randomuserid@users.noreply.github.com>
Co-authored-by: Yuliia Naumenko <jo.naumenko@gmail.com>
Co-authored-by: Brandon Kobel <brandon.kobel@elastic.co>
Co-authored-by: Pierre Gayvallet <pierre.gayvallet@elastic.co>

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Cauê Marcondes <55978943+cauemarcondes@users.noreply.github.com>
Co-authored-by: Nathan L Smith <nathan.smith@elastic.co>
Co-authored-by: DianaDerevyankina <54894989+DianaDerevyankina@users.noreply.github.com>
Co-authored-by: Brian Seeders <brian.seeders@elastic.co>
Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
Co-authored-by: Robert Austin <robert.austin@elastic.co>
Co-authored-by: Wylie Conlon <william.conlon@elastic.co>
Co-authored-by: Brent Kimmel <bkimmel@users.noreply.github.com>
Co-authored-by: Tim Sullivan <tsullivan@users.noreply.github.com>
Co-authored-by: Ryland Herrick <ryalnd@gmail.com>
Co-authored-by: CJ Cenizal <cj@cenizal.com>
Co-authored-by: Ahmad Bamieh <ahmadbamieh@gmail.com>
Co-authored-by: Dmitry Lemeshko <dzmitry.lemechko@elastic.co>
Co-authored-by: Candace Park <56409205+parkiino@users.noreply.github.com>
Co-authored-by: The SpaceCake Project <randomuserid@users.noreply.github.com>
Co-authored-by: Yuliia Naumenko <jo.naumenko@gmail.com>
Co-authored-by: Brandon Kobel <brandon.kobel@elastic.co>
Co-authored-by: Pierre Gayvallet <pierre.gayvallet@elastic.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:New Platform release_note:skip Skip the PR/issue when compiling release notes Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc v7.8.0 v8.0.0
Projects
Development

Successfully merging this pull request may close these issues.

ScopedHistory#createHref implementation does not include the local basePath
6 participants