Skip to content

Commit

Permalink
add docs link on the main menu
Browse files Browse the repository at this point in the history
  • Loading branch information
dsschult committed Oct 31, 2023
1 parent 0123ebb commit 20fcfad
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions cypress/integration/home.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ context('Home Page', () => {

cy.get('#nav .active').contains('home', {matchCase: false})
cy.get('#nav li').contains('institutions', {matchCase: false}).should('not.exist')
cy.get('#nav li').contains('docs', {matchCase: false})

cy.get('.account .login-link').should('contain', 'Sign in')

Expand Down
7 changes: 6 additions & 1 deletion user_mgmt/static/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,11 @@ Vue.component('navpage', {
this.current = to.params.route
next()
},
template: '<li :class="classObj"><router-link :to="path">{{ name }}</router-link></li>'
template: `
<li :class="classObj">
<a v-if="path.startsWith('http')" :href="path">{{ name }}</a>
<router-link v-else :to="path">{{ name }}</router-link>
</li>`
});

Vue.component('account', {
Expand Down Expand Up @@ -208,6 +212,7 @@ export default async function vue_startup(keycloak){
{ path: '/groups', name: 'Groups', component: Groups,
props: {keycloak: keycloak}, meta: { requiresAuth: true, requiresGroupAdmin: true }
},
{ path: 'https://docs.icecube.aq/Madison-account/user-workflow/', name: 'Docs' },
{ path: '*', name: '404', component: Error404, props: true }
];

Expand Down

0 comments on commit 20fcfad

Please sign in to comment.