web: cleanup
Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
		
							
								
								
									
										1
									
								
								.github/workflows/web-api-publish.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1
									
								
								.github/workflows/web-api-publish.yml
									
									
									
									
										vendored
									
									
								
							| @ -17,6 +17,7 @@ jobs: | ||||
|       - run: make gen-web | ||||
|       - run: | | ||||
|           cd web/api/ | ||||
|           npm run build | ||||
|           npm publish | ||||
|         env: | ||||
|           NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }} | ||||
|  | ||||
							
								
								
									
										33
									
								
								web/package-lock.json
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										33
									
								
								web/package-lock.json
									
									
									
										generated
									
									
									
								
							| @ -33,7 +33,6 @@ | ||||
|                 "@typescript-eslint/eslint-plugin": "^4.29.1", | ||||
|                 "@typescript-eslint/parser": "^4.29.1", | ||||
|                 "@webcomponents/webcomponentsjs": "^2.6.0", | ||||
|                 "authentik-api": "file:api", | ||||
|                 "babel-plugin-macros": "^3.1.0", | ||||
|                 "base64-js": "^1.5.1", | ||||
|                 "chart.js": "^3.5.0", | ||||
| @ -69,23 +68,11 @@ | ||||
|         "api": { | ||||
|             "name": "authentik-api", | ||||
|             "version": "1.0.0", | ||||
|             "extraneous": true, | ||||
|             "devDependencies": { | ||||
|                 "typescript": "^3.9.5" | ||||
|             } | ||||
|         }, | ||||
|         "api/node_modules/typescript": { | ||||
|             "version": "3.9.9", | ||||
|             "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.9.tgz", | ||||
|             "integrity": "sha512-kdMjTiekY+z/ubJCATUPlRDl39vXYiMV9iyeMuEuXZh2we6zz80uovNN2WlAxmmdE/Z/YQe+EbOEXB5RHEED3w==", | ||||
|             "dev": true, | ||||
|             "bin": { | ||||
|                 "tsc": "bin/tsc", | ||||
|                 "tsserver": "bin/tsserver" | ||||
|             }, | ||||
|             "engines": { | ||||
|                 "node": ">=4.2.0" | ||||
|             } | ||||
|         }, | ||||
|         "node_modules/@apitools/openapi-parser": { | ||||
|             "version": "0.0.7", | ||||
|             "resolved": "https://registry.npmjs.org/@apitools/openapi-parser/-/openapi-parser-0.0.7.tgz", | ||||
| @ -2994,10 +2981,6 @@ | ||||
|                 "node": ">= 4.5.0" | ||||
|             } | ||||
|         }, | ||||
|         "node_modules/authentik-api": { | ||||
|             "resolved": "api", | ||||
|             "link": true | ||||
|         }, | ||||
|         "node_modules/babel-plugin-dynamic-import-node": { | ||||
|             "version": "2.3.3", | ||||
|             "resolved": "https://registry.npmjs.org/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz", | ||||
| @ -10233,20 +10216,6 @@ | ||||
|             "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz", | ||||
|             "integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==" | ||||
|         }, | ||||
|         "authentik-api": { | ||||
|             "version": "file:api", | ||||
|             "requires": { | ||||
|                 "typescript": "^3.9.5" | ||||
|             }, | ||||
|             "dependencies": { | ||||
|                 "typescript": { | ||||
|                     "version": "3.9.9", | ||||
|                     "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.9.tgz", | ||||
|                     "integrity": "sha512-kdMjTiekY+z/ubJCATUPlRDl39vXYiMV9iyeMuEuXZh2we6zz80uovNN2WlAxmmdE/Z/YQe+EbOEXB5RHEED3w==", | ||||
|                     "dev": true | ||||
|                 } | ||||
|             } | ||||
|         }, | ||||
|         "babel-plugin-dynamic-import-node": { | ||||
|             "version": "2.3.3", | ||||
|             "resolved": "https://registry.npmjs.org/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz", | ||||
|  | ||||
| @ -2,7 +2,6 @@ import resolve from "rollup-plugin-node-resolve"; | ||||
| import commonjs from "rollup-plugin-commonjs"; | ||||
| import { terser } from "rollup-plugin-terser"; | ||||
| import sourcemaps from "rollup-plugin-sourcemaps"; | ||||
| import typescript from "@rollup/plugin-typescript"; | ||||
| import cssimport from "rollup-plugin-cssimport"; | ||||
| import copy from "rollup-plugin-copy"; | ||||
| import babel from "@rollup/plugin-babel"; | ||||
| @ -47,9 +46,6 @@ const resources = [ | ||||
| const isProdBuild = process.env.NODE_ENV === "production"; | ||||
| // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types | ||||
| function manualChunks(id) { | ||||
|     if (id.endsWith("web/api/dist/index.js")) { | ||||
|         return "api"; | ||||
|     } | ||||
|     if (id.includes("locales")) { | ||||
|         const parts = id.split("/"); | ||||
|         const file = parts[parts.length - 1]; | ||||
| @ -64,31 +60,6 @@ function manualChunks(id) { | ||||
| } | ||||
|  | ||||
| export default [ | ||||
|     // Autogenerated API Client | ||||
|     { | ||||
|         input: "./api/src/index.ts", | ||||
|         output: [ | ||||
|             { | ||||
|                 format: "es", | ||||
|                 dir: "./api/dist/", | ||||
|                 sourcemap: true, | ||||
|             }, | ||||
|         ], | ||||
|         plugins: [ | ||||
|             typescript({ | ||||
|                 declaration: true, | ||||
|                 outDir: "./api/dist/", | ||||
|             }), | ||||
|             isProdBuild && terser(), | ||||
|             copy({ | ||||
|                 targets: [...resources], | ||||
|                 copyOnce: false, | ||||
|             }), | ||||
|         ].filter((p) => p), | ||||
|         watch: { | ||||
|             clearScreen: false, | ||||
|         }, | ||||
|     }, | ||||
|     // Polyfills (imported first) | ||||
|     { | ||||
|         input: "./poly.ts", | ||||
|  | ||||
| @ -1,4 +1,4 @@ | ||||
| import { Config, Configuration, CoreApi, CurrentTenant, Middleware, ResponseContext, RootApi, Tenant } from "@goauthentik/api"; | ||||
| import { Config, Configuration, CoreApi, CurrentTenant, Middleware, ResponseContext, RootApi } from "@goauthentik/api"; | ||||
| import { getCookie } from "../utils"; | ||||
| import { APIMiddleware } from "../elements/notifications/APIDrawer"; | ||||
| import { MessageMiddleware } from "../elements/messages/Middleware"; | ||||
|  | ||||
| @ -19,7 +19,7 @@ import { | ||||
|     TITLE_DEFAULT, | ||||
| } from "../constants"; | ||||
| import { DEFAULT_CONFIG, tenant } from "../api/Config"; | ||||
| import { EventsApi } from "../../api/dist"; | ||||
| import { EventsApi } from "@goauthentik/api"; | ||||
|  | ||||
| @customElement("ak-page-header") | ||||
| export class PageHeader extends LitElement { | ||||
|  | ||||
| @ -1,4 +1,10 @@ | ||||
| import { CoreApi, PoliciesApi, Policy, PolicyTestRequest, PolicyTestResult } from "@goauthentik/api"; | ||||
| import { | ||||
|     CoreApi, | ||||
|     PoliciesApi, | ||||
|     Policy, | ||||
|     PolicyTestRequest, | ||||
|     PolicyTestResult, | ||||
| } from "@goauthentik/api"; | ||||
| import { t } from "@lingui/macro"; | ||||
| import { customElement, property } from "lit-element"; | ||||
| import { html, TemplateResult } from "lit-html"; | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 Jens Langhammer
					Jens Langhammer