diff --git a/web/src/common/styles/authentik.css b/web/src/common/styles/authentik.css
index 9125943371..e696e6f80f 100644
--- a/web/src/common/styles/authentik.css
+++ b/web/src/common/styles/authentik.css
@@ -9,6 +9,9 @@
--ak-dark-background-light: #1c1e21;
--ak-dark-background-light-ish: #212427;
--ak-dark-background-lighter: #2b2e33;
+
+ /* PatternFly likes to override global variables for some reason */
+ --ak-global--Color--100: var(--pf-global--Color--100);
}
::-webkit-scrollbar {
diff --git a/web/src/common/styles/theme-dark.css b/web/src/common/styles/theme-dark.css
index 9e52b715c4..52501ab86c 100644
--- a/web/src/common/styles/theme-dark.css
+++ b/web/src/common/styles/theme-dark.css
@@ -1,11 +1,12 @@
-body {
- background-color: var(--ak-dark-background) !important;
-}
:root {
--pf-global--Color--100: var(--ak-dark-foreground) !important;
+ --ak-global--Color--100: var(--ak-dark-foreground) !important;
--pf-c-page__main-section--m-light--BackgroundColor: var(--ak-dark-background-darker);
--pf-global--link--Color: var(--ak-dark-foreground-link) !important;
}
+body {
+ background-color: var(--ak-dark-background) !important;
+}
.pf-c-radio {
--pf-c-radio__label--Color: var(--ak-dark-foreground);
}
diff --git a/web/src/user/LibraryApplication.ts b/web/src/user/LibraryApplication.ts
index c44da31f03..eff21dbb2c 100644
--- a/web/src/user/LibraryApplication.ts
+++ b/web/src/user/LibraryApplication.ts
@@ -1,5 +1,6 @@
import { truncateWords } from "@goauthentik/common/utils";
import { AKElement, rootInterface } from "@goauthentik/elements/Base";
+import "@goauthentik/elements/Expand";
import { UserInterface } from "@goauthentik/user/UserInterface";
import { msg } from "@lit/localize";
@@ -32,27 +33,47 @@ export class LibraryApplication extends AKElement {
PFButton,
PFAvatar,
css`
- .pf-c-card {
- height: 100%;
+ :host {
+ --icon-height: 4rem;
+ --icon-border: 0.25rem;
}
- i.pf-icon {
- height: 36px;
- display: flex;
- flex-direction: column;
- justify-content: center;
+ .pf-c-card {
+ --pf-c-card--BoxShadow: var(--pf-global--BoxShadow--md);
}
.pf-c-avatar {
--pf-c-avatar--BorderRadius: 0;
+ --pf-c-avatar--Height: calc(
+ var(--icon-height) + var(--icon-border) + var(--icon-border)
+ );
+ --pf-c-avatar--Width: calc(
+ var(--icon-height) + var(--icon-border) + var(--icon-border)
+ );
}
.pf-c-card__header {
- min-height: 60px;
justify-content: space-between;
+ flex-direction: column;
}
.pf-c-card__header a {
display: flex;
flex-direction: column;
justify-content: center;
- margin-right: 0.25em;
+ }
+ .icon {
+ font-size: var(--icon-height);
+ color: var(--ak-global--Color--100);
+ padding: var(--icon-border);
+ max-height: calc(var(--icon-height) + var(--icon-border) + var(--icon-border));
+ line-height: calc(var(--icon-height) + var(--icon-border) + var(--icon-border));
+ }
+ .expander {
+ flex-grow: 1;
+ }
+ .pf-c-card__title {
+ text-align: center;
+ /* This is not ideal as it hard limits us to 2 lines of text for the title
+ of the application. In theory that should be fine for most cases, but ideally
+ we don't do this */
+ height: 48px;
}
`,
];
@@ -62,7 +83,7 @@ export class LibraryApplication extends AKElement {
if (this.application?.metaIcon) {
if (this.application.metaIcon.startsWith("fa://")) {
const icon = this.application.metaIcon.replaceAll("fa://", "");
- return html``;
+ return html``;
}
return html``;
}
- return html``;
+ return html`${this.application?.name.charAt(0).toUpperCase()}`;
}
render(): TemplateResult {
@@ -82,7 +103,7 @@ export class LibraryApplication extends AKElement {
class="pf-c-card pf-m-hoverable pf-m-compact ${this.selected
? "pf-m-selectable pf-m-selected"
: ""}"
- style="background: ${this.background} !important"
+ style=${this.background !== "" ? `background: ${this.background} !important` : ""}
>