@tekkare/auriga 0.2.209 → 0.2.211
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/module.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div
|
|
3
|
-
v-if="langs.length > 0"
|
|
3
|
+
v-if="langs.length > 0 && selectedItem"
|
|
4
4
|
class="language_container"
|
|
5
5
|
:class="[
|
|
6
6
|
showLangOptions ? 'open' : 'close',
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
<div class="oip_row v-center gap-4">
|
|
16
16
|
<arg-flag :iso="selectedItem.iso" height="18" emoji />
|
|
17
17
|
<p v-if="sidebarOpen !== false">
|
|
18
|
-
{{
|
|
18
|
+
{{ selectedItem.title }}
|
|
19
19
|
</p>
|
|
20
20
|
</div>
|
|
21
21
|
<arg-icon
|
|
@@ -80,18 +80,29 @@ export default defineComponent({
|
|
|
80
80
|
emits: ["onSelectLang", "update:Lang"],
|
|
81
81
|
setup(props, { emit }) {
|
|
82
82
|
const showLangOptions = ref(false);
|
|
83
|
-
|
|
84
|
-
props.langs
|
|
85
|
-
|
|
83
|
+
function findSelected() {
|
|
84
|
+
const index = props.langs.findIndex(
|
|
85
|
+
(a) => a.locale === props.default_locale
|
|
86
|
+
);
|
|
87
|
+
return index !== -1 ? props.langs[index] : props.langs[0];
|
|
88
|
+
}
|
|
89
|
+
const selectedItem = ref(findSelected());
|
|
86
90
|
onMounted(() => {
|
|
87
|
-
selectedItem.value =
|
|
91
|
+
selectedItem.value = findSelected();
|
|
88
92
|
});
|
|
89
93
|
watch(
|
|
90
94
|
() => props.default_locale,
|
|
91
95
|
() => {
|
|
92
|
-
selectedItem.value =
|
|
96
|
+
selectedItem.value = findSelected();
|
|
93
97
|
}
|
|
94
98
|
);
|
|
99
|
+
watch(
|
|
100
|
+
() => props.langs,
|
|
101
|
+
() => {
|
|
102
|
+
selectedItem.value = findSelected();
|
|
103
|
+
},
|
|
104
|
+
{ deep: true }
|
|
105
|
+
);
|
|
95
106
|
watch(
|
|
96
107
|
() => showLangOptions.value,
|
|
97
108
|
() => {
|
|
@@ -54,9 +54,9 @@
|
|
|
54
54
|
<div class="arg_sidebar_content">
|
|
55
55
|
<slot name="menu" />
|
|
56
56
|
</div>
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
57
|
+
</div>
|
|
58
|
+
<div class="arg_sidebar_footer">
|
|
59
|
+
<slot name="footer" />
|
|
60
60
|
</div>
|
|
61
61
|
|
|
62
62
|
<!-- Have a slot here for the submenus -->
|
|
@@ -145,5 +145,5 @@ export default defineComponent({
|
|
|
145
145
|
});
|
|
146
146
|
</script>
|
|
147
147
|
<style scoped>
|
|
148
|
-
.arg_sidebar{align-items:flex-start;background:var(--lightest);border-right:1px solid var(--light,#ececf2);box-sizing:border-box;display:flex;flex-direction:column;gap:16px;height:100vh;left:0;padding:16px 8px;position:fixed;top:0;transition:all .3s ease;width:54px;z-index:98}.arg_sidebar_open{width:200px}.arg_sidebar_header_full{align-items:center;align-self:stretch;display:flex}.arg_sidebar_header_full.center{display:flex;justify-content:space-between}.arg_sidebar_header_full.end{display:flex;justify-content:flex-end}.arg_sidebar_header_small{align-items:center;display:flex;flex-direction:column;gap:var(--xxs,4px)}.arg_sidebar_home{background:var(--transparent);border-radius:4px;color:var(--primary);cursor:pointer;font-size:14px;font-weight:400;gap:6px;height:32px;line-height:160%;padding:6px}.arg_sidebar_home,.arg_sidebar_title{align-items:center;display:flex;font-style:normal}.arg_sidebar_title{align-self:stretch;flex-direction:row;font-size:20px;font-weight:900;gap:8px;line-height:normal;margin-bottom:16px;padding:0 8px}.arg_sidebar_body{gap:16px;
|
|
148
|
+
.arg_sidebar{align-items:flex-start;background:var(--lightest);border-right:1px solid var(--light,#ececf2);box-sizing:border-box;display:flex;flex-direction:column;gap:16px;height:100vh;left:0;padding:16px 8px;position:fixed;top:0;transition:all .3s ease;width:54px;z-index:98}.arg_sidebar_open{width:200px}.arg_sidebar_header_full{align-items:center;align-self:stretch;display:flex}.arg_sidebar_header_full.center{display:flex;justify-content:space-between}.arg_sidebar_header_full.end{display:flex;justify-content:flex-end}.arg_sidebar_header_small{align-items:center;display:flex;flex-direction:column;gap:var(--xxs,4px)}.arg_sidebar_home{background:var(--transparent);border-radius:4px;color:var(--primary);cursor:pointer;font-size:14px;font-weight:400;gap:6px;height:32px;line-height:160%;padding:6px}.arg_sidebar_home,.arg_sidebar_title{align-items:center;display:flex;font-style:normal}.arg_sidebar_title{align-self:stretch;flex-direction:row;font-size:20px;font-weight:900;gap:8px;line-height:normal;margin-bottom:16px;padding:0 8px}.arg_sidebar_body{display:flex;flex:1;flex-direction:column;gap:16px;min-height:0;overflow:hidden;width:100%}.arg_sidebar_footer{width:100%}.arg_sidebar_content{display:flex;flex:1;flex-direction:column;gap:8px;min-height:0;overflow-y:auto}.arg_sidebar_content::-webkit-scrollbar{height:5px;width:5px}.arg_sidebar_content::-webkit-scrollbar-thumb{background:var(--medium);border-radius:12px!important}.arg_sidebar_content::-webkit-scrollbar-thumb:hover{background:var(--medium)!important}.sidebar_toggle{align-items:center;align-self:flex-end;background:transparent;border-radius:4px;cursor:pointer;display:flex;justify-content:center;padding:6px}.link_menu_tooltip_icon{flex:1 1 100%}.tooltip_display{display:flex!important}.arg_sidebar_home:hover,.sidebar_toggle:hover{background:var(--light,#ececf2)!important}
|
|
149
149
|
</style>
|