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

Router link components improvement #1651

Merged
merged 20 commits into from
Jul 27, 2018
Merged

Router link components improvement #1651

merged 20 commits into from
Jul 27, 2018

Conversation

VdustR
Copy link
Member

@VdustR VdustR commented Mar 31, 2018

  • MdTabs, MdList, MdBottomBar, MdSteppers support all <router-link> props except tag via mixins.
  • Correct active highlight with exact and non-exact(sub) routes.
  • Custom default active class option.
  • Navigation Guards works, tested.
  • Documentation about working with vue router.
  • Better performance tabs with throttling setIndicatorStyles.
  • Better performance stppers with throttling calculateStepperPos.
  • Documentation about working with vue router.

fix #1644

fix exact router for active class

fix #1644
keep non-exact list item active when matched
better router active with class instead of comparing `to` prop
better router active with class instead of comparing `to` prop
prevent active bar item directly in sync route mode
@VdustR VdustR changed the title Router link components improvement Router link components improvement, not completed Mar 31, 2018
@VdustR VdustR changed the title Router link components improvement, not completed Router link components improvement Apr 4, 2018


export default (fn, time, option) => {
const leading = option ?
Copy link
Member

Choose a reason for hiding this comment

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

Those two functions are exactly the same.

@@ -0,0 +1,11 @@
export default {
Copy link
Member

Choose a reason for hiding this comment

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

Why recreate the MdRouterLink props if we can read them from Vue Router?

Copy link
Member Author

Choose a reason for hiding this comment

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

I can't make it work with only MdRouterLinkProps

@@ -45,7 +45,7 @@ export const routes = [
page: 'Components/Datepicker/Datepicker.vue'
},
{
path: '/components/steppers/:optional?',
path: '/components/steppers/:optional?/:sub?',
Copy link
Member

Choose a reason for hiding this comment

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

Is this :sub? needed? It's breaking the 'docs-build' task.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, they are for sub-subpages.

@Samuell1 Samuell1 merged commit fee1503 into vuematerial:dev Jul 27, 2018
@VdustR VdustR deleted the fix/router/exact branch July 27, 2018 12:10
This was referenced Aug 9, 2018
marcosmoura added a commit that referenced this pull request May 11, 2019
* origin: (55 commits)
  fix(MdSvgLoader): svg loader for invalid / missing mimetype (#1942)
  docs(Icon): fix minor typo (#1973)
  fix(MdRouterLink): new router-link registration name (#1978)
  chore: apply discord vanity URL (#1927)
  docs(ROADMAP.md): replace dead slack invite link with discord invite link (#1924)
  docs(Table): fix grammar issues (#1902)
  feat: router link components improvements (#1651)
  fix(MdTable): recalculate fixed header width on data changes (#1877)
  fix(MdDialogContent): missing theme class (#1876)
  docs(Elevation and Layout): Typos fixed and improved documentation. (#1878)
  fix(MdTable): nextTick selection data (#1874)
  docs(BottomBar): fix typo (#1875)
  docs(MdButton): escape a tag (#1872)
  docs(Input): typos and correction
  chore: upgrade dependencies
  fix(MdField): remove firefox required box-shadow
  feat: disable complexity rules for some methods
  fix(MdProgressSpinner): fix CSP error (#1850)
  fix: MdBadge do not accept color #1854 issue (#1856)
  fix: fix the repeated generated css theme classes if there is multiple themes defined (#1784)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[MdTabs] property "exact"
3 participants