Skip to content

Commit

Permalink
Language localization
Browse files Browse the repository at this point in the history
  • Loading branch information
hujambo-dunia committed Nov 21, 2023
1 parent 8a79359 commit c305644
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions client/src/components/Form/FormRepeat.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { defineAsyncComponent, nextTick, type PropType } from "vue";
import { computed } from "vue";
import { useKeyedObjects } from "@/composables/keyedObjects";
import localize from "@/utils/localization";
import FormCard from "./FormCard.vue";
Expand All @@ -31,14 +32,14 @@ const minRepeats = computed(() => {
const buttonTooltip = computed(() => {
return maxRepeats.value
? `Maximum number of ${props.input.title || "Repeat"} fields reached`
: `Click to add ${props.input.title || "Repeat"} fields`;
? localize(`Maximum number of ${props.input.title || "Repeat"} fields reached`)
: localize(`Click to add ${props.input.title || "Repeat"} fields`);
});
const deleteTooltip = computed(() => {
return !minRepeats.value
? `Minimum number of ${props.input.title || "Repeat"} not reached`
: `Click to delete ${props.input.title || "Repeat"} fields`;
? localize(`Minimum number of ${props.input.title || "Repeat"} not reached`)
: localize(`Click to delete ${props.input.title || "Repeat"} fields`);
});
const props = defineProps({
Expand Down

0 comments on commit c305644

Please sign in to comment.