Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
perun-web-apps
Manage
Activity
Members
Labels
Plan
Issues
1
Issue boards
Milestones
Iterations
Jira
Code
Merge requests
3
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Perun
Perun IdM
perun-web-apps
Merge requests
!1406
fix: initialize colors from instance config
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
fix: initialize colors from instance config
github/fork/bodnara/fixConfigColors
into
master
Overview
9
Commits
1
Pipelines
0
Changes
18
Merged
Jednotné přihlášení test
requested to merge
github/fork/bodnara/fixConfigColors
into
master
1 year ago
Overview
9
Commits
1
Pipelines
0
Changes
18
Expand
Created by: bodnara
all color variables are now initialized by the script
removed creation of css variables during runtime
removed unused classes in styles.scss for all apps
formated styles.scss for all apps
👍
0
👎
0
Merge request reports
Compare
master
master (base)
and
latest version
latest version
f917d86a
1 commit,
1 year ago
18 files
+
1044
−
1964
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
18
Search (e.g. *.vue) (Ctrl+P)
apps/admin-gui/src/app/core/services/common/admin-gui-config.service.ts
+
1
−
82
Options
@@ -4,7 +4,7 @@ import {
InitAuthService
,
MfaHandlerService
,
}
from
'
@perun-web-apps/perun/services
'
;
import
{
AppConfigService
,
ColorConfig
,
EntityColorConfig
}
from
'
@perun-web-apps/config
'
;
import
{
AppConfigService
}
from
'
@perun-web-apps/config
'
;
import
{
AuthzResolverService
}
from
'
@perun-web-apps/perun/openapi
'
;
import
{
MatDialog
}
from
'
@angular/material/dialog
'
;
import
{
Location
}
from
'
@angular/common
'
;
@@ -20,84 +20,6 @@ import { firstValueFrom } from 'rxjs';
providedIn
:
'
root
'
,
})
export
class
AdminGuiConfigService
{
entityColorConfigs
:
EntityColorConfig
[]
=
[
{
entity
:
'
vo
'
,
configValue
:
'
vo_color
'
,
cssVariable
:
'
--vo-color
'
,
},
{
entity
:
'
group
'
,
configValue
:
'
group_color
'
,
cssVariable
:
'
--group-color
'
,
},
{
entity
:
'
user
'
,
configValue
:
'
user_color
'
,
cssVariable
:
'
--user-color
'
,
},
{
entity
:
'
member
'
,
configValue
:
'
member_color
'
,
cssVariable
:
'
--member-color
'
,
},
{
entity
:
'
facility
'
,
configValue
:
'
facility_color
'
,
cssVariable
:
'
--facility-color
'
,
},
{
entity
:
'
resource
'
,
configValue
:
'
resource_color
'
,
cssVariable
:
'
--resource-color
'
,
},
{
entity
:
'
admin
'
,
configValue
:
'
admin_color
'
,
cssVariable
:
'
--admin-color
'
,
},
{
entity
:
'
service
'
,
configValue
:
'
service_color
'
,
cssVariable
:
'
--service-color
'
,
},
];
colorConfigs
:
ColorConfig
[]
=
[
{
configValue
:
'
sidemenu_hover_color
'
,
cssVariable
:
'
--side-root-item-hover
'
,
},
{
configValue
:
'
sidemenu_active_color
'
,
cssVariable
:
'
--side-root-item-active
'
,
},
{
configValue
:
'
sidemenu_submenu_active_color
'
,
cssVariable
:
'
--side-link-active
'
,
},
{
configValue
:
'
sidemenu_submenu_hover_color
'
,
cssVariable
:
'
--side-link-hover
'
,
},
{
configValue
:
'
sidemenu_hover_text_color
'
,
cssVariable
:
'
--side-root-item-text-hover
'
,
},
{
configValue
:
'
sidemenu_active_text_color
'
,
cssVariable
:
'
--side-root-item-text-active
'
,
},
{
configValue
:
'
sidemenu_submenu_active_text_color
'
,
cssVariable
:
'
--side-link-text-active
'
,
},
{
configValue
:
'
sidemenu_submenu_hover_text_color
'
,
cssVariable
:
'
--side-link-text-hover
'
,
},
];
constructor
(
private
initAuthService
:
InitAuthService
,
private
appConfigService
:
AppConfigService
,
@@ -113,9 +35,6 @@ export class AdminGuiConfigService {
.
loadAppDefaultConfig
()
.
then
(()
=>
this
.
appConfigService
.
loadAppInstanceConfig
())
.
then
(()
=>
this
.
appConfigService
.
setApiUrl
())
.
then
(()
=>
this
.
appConfigService
.
initializeColors
(
this
.
entityColorConfigs
,
this
.
colorConfigs
)
)
.
then
(()
=>
this
.
appConfigService
.
setInstanceFavicon
())
.
then
(()
=>
this
.
initAuthService
.
verifyAuth
())
.
catch
((
err
)
=>
{
Loading