Skip to content

Commit

Permalink
chore: add frontend section to dev config (dexidp#1913)
Browse files Browse the repository at this point in the history
* chore: add frontend section to dev config

Signed-off-by: m.nabokikh <[email protected]>
  • Loading branch information
nabokihms authored Jan 12, 2021
1 parent 4f32639 commit 35da73d
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 14 deletions.
15 changes: 11 additions & 4 deletions examples/config-dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,13 @@ web:
# tlsCert: /etc/dex/tls.crt
# tlsKey: /etc/dex/tls.key

# Configuration for dex appearance
# frontend:
# issuer: dex
# logoURL: theme/logo.png
# dir: web/
# theme: light

# Configuration for telemetry
telemetry:
http: 0.0.0.0:5558
Expand All @@ -58,9 +65,9 @@ telemetry:
# from the HTTP endpoints.
# grpc:
# addr: 127.0.0.1:5557
# tlsCert: examples/grpc-client/server.crt
# tlsKey: examples/grpc-client/server.key
# tlsClientCA: examples/grpc-client/ca.crt
# tlsCert: examples/grpc-client/server.crt
# tlsKey: examples/grpc-client/server.key
# tlsClientCA: examples/grpc-client/ca.crt

# Uncomment this block to enable configuration for the expiration time durations.
# expiry:
Expand All @@ -84,7 +91,7 @@ telemetry:
# go directly to it. For connected IdPs, this redirects the browser away
# from application to upstream provider such as the Google login page
# alwaysShowLoginScreen: false
# Uncommend the passwordConnector to use a specific connector for password grants
# Uncomment the passwordConnector to use a specific connector for password grants
# passwordConnector: local

# Instead of reading from an external storage, use this list of clients.
Expand Down
5 changes: 1 addition & 4 deletions server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,9 +96,6 @@ type Config struct {
}

// WebConfig holds the server's frontend templates and asset configuration.
//
// These are currently very custom to CoreOS and it's not recommended that
// outside users attempt to customize these.
type WebConfig struct {
// A filepath to web static.
//
Expand All @@ -116,7 +113,7 @@ type WebConfig struct {
// Defaults to "dex"
Issuer string

// Defaults to "coreos"
// Defaults to "light"
Theme string

// Map of extra values passed into the templates
Expand Down
15 changes: 9 additions & 6 deletions web/themes/dark/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
}

.theme-btn-provider:hover {
background-color: #25343a;
background-color: #212731;
color: #ffffff;
}

Expand All @@ -62,18 +62,18 @@
}

.theme-btn--primary:hover {
background-color: #425f69;
background-color: #212731;
color: #e9e9e9;
}

.theme-btn--success {
background-color: #233239;
background-color: #1891bb;
color: #e9e9e9;
width: 250px;
}

.theme-btn--success:hover {
background-color: #46add0;
background-color: #1da5d4;
}

.theme-form-row {
Expand All @@ -87,8 +87,10 @@
padding: 6px 12px;
font-size: 14px;
line-height: 1.42857143;
border: 1px solid #c8d1d9;
border: 1px solid #515559;
border-radius: 4px;
color: #c8d1d9;
background-color: #0f1218;
box-shadow: inset 0 1px 1px rgb(27, 40, 46);
width: 250px;
margin: auto;
Expand All @@ -97,7 +99,8 @@
.theme-form-input:focus,
.theme-form-input:active {
outline: none;
border-color: #1b282e;
border-color: #f8f9f9;
color: #c8d1d9;
}

.theme-form-label {
Expand Down

0 comments on commit 35da73d

Please sign in to comment.