Skip to content

Commit a1b87d8

Browse files
add a reusable ActivityBarSeparator
1 parent b300938 commit a1b87d8

4 files changed

Lines changed: 16 additions & 15 deletions

File tree

client/src/components/ActivityBar/ActivityBar.vue

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ import localize from "@/utils/localization";
1919
import ChatHistoryPanel from "../ChatGXY/ChatHistoryPanel.vue";
2020
import InvocationsPanel from "../Panels/InvocationsPanel.vue";
2121
import ActivityBarHeader from "./ActivityBarHeader.vue";
22+
import ActivityBarSeparator from "./ActivityBarSeparator.vue";
2223
import ActivityItem from "./ActivityItem.vue";
2324
import InteractiveItem from "./Items/InteractiveItem.vue";
2425
import NotificationItem from "./Items/NotificationItem.vue";
@@ -332,7 +333,8 @@ defineExpose({
332333
</div>
333334
</draggable>
334335
</b-nav>
335-
<b-nav v-if="!isAnonymous" vertical class="activity-footer flex-nowrap p-1">
336+
<ActivityBarSeparator />
337+
<b-nav v-if="!isAnonymous" vertical class="flex-nowrap p-1">
336338
<template v-for="activity in props.specialActivities">
337339
<ActivityItem
338340
v-if="activity.panel"
@@ -466,11 +468,6 @@ defineExpose({
466468
display: none;
467469
}
468470
469-
.activity-footer {
470-
border-top: $border-default;
471-
border-top-style: dotted;
472-
}
473-
474471
.activity-popper-disabled {
475472
.popper-element {
476473
display: none;

client/src/components/ActivityBar/ActivityBarHeader.vue

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ import type { IconDefinition } from "@fortawesome/free-solid-svg-icons";
33
import { faChevronLeft, faHome } from "@fortawesome/free-solid-svg-icons";
44
import { FontAwesomeIcon } from "@fortawesome/vue-fontawesome";
55
6+
import ActivityBarSeparator from "./ActivityBarSeparator.vue";
7+
68
interface Props {
79
/** Whether an activity's side panel is currently open. */
810
isSideBarOpen: boolean;
@@ -41,7 +43,7 @@ function closeSidebar(event: KeyboardEvent | MouseEvent) {
4143
<FontAwesomeIcon :icon="props.isSideBarOpen ? faChevronLeft : props.icon" size="sm" fixed-width />
4244
<span class="activity-bar-header-text">{{ props.title }}</span>
4345
</div>
44-
<div class="activity-bar-header-divider" />
46+
<ActivityBarSeparator />
4547
</div>
4648
</template>
4749

@@ -66,9 +68,4 @@ function closeSidebar(event: KeyboardEvent | MouseEvent) {
6668
font-size: var(--font-size-small);
6769
}
6870
}
69-
70-
.activity-bar-header-divider {
71-
border-top: var(--border-default);
72-
border-top-style: dotted;
73-
}
7471
</style>
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<template>
2+
<div class="activity-bar-separator" />
3+
</template>
4+
5+
<style scoped lang="scss">
6+
.activity-bar-separator {
7+
border-top: 1px solid var(--color-grey-600);
8+
border-top-style: dotted;
9+
}
10+
</style>

client/src/style/scss/custom_theme_variables.scss

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,6 @@ html,
8585
--masthead-height: #{$masthead-height};
8686
--masthead-logo-height: calc(var(--masthead-height) - 0.5rem);
8787

88-
--border-color: #{$border-color};
89-
--border-default: #{$border-default};
90-
9188
--masthead-color: #{$masthead-color};
9289
--masthead-text-color: #{$masthead-text-color};
9390
--masthead-text-hover: #{$masthead-text-hover};

0 commit comments

Comments
 (0)