Skip to content

Commit

Permalink
fix: remove color tags only
Browse files Browse the repository at this point in the history
  • Loading branch information
brenoepics committed Sep 26, 2024
1 parent 93da642 commit b3bb6de
Showing 1 changed file with 14 additions and 12 deletions.
26 changes: 14 additions & 12 deletions src/utils/constants.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
export const LOW_HEALTH_THRESHOLD: number = 75;
export const MEDIUM_HEALTH_THRESHOLD: number = 85;
export const OK_HEALTH_THRESHOLD: number = 95;
export const tagsRemover: (str: string) => string = (str: string) => str.replace(/<bg_err>/g, "")
.replace(/<bg_warn>/g, "")
.replace(/<bg_info>/g, "")
.replace(/<bg_ok>/g, "")
.replace(/<\/bg_err>/g, "")
.replace(/<\/bg_warn>/g, "")
.replace(/<\/bg_info>/g, "")
.replace(/<\/bg_ok>/g, "")
.replace(/<text_warn>/g, "")
.replace(/<text_info>/g, "")
.replace(/<\/text_warn>/g, "")
.replace(/<\/text_info>/g, "");
export const tagsRemover: (str: string) => string = (str: string) =>
str
.replace(/<bg_err>/g, "")
.replace(/<bg_warn>/g, "")
.replace(/<bg_info>/g, "")
.replace(/<bg_ok>/g, "")
.replace(/<\/bg_err>/g, "")
.replace(/<\/bg_warn>/g, "")
.replace(/<\/bg_info>/g, "")
.replace(/<\/bg_ok>/g, "")
.replace(/<text_warn>/g, "")
.replace(/<text_info>/g, "")
.replace(/<\/text_warn>/g, "")
.replace(/<\/text_info>/g, "");

0 comments on commit b3bb6de

Please sign in to comment.