Skip to content

Sync-in · Sovereign platform for file storage, sharing, synchronization, and collaboration.

chore(frontend): ui colors

johavenf1dc7dd37283
diff --git a/frontend/src/app/applications/spaces/components/dialogs/space-dialog.component.html b/frontend/src/app/applications/spaces/components/dialogs/space-dialog.component.html
index ae26b78a..172d223a 100644
--- a/frontend/src/app/applications/spaces/components/dialogs/space-dialog.component.html
+++ b/frontend/src/app/applications/spaces/components/dialogs/space-dialog.component.html
@@ -19,7 +19,7 @@
</div>
<div class="modal-body">
<tabset [justified]="true" type="pills">
- <tab (selectTab)="tabView=null" customClass="tab-dialog form-validation">
+ <tab (selectTab)="tabView=null" customClass="tab-dialog">
<ng-template tabHeading>
<span class="app-tab-heading">
<fa-icon [icon]="icons.faCog"></fa-icon>
@@ -117,6 +117,7 @@
[searchFunction]="searchManagers.bind(this)"
[editMode]="editManagers"
[hideInput]="!editManagers"
+ [rowBackgroundClass]="''"
[customPlaceholder]="'Type to search for managers to add'">
</app-user-search>
@if (!space.managers.length) {
diff --git a/frontend/src/app/applications/spaces/components/utils/space-manage-roots.component.html b/frontend/src/app/applications/spaces/components/utils/space-manage-roots.component.html
index c99aed2b..772d92cf 100644
--- a/frontend/src/app/applications/spaces/components/utils/space-manage-roots.component.html
+++ b/frontend/src/app/applications/spaces/components/utils/space-manage-roots.component.html
@@ -1,5 +1,5 @@
@for (r of space.roots; track r.alias) {
- <div class="bg-theme mb-1 p-2" style="border-radius: 4px">
+ <div class="bg-theme mb-1 px-3 py-2" style="border-radius: 4px">
<div class="d-flex align-items-center text-truncate no-select fs-xs" style="max-height: 34px">
<div class="d-flex align-items-center text-truncate me-auto">
@if (showUsers) {
diff --git a/frontend/src/app/applications/users/components/utils/user-search.component.ts b/frontend/src/app/applications/users/components/utils/user-search.component.ts
index 511ccaaf..c5f5e344 100644
--- a/frontend/src/app/applications/users/components/utils/user-search.component.ts
+++ b/frontend/src/app/applications/users/components/utils/user-search.component.ts
@@ -47,6 +47,7 @@ export class UserSearchComponent implements OnInit {
@Input() searchFunction: (search: string) => any
@Input() editFunction: (member: MemberModel) => void = null
@Input() customPlaceholder: string
+ @Input() rowBackgroundClass = 'bg-theme'
protected locale = inject<L10nLocale>(L10N_LOCALE)
protected readonly MEMBER_TYPE = MEMBER_TYPE
protected readonly originalOrderKeyValue = originalOrderKeyValue
diff --git a/frontend/src/app/applications/users/components/utils/users-search.component.html b/frontend/src/app/applications/users/components/utils/users-search.component.html
index ed97943a..35939863 100644
--- a/frontend/src/app/applications/users/components/utils/users-search.component.html
+++ b/frontend/src/app/applications/users/components/utils/users-search.component.html
@@ -21,28 +21,30 @@
</div>
</ng-template>
@if (!hideInput) {
- <input
- #InputTypeHead
- (typeaheadOnSelect)="onSelect($event)"
- (typeaheadLoading)="onLoading()"
- (typeaheadNoResults)="onNoResults()"
- (typeaheadOnPreview)="onPreview()"
- [(ngModel)]="selection"
- [placeholder]="placeHolder | translate: locale.language"
- [typeaheadItemTemplate]="searchMembers"
- [typeaheadAsync]="true"
- [typeaheadMinLength]="0"
- [typeaheadSingleWords]="true"
- [typeaheadOptionField]="'name'"
- [typeaheadWaitMs]="100"
- [typeaheadHideResultsOnBlur]="true"
- [typeahead]="asyncSearchUsersOrGroups"
- class="form-control form-control-sm mb-2"
- />
+ <div class="form-validation">
+ <input
+ #InputTypeHead
+ (typeaheadOnSelect)="onSelect($event)"
+ (typeaheadLoading)="onLoading()"
+ (typeaheadNoResults)="onNoResults()"
+ (typeaheadOnPreview)="onPreview()"
+ [(ngModel)]="selection"
+ [placeholder]="placeHolder | translate: locale.language"
+ [typeaheadItemTemplate]="searchMembers"
+ [typeaheadAsync]="true"
+ [typeaheadMinLength]="0"
+ [typeaheadSingleWords]="true"
+ [typeaheadOptionField]="'name'"
+ [typeaheadWaitMs]="100"
+ [typeaheadHideResultsOnBlur]="true"
+ [typeahead]="asyncSearchUsersOrGroups"
+ class="form-control form-control-sm mb-3"
+ />
+ </div>
}
<div class="col-12 mt-1">
@for (member of members; track member.mid) {
- <div class="bg-theme mb-1 p-2" style="border-radius: 4px">
+ <div class="{{rowBackgroundClass}} mb-1 px-3 py-2" style="border-radius: 4px">
<div class="d-flex align-items-center text-truncate no-select fs-xs" style="max-height: 34px">
<div class="d-flex align-items-center text-truncate me-auto">
@if (member.isUser) {
@@ -106,4 +108,4 @@
</div>
</div>
}
-</div>
\ No newline at end of file
+</div>
diff --git a/frontend/src/app/common/components/filter.component.ts b/frontend/src/app/common/components/filter.component.ts
index 2b4ee040..81e20794 100644
--- a/frontend/src/app/common/components/filter.component.ts
+++ b/frontend/src/app/common/components/filter.component.ts
@@ -1,7 +1,7 @@
import { Component, ElementRef, HostListener, inject, OnDestroy, signal, ViewChild } from '@angular/core'
import { FormBuilder, FormControl, ReactiveFormsModule } from '@angular/forms'
import { FaIconComponent } from '@fortawesome/angular-fontawesome'
-import { faTimes } from '@fortawesome/free-solid-svg-icons'
+import { faFilter, faTimes } from '@fortawesome/free-solid-svg-icons'
import { L10N_LOCALE, L10nLocale, L10nTranslatePipe } from 'angular-l10n'
import { Subscription } from 'rxjs'
import { debounceTime, distinctUntilChanged } from 'rxjs/operators'
@@ -10,20 +10,20 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'
selector: 'app-input-filter',
imports: [ReactiveFormsModule, L10nTranslatePipe, FaIconComponent],
template: `
- <div class="btn-group" style="height: 30px; max-width: 150px">
+ <div class="filter-shell" [class.has-value]="!!search()">
+ <fa-icon class="filter-icon" [icon]="faFilterIcon"></fa-icon>
<input
#iFilter
type="text"
- class="form-control form-control-sm"
- style="padding-right: 24px"
+ autocomplete="off"
(keyup.escape)="clear()"
- [placeholder]="('Filter' | translate: locale.language) + ' (Ctrl/⌘+F)'"
+ [placeholder]="('Filter' | translate: locale.language) + ' (' + shortcutHint + ')'"
[formControl]="searchControl"
/>
@if (search()) {
- <span class="cursor-pointer" style="position: absolute; right: 5px; top: 3px; z-index: 1001; font-size: 1rem">
- <fa-icon (click)="clear()" [icon]="faTimes" role="button"></fa-icon>
- </span>
+ <button (click)="clear()" type="button" class="clear-btn" aria-label="Clear filter">
+ <fa-icon [icon]="faTimes"></fa-icon>
+ </button>
}
</div>
`
@@ -33,7 +33,9 @@ export class FilterComponent implements OnDestroy {
public search = signal('')
protected readonly locale = inject<L10nLocale>(L10N_LOCALE)
protected readonly searchControl: FormControl
+ protected readonly faFilterIcon = faFilter
protected readonly faTimes = faTimes
+ protected readonly shortcutHint = this.getShortcutHint()
private readonly fb = inject(FormBuilder)
private readonly subscription: Subscription
@@ -69,4 +71,13 @@ export class FilterComponent implements OnDestroy {
onType(value: string) {
this.search.set(value)
}
+
+ private getShortcutHint(): string {
+ if (typeof navigator === 'undefined') {
+ return 'Ctrl+F'
+ }
+
+ const platform = `${navigator.platform ?? ''} ${navigator.userAgent ?? ''}`
+ return /mac|iphone|ipad|ipod/i.test(platform) ? '⌘+F' : 'Ctrl+F'
+ }
}
diff --git a/frontend/src/i18n/en.json b/frontend/src/i18n/en.json
index 3f0badf2..e4062fb0 100644
--- a/frontend/src/i18n/en.json
+++ b/frontend/src/i18n/en.json
@@ -1,5 +1,5 @@
{
- "no_task": "no task",
+ "no_task": "No task",
"one_task": "{{ nb }} task completed",
"nb_tasks": "{{ nb }} tasks completed",
"one_active_task": "{{ nba }} task in progress on {{ nb }}",
@@ -15,9 +15,9 @@
"delete_one_file": "Do you want to permanently delete <b>{{arg}}</b> ?",
"trash_multiple_files": "Would you like to move <b>{{arg}} files</b> to trash ?",
"delete_multiple_files": "Do you want to permanently delete these <b>{{arg}} files</b> ?",
- "scheduler_unit_hour": "scheduler_unit_hour",
- "scheduler_unit_minute": "scheduler_unit_minute",
- "scheduler_unit_day": "scheduler_unit_day",
+ "scheduler_unit_hour": "hours",
+ "scheduler_unit_minute": "minutes",
+ "scheduler_unit_day": "days",
"no_selection": "no item selected",
"one_selection": "{{ nb }} item selected",
"nb_selections": "{{ nb }} items selected",
diff --git a/frontend/src/styles/components/_app.scss b/frontend/src/styles/components/_app.scss
index 35555915..3efbe199 100755
--- a/frontend/src/styles/components/_app.scss
+++ b/frontend/src/styles/components/_app.scss
@@ -295,6 +295,70 @@
}
}
+app-input-filter {
+ display: inline-block;
+ width: 150px;
+ min-width: 150px;
+ margin: 0;
+ vertical-align: middle;
+
+ .filter-shell {
+ position: relative;
+ display: flex;
+ align-items: center;
+ width: 100%;
+ height: 30px;
+ border: 1px solid transparent;
+ border-radius: $btn-border-radius-sm;
+
+ input {
+ width: 100%;
+ height: 100%;
+ border: 0;
+ outline: 0;
+ background: transparent;
+ font-size: $font-size-2xs;
+ line-height: 1.5;
+ padding: 0 31px 0 29px;
+
+ &::placeholder {
+ font-size: $font-size-2xs;
+ opacity: 1;
+ }
+ }
+ }
+
+ .filter-icon {
+ position: absolute;
+ left: 9px;
+ pointer-events: none;
+ font-size: .68rem;
+ }
+
+ .clear-btn {
+ position: absolute;
+ right: 6px;
+ display: inline-flex;
+ align-items: center;
+ justify-content: center;
+ width: 15px;
+ height: 15px;
+ padding: 0;
+ border: 0;
+ background-color: transparent;
+ cursor: pointer;
+
+ fa-icon {
+ font-size: $font-size-2xs;
+ }
+
+ :focus-visible {
+ outline: 2px solid transparent;
+ outline-offset: 1px;
+ }
+ }
+}
+
.app-foot-menu {
@extend .no-select;
display: flex;
diff --git a/frontend/src/styles/components/_modal.scss b/frontend/src/styles/components/_modal.scss
index c0d04998..224050d0 100644
--- a/frontend/src/styles/components/_modal.scss
+++ b/frontend/src/styles/components/_modal.scss
@@ -28,7 +28,7 @@
.modal-body {
font-size: $font-size-xs;
- padding: 8px 12px;
+ padding: 10px;
}
tabset {
@@ -37,10 +37,9 @@
display: grid;
grid-auto-flow: column;
grid-auto-columns: minmax(0, 1fr);
- gap: $nav-link-padding-y;
- padding: $nav-link-padding-y;
- margin: 0 0 .6rem;
- border-radius: $nav-tabs-border-radius;
+ gap: 0.5rem;
+ padding: 0 0.3rem 0.6rem 0;
+ margin: 0 0 .8rem;
> li {
min-width: 0;
diff --git a/frontend/src/styles/components/_theme_dark.scss b/frontend/src/styles/components/_theme_dark.scss
index 061d4530..e5ec4e70 100755
--- a/frontend/src/styles/components/_theme_dark.scss
+++ b/frontend/src/styles/components/_theme_dark.scss
@@ -196,8 +196,8 @@
tabset {
> .nav.nav-pills,
> ul.nav.nav-pills {
- border: 1px solid $dark-dialog-tabs-bar-border-color;
- background: $dark-dialog-tabs-bar-bg;
+ border-bottom: 1px solid $dark-dialog-tabs-bar-border-color;
+ background: transparent;
.nav-link {
background: $dark-dialog-tab-bg;
@@ -286,6 +286,53 @@
.btn-minimize {
background: transparent url("#{$theme-btn-minimize-icon-svg}") center/1em auto no-repeat;
}
+ app-input-filter {
+ .filter-shell {
+ border-color: $dark-surface-border;
+ background-color: $dark-surface-bg;
+ box-shadow: inset 0 1px 1px rgba($black, 0.24);
+
+ &:hover {
+ border-color: mix($primary, $sidebar-dark-icons-menu-border-color, 34%);
+ }
+
+ &:focus-within {
+ border-color: $primary;
+ box-shadow:
+ 0 0 0 2px $dark-btn-focus-color,
+ inset 0 1px 1px rgba($black, 0.2);
+ }
+
+ &.has-value {
+ border-color: mix($primary, $dark-surface-border, 62%);
+ }
+
+ input {
+ color: $dark-item-hover-color;
+ caret-color: lighten($primary, 12%);
+
+ &::placeholder {
+ color: $dark-item-disabled-color;
+ }
+ }
+ }
+
+ .filter-icon {
+ color: $dark-item-color;
+ }
+
+ .clear-btn {
+ color: $dark-item-color;
+
+ &:hover {
+ color: $dark-item-hover-color;
+ }
+
+ &:focus-visible {
+ outline-color: $dark-btn-focus-color;
+ }
+ }
+ }
.dropdown-menu {
border: .5px solid $dark-surface-border !important;
background-color: $dark-surface-bg !important;
diff --git a/frontend/src/styles/components/_theme_light.scss b/frontend/src/styles/components/_theme_light.scss
index 1dd3e91d..2a0a59a0 100755
--- a/frontend/src/styles/components/_theme_light.scss
+++ b/frontend/src/styles/components/_theme_light.scss
@@ -218,8 +218,8 @@
tabset {
> .nav.nav-pills,
> ul.nav.nav-pills {
- border: 1px solid $light-dialog-tabs-bar-border-color;
- background: $light-dialog-tab-card-bg;
+ border-bottom: 1px solid $light-dialog-tabs-bar-border-color;
+ background: transparent;
.nav-link {
background: $light-dialog-tab-bg;
@@ -305,9 +305,51 @@
.btn-minimize {
background: transparent url("#{$theme-btn-minimize-icon-svg}") center/1em auto no-repeat;
}
+ app-input-filter {
+ .filter-shell {
+ border-color: $light-surface-border;
+ background-color: $light-surface-bg;
+ box-shadow: inset 0 1px 1px rgba($custom-dark-color, 0.12);
+
+ &:hover {
+ border-color: mix($primary, $gray-light, 26%);
+ }
+
+ &:focus-within {
+ border-color: $primary;
+ }
+
+ &.has-value {
+ border-color: mix($primary, $light-surface-border, 48%);
+ }
+
+ input {
+ color: $light-item-color;
+ caret-color: $primary;
+
+ &::placeholder {
+ color: $placeholder-color;
+ }
+ }
+ }
+
+ .filter-icon {
+ color: mix($primary, $light-item-color, 52%);
+ }
+
+ .clear-btn {
+ &:hover {
+ color: $light-item-hover-color;
+ }
+
+ &:focus-visible {
+ outline-color: $light-btn-focus-color;
+ }
+ }
+ }
.dropdown-menu {
border: .5px solid $light-menu-surface-border !important;
- background-color: $light-menu-surface-bg !important;
+ background-color: $gray-lightest !important;
box-shadow: $light-menu-surface-shadow;
> li > a {
@@ -385,7 +427,7 @@
background: linear-gradient(to right, $light-app-top-menu-gradient-start 0%, $light-app-top-menu-gradient-mid 50%, $light-app-top-menu-gradient-end 100%);
.dropdown-menu {
- background-color: $light-menu-surface-bg !important;
+ background-color: $gray-lightest !important;
}
}
.app-foot-menu {
@@ -454,7 +496,7 @@
color: $custom-color;
}
.profile-page {
- background-color: $body-bg;
+ background-color: $gray-lightest;
.box {
background-color: $gray-lighter;
@@ -482,7 +524,7 @@
}
}
.app-small-card {
- background-color: $gray-lighter;
+ background-color: $light-sidebar-mini-bg;
}
.wizard {
background-color: lighten($primary, 50%);
@@ -523,7 +565,7 @@
// border-left: .5px solid $sidebar-light-apps-menu-border-color;
//}
.ngx-contextmenu {
- background-color: $light-menu-surface-bg !important;
+ background-color: $gray-lightest !important;
border-color: $light-menu-surface-border !important;
box-shadow: $light-menu-surface-shadow !important;
@@ -552,7 +594,7 @@
typeahead-container,
.ui-select-choices {
&.dropdown-menu {
- background-color: $white !important;
+ background-color: $gray-lightest !important;
}
}
.form-control,
@@ -624,11 +666,14 @@
}
}
.bg-theme {
- background-color: $light-bg-theme;
+ background-color: darken($gray-lighter, 4%);
}
.bg-theme-alt {
background-color: $gray-lightest !important;
}
+ .text-bg-light {
+ background-color: $white !important;
+ }
.recents-grid .box-transparent > .box-header {
background: $light-recents-box-header-bg;
border-bottom-color: mix($primary, $white, 20%);
diff --git a/frontend/src/styles/components/_variables.scss b/frontend/src/styles/components/_variables.scss
index 9f88634b..44ae9faf 100644
--- a/frontend/src/styles/components/_variables.scss
+++ b/frontend/src/styles/components/_variables.scss
@@ -106,7 +106,6 @@ $dark-text-primary-color: #6ab8f0;
$dark-text-muted-color: #b6bcc2;
//Light theme
-$light-bg-theme: #c8d6ea;
$light-sidebar-mini-bg: #ebeef5;
$light-sidebar-mini-hover-bg: lighten(#d4e1f1, 2%);
$light-sidebar-mini-active-bg: darken(#d4e1f1, 4%);
@@ -140,7 +139,7 @@ $light-chat-button-hover-color: $black;
$light-dialog-tab-card-bg: rgba(255, 255, 255, 0.52);
$light-dialog-tab-card-border-color: rgba(20, 45, 72, 0.11);
$light-dialog-tab-card-shadow-color: rgba(31, 56, 86, 0.1);
-$light-dialog-check-card-bg: rgba(236, 243, 251, 0.72);
+$light-dialog-check-card-bg: $light-dialog-tab-card-bg;
$light-dialog-check-card-border-color: rgba(30, 59, 89, 0.14);
$light-dialog-check-card-hover-bg: rgba(236, 243, 251, 0.88);
$light-dialog-check-card-hover-border-color: rgba(52, 94, 146, 0.48);
@@ -148,8 +147,8 @@ $light-dialog-check-card-hover-shadow-color: rgba(31, 56, 86, 0.12);
$light-dialog-check-card-active-border-color: rgba(30, 59, 89, 0.3);
$light-dialog-tabs-bar-bg: mix($light-dialog-tab-card-bg, #eaf2fc, 74%);
$light-dialog-tabs-bar-border-color: rgba(51, 84, 121, 0.24);
-$light-dialog-tab-bg: #b8cbe4;
-$light-dialog-tab-color: #2f3e4e;
+$light-dialog-tab-bg: #b5c8e3;
+$light-dialog-tab-color: $black;
$light-dialog-tab-hover-bg: mix($primary, $light-dialog-tab-bg, 30%);
$light-dialog-tab-hover-border-color: mix($primary, $light-dialog-tab-bg, 52%);
$light-dialog-tab-hover-color: $light-dialog-tab-color;