From bf618ab790de82f321e0bed4c0a04414726effc7 Mon Sep 17 00:00:00 2001 From: Ken Sternberg Date: Fri, 5 Jan 2024 16:09:35 -0800 Subject: [PATCH] web: strengthened weak regex in import map. --- web/packages/authentik/.storybook/css-import-maps.ts | 3 ++- web/packages/authentik/scripts/build-storybook-import-maps.ts | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/web/packages/authentik/.storybook/css-import-maps.ts b/web/packages/authentik/.storybook/css-import-maps.ts index c26d48146..69bda7100 100644 --- a/web/packages/authentik/.storybook/css-import-maps.ts +++ b/web/packages/authentik/.storybook/css-import-maps.ts @@ -1,3 +1,4 @@ + // THIS IS A GENERATED FILE. DO NOT EDIT BY HAND. // // This file is generated by the build-storybook-import-maps script in the UI's base directory. @@ -76,5 +77,5 @@ export const cssImportMaps = cssImportMapsBase.reduce( ...acc, [importLine]: importLine.replace(/.css/, ".css?inline"), }), - {}, + {} ); diff --git a/web/packages/authentik/scripts/build-storybook-import-maps.ts b/web/packages/authentik/scripts/build-storybook-import-maps.ts index abf204a01..6ecf05a36 100644 --- a/web/packages/authentik/scripts/build-storybook-import-maps.ts +++ b/web/packages/authentik/scripts/build-storybook-import-maps.ts @@ -82,7 +82,7 @@ type ImportMapType = Record; export const cssImportMaps = cssImportMapsBase.reduce( (acc: ImportMapType, importLine: string) => ({ ...acc, - [importLine]: importLine.replace(/.css/, ".css?inline"), + [importLine]: importLine.replace(/\.css/, ".css?inline"), }), {} );