-
Notifications
You must be signed in to change notification settings - Fork 388
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into feat/add-webhooks-feature-branch
- Loading branch information
Showing
19 changed files
with
224 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
62 changes: 62 additions & 0 deletions
62
argilla-frontend/components/features/user-settings/UserSettingsLanguage.vue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
<template> | ||
<div class="language-switch"> | ||
<BaseTooltip | ||
class="language-switch__item" | ||
v-for="{ code, name } in languages" | ||
:key="code" | ||
:text="name" | ||
:minimalist="false" | ||
> | ||
<input | ||
type="radio" | ||
:id="code" | ||
:value="code" | ||
v-model="$i18n.locale" | ||
@input="change(code)" | ||
/> | ||
<label :for="code"> {{ code }}</label> | ||
</BaseTooltip> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
import { useUserSettingsLanguageViewModel } from "./useUserSettingsLanguageViewModel"; | ||
export default { | ||
setup() { | ||
return useUserSettingsLanguageViewModel(); | ||
}, | ||
}; | ||
</script> | ||
|
||
<style scoped lang="scss"> | ||
.language-switch { | ||
display: flex; | ||
gap: $base-space * 2; | ||
padding: $base-space * 2 0; | ||
} | ||
input { | ||
display: none; | ||
} | ||
label { | ||
display: flex; | ||
flex-direction: column; | ||
gap: $base-space; | ||
align-items: center; | ||
min-width: 40px; | ||
padding: $base-space * 2; | ||
background: var(--bg-opacity-4); | ||
border-radius: 6px; | ||
border: 1px solid var(--bg-opacity-4); | ||
color: var(--fg-secondary); | ||
text-transform: uppercase; | ||
&:hover { | ||
transition: color 0.3s ease; | ||
color: var(--fg-primary); | ||
} | ||
} | ||
input:checked + label { | ||
border-color: var(--fg-cuaternary); | ||
color: var(--fg-primary); | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
argilla-frontend/components/features/user-settings/useUserSettingsLanguageViewModel.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import { useContext } from "@nuxtjs/composition-api"; | ||
import { useLanguageChanger } from "~/v1/infrastructure/services"; | ||
|
||
export const useUserSettingsLanguageViewModel = () => { | ||
const context = useContext(); | ||
const { change, languages } = useLanguageChanger(context); | ||
|
||
return { | ||
change, | ||
languages, | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 5 additions & 2 deletions
7
argilla-frontend/v1/infrastructure/services/useColorSchema.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.