Skip to content

Commit

Permalink
fix(a11y): fixed typo in diff style button
Browse files Browse the repository at this point in the history
  • Loading branch information
technikhil314 committed Sep 26, 2024
1 parent a0b8025 commit 1fc5450
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions components/buttons/diffStyle.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<button
class="inline-flex items-center justify-center px-1 py-1 text-sm text-gray-600 transition-transform transform bg-gray-300 border border-gray-800 rounded-sm dark:border-gray-400 dark:text-white dark:bg-gray-800 align-center focus-visible:ring-4 active:scale-y-75"
class="inline-flex items-center justify-center px-1 py-1 text-sm text-gray-600 transition-transform transform bg-gray-300 border border-gray-800 rounded-sm dark:border-gray-400 dark:text-white dark:bg-gray-800 align-center focus-visible:ring-4 active:scale-y-75"
role="button"
:aria-label="label"
:title="label"
Expand All @@ -20,8 +20,8 @@
</template>

<script lang="ts">
import Vue from 'vue'
import DiffStyle from '~/components/icons/diffStyle.vue'
import Vue from "vue";
import DiffStyle from "~/components/icons/diffStyle.vue";
export default Vue.extend({
components: { DiffStyle },
props: {
Expand All @@ -33,21 +33,21 @@ export default Vue.extend({
data() {
return {
sideBySide: true,
}
};
},
computed: {
label() {
if (this.sideBySide) {
return 'Switch unified diff layout'
return "Switch to unified diff layout";
}
return 'Switch to split diff layout'
return "Switch to split diff layout";
},
},
methods: {
handleClick() {
this.sideBySide = !this.sideBySide
this.clickHandler(this.sideBySide === true)
this.sideBySide = !this.sideBySide;
this.clickHandler(this.sideBySide === true);
},
},
})
});
</script>

0 comments on commit 1fc5450

Please sign in to comment.