mirror of
https://github.com/goauthentik/authentik
synced 2026-05-11 01:22:25 +02:00
* web: Separate global styles from element roots. * web: Flesh out style strategy plugin, fixes for imported styles. * web: Clean up applying of dark theme. web: unminify. * web: Fix alignment, rendering on high contrast. web: Apply footer resize. web: Fix application of global styles in style roots. web: Fix missing layout attribute. web: Normalize background alignment. web: Fix layout issues, color overrides. web: Fix alignment, colors, jank. web: Separate method into function. web: Clean up alignment, reflow. web: Fix colors, compatibility mode. web: Add content left/right support. web: Fix colors, compatibility mode overrides. * Fix issue where missing config throws runtime error. * web: Refactor. * Update tests. * web: Fix Storybook imports. * Fix order of theme application. * web: Fix storybook asset paths. * web: Flesh out tests surrounding source buttons, fix alignment, contrast. * Update tests, clarify errors. * Update test selectors, assertions. * Clarify redirect handling. * Adjust user check. * Update logs. * web: Fix selector timing. * Fix alignment. * Fix selectors, timing. * Log current URL content. * Refine shadow selector, add delay. * Replace IDs with named elements. * Fix overlay color. * Fix footer padding. * Fix contrast. * Add selectable name to button. * Fix alignment, mobile layout. * web: Spread exported parts to stages. * Fix z-index order. * Tidy colors, behaviors, layout. * Fix overflow scroll. * Clean up duplicate color styles. * Clarify selector order. Fix overrides, color contrast. * Attempt to read JSON multiple times. * Clarify error. * web: Fix timeouts, URL changes. * web: Fix disabled styles. * Fix color flip. * Fix selector. * Fix issue where hidden tables will alter test URLs. * Use DOM to look for connection, rather than API. Update selectors. * Immediately navigate to tab. * Upgrade Dex. * Ensure Dex redirects. * Use same host during tests. * web: Update package-lock.json * Add delay.
100 lines
2.8 KiB
JavaScript
100 lines
2.8 KiB
JavaScript
/**
|
|
* @file Paths used by the web package.
|
|
*
|
|
* @runtime node
|
|
*/
|
|
|
|
import { dirname, resolve } from "node:path";
|
|
import { fileURLToPath } from "node:url";
|
|
|
|
import { DistDirectoryName } from "#paths";
|
|
|
|
import { resolvePackage } from "@goauthentik/core/paths/node";
|
|
|
|
const relativeDirname = dirname(fileURLToPath(import.meta.url));
|
|
|
|
//#region Base paths
|
|
|
|
/**
|
|
* @typedef {'@goauthentik/web'} WebPackageIdentifier
|
|
*/
|
|
|
|
/**
|
|
* The root of the web package.
|
|
*
|
|
* @runtime node
|
|
*/
|
|
export const PackageRoot = /** @type {WebPackageIdentifier} */ (resolve(relativeDirname, ".."));
|
|
|
|
/**
|
|
* Path to the web package's distribution directory.
|
|
*
|
|
* This is where the built files are located after running the build process.
|
|
*
|
|
* @runtime node
|
|
*/
|
|
export const DistDirectory = /** @type {`${WebPackageIdentifier}/${DistDirectoryName}`} */ (
|
|
resolve(PackageRoot, DistDirectoryName)
|
|
);
|
|
|
|
//#endregion
|
|
|
|
//#region Entry points
|
|
|
|
/**
|
|
* @typedef {{ in: string, out: string }} EntryPointTarget
|
|
*
|
|
* ESBuild entrypoint target.
|
|
* Matches the type defined in the ESBuild context.
|
|
*/
|
|
|
|
const patternflyPath = resolvePackage("@patternfly/patternfly", import.meta);
|
|
|
|
/**
|
|
* Entry points available for building.
|
|
*
|
|
* @satisfies {Record<string, EntryPointTarget>}
|
|
*
|
|
* @runtime node
|
|
*/
|
|
export const EntryPoint = /** @type {const} */ ({
|
|
Admin: {
|
|
in: resolve(PackageRoot, "src", "admin", "AdminInterface", "index.entrypoint.ts"),
|
|
out: resolve(DistDirectory, "admin", "AdminInterface"),
|
|
},
|
|
User: {
|
|
in: resolve(PackageRoot, "src", "user", "index.entrypoint.ts"),
|
|
out: resolve(DistDirectory, "user", "UserInterface"),
|
|
},
|
|
Flow: {
|
|
in: resolve(PackageRoot, "src", "flow", "index.entrypoint.ts"),
|
|
out: resolve(DistDirectory, "flow", "FlowInterface"),
|
|
},
|
|
StandaloneAPI: {
|
|
in: resolve(PackageRoot, "src", "standalone", "api-browser/index.entrypoint.ts"),
|
|
out: resolve(DistDirectory, "standalone", "api-browser", "index"),
|
|
},
|
|
StandaloneLoading: {
|
|
in: resolve(PackageRoot, "src", "standalone", "loading/index.entrypoint.ts"),
|
|
out: resolve(DistDirectory, "standalone", "loading", "index"),
|
|
},
|
|
RAC: {
|
|
in: resolve(PackageRoot, "src", "rac", "index.entrypoint.ts"),
|
|
out: resolve(DistDirectory, "rac", "index"),
|
|
},
|
|
Polyfill: {
|
|
in: resolve(PackageRoot, "src", "polyfill", "index.entrypoint.ts"),
|
|
out: resolve(DistDirectory, "poly"),
|
|
},
|
|
InterfaceStyles: {
|
|
in: resolve(PackageRoot, "src", "styles", "authentik", "interface.global.css"),
|
|
out: resolve(DistDirectory, "styles", "interface"),
|
|
},
|
|
StaticStyles: {
|
|
in: resolve(PackageRoot, "src", "styles", "authentik", "static.global.css"),
|
|
out: resolve(DistDirectory, "styles", "static"),
|
|
},
|
|
});
|
|
|
|
//#endregion
|