Skip to content

Commit

Permalink
Fix secondary button with old style as temporary solution
Browse files Browse the repository at this point in the history
Signed-off-by: Joas Schilling <coding@schilljs.com>
  • Loading branch information
nickvergessen committed Mar 21, 2022
1 parent 44c3ef1 commit 88001c4
Showing 1 changed file with 17 additions and 5 deletions.
22 changes: 17 additions & 5 deletions src/components/Button/Button.vue
Original file line number Diff line number Diff line change
Expand Up @@ -256,12 +256,9 @@ export default {
type: {
type: String,
validator(value) {
// Disallowing secondary until we solve theming and
// accessibility issues.
// https://github.com/nextcloud/nextcloud-vue/issues/2538
return ['primary', 'tertiary', 'error', 'warning', 'success'].indexOf(value) !== -1
return ['primary', 'secondary', 'tertiary', 'error', 'warning', 'success'].indexOf(value) !== -1
},
default: '',
default: 'secondary',
},
/**
Expand Down Expand Up @@ -516,6 +513,9 @@ export default {
&.button-vue--vue-primary {
background-color: var(--color-primary-hover);
}
&.button-vue--vue-secondary {
box-shadow: 0 0 0 2px var(--color-main-text);
}
&.button-vue--vue-tertiary {
color: var(--color-main-text);
}
Expand Down Expand Up @@ -546,6 +546,18 @@ export default {
}
}
// Secondary
&--vue-secondary {
color: var(--color-main-text);
background-color: var(--color-background-dark);
box-shadow: 0 0 0 2px var(--color-border-dark);
&:hover {
color: var(--color-main-text);
background-color: var(--color-background-dark);
box-shadow: 0 0 0 2px var(--color-primary-element);
}
}
// Tertiary
&--vue-tertiary {
color: var(--color-text-lighter);
Expand Down

0 comments on commit 88001c4

Please sign in to comment.