ember-primitives icon indicating copy to clipboard operation
ember-primitives copied to clipboard

Add Support for @activeOnSubPaths to Link component

Open rtablada opened this issue 1 year ago • 2 comments

Per #308 this adds a named arg @activeOnSubPaths to allow links to be considered active when child routes are the current URL.

The new @activeOnSubPaths arg defaults to false to retain existing active behavior without a breaking change. In a major release it may make sense to default this to true.

rtablada avatar May 14 '24 12:05 rtablada

In a major release it may make sense to default this to true.

I don't think the default will change, because sometimes you do want a differentiation between foo.index and foo.bar, which are foo/ and foo/bar respectively.

But this change is great! thanks for working on it! is the PR intended to still be draft?

NullVoxPopuli avatar May 14 '24 14:05 NullVoxPopuli

is the PR intended to still be draft?

I was still checking that the docs rendered and giving some 👀 after coffee.

Gonna check the ternary.

I'm :/ on the query params state not having a test right now so gonna work on a test state for that to go along with the includeActiveQueryParams render test

rtablada avatar May 14 '24 14:05 rtablada