Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement groups view layout and styling #1729

Merged
merged 3 commits into from
Dec 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion resource/css/skosmos.css
Original file line number Diff line number Diff line change
Expand Up @@ -620,6 +620,11 @@ body {
font-weight: bold;
}

#tab-groups .sidebar-list .list-group-item .concept-label i {
color: var(--dark-color);
font-size: 14px;
}

.hierarchy-button {
background-color: transparent;
color: var(--vocab-text);
Expand All @@ -637,13 +642,15 @@ body {
position: absolute;
left: 11px;
top: 7px;
z-index: 1;
font-size: 12px;
}

.hierarchy-button img {
transform: rotate(-45deg);
position: absolute;
top: 9px;
left: 10px;
left: 11px;
width: 7px;
z-index: 1;
}
Expand Down
4 changes: 2 additions & 2 deletions resource/js/tab-alpha.js
Original file line number Diff line number Diff line change
Expand Up @@ -123,10 +123,10 @@ const tabAlphaApp = Vue.createApp({

// get height and width of pagination and sidebar tabs elements if they exist
const height = pagination && pagination.clientHeight + sidebarTabs.clientHeight
const width = pagination && pagination.clientWidth
const width = pagination && pagination.clientWidth - 1

this.listStyle = {
height: 'calc(100% - ' + height + 'px)',
height: 'calc(100% - ' + height + 'px )',
width: width + 'px'
}
}
Expand Down
8 changes: 7 additions & 1 deletion resource/js/tab-groups.js
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,12 @@ const tabGroupsApp = Vue.createApp({
}
},
setListStyle () {
// TODO: set list style when mounting component and resizing window
const height = document.getElementById('sidebar-tabs').clientHeight
const width = document.getElementById('sidebar-tabs').clientWidth - 1
this.listStyle = {
height: 'calc( 100% - ' + height + 'px )',
width: width + 'px'
}
},
loadChildren (group) {
// Load children only if group has children and they have not been loaded yet
Expand Down Expand Up @@ -275,6 +280,7 @@ tabGroupsApp.component('tab-groups', {
</template>
</button>
<span class="concept-label" :class="{ 'last': isLast }">
<i v-if="group.isGroup" class="property-hover fa-solid fa-layer-group"></i>
<a :class="{ 'selected': selectedGroup === group.uri }"
:href="getConceptURL(group.uri)"
@click="handleClickGroupEvent($event, group)"
Expand Down
4 changes: 2 additions & 2 deletions resource/js/tab-hierarchy.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,9 +156,9 @@ const tabHierApp = Vue.createApp({
},
setListStyle () {
const height = document.getElementById('sidebar-tabs').clientHeight
const width = document.getElementById('sidebar-tabs').clientWidth
const width = document.getElementById('sidebar-tabs').clientWidth - 1
this.listStyle = {
height: 'calc( 100% - ' + height + 'px)',
height: 'calc( 100% - ' + height + 'px )',
width: width + 'px'
}
},
Expand Down
Loading