mirror of
https://github.com/openclaw/openclaw.git
synced 2026-04-19 09:38:39 +00:00
fix: widen external link rel token set type
This commit is contained in:
@@ -4,7 +4,7 @@ export const EXTERNAL_LINK_TARGET = "_blank";
|
|||||||
|
|
||||||
export function buildExternalLinkRel(currentRel?: string): string {
|
export function buildExternalLinkRel(currentRel?: string): string {
|
||||||
const extraTokens: string[] = [];
|
const extraTokens: string[] = [];
|
||||||
const seen = new Set(REQUIRED_EXTERNAL_REL_TOKENS);
|
const seen = new Set<string>(REQUIRED_EXTERNAL_REL_TOKENS);
|
||||||
|
|
||||||
for (const rawToken of (currentRel ?? "").split(/\s+/)) {
|
for (const rawToken of (currentRel ?? "").split(/\s+/)) {
|
||||||
const token = rawToken.trim().toLowerCase();
|
const token = rawToken.trim().toLowerCase();
|
||||||
|
|||||||
Reference in New Issue
Block a user