This commit is contained in:
Henry Jameson 2026-03-06 15:25:30 +02:00
commit 18a3bbbd49
15 changed files with 43 additions and 36 deletions

View file

@ -1,8 +1,8 @@
import { parseLinkHeader } from '@web3-storage/parse-link-header'
import escapeHtml from 'escape-html'
import fileTypeService from '../file_type/file_type.service.js'
import punycode from 'punycode.js'
import fileTypeService from '../file_type/file_type.service.js'
import { isStatusNotification } from '../notification_utils/notification_utils.js'
/** NOTICE! **

View file

@ -23,7 +23,9 @@ export const getAttrs = (tag, filter) => {
.replace(/\/?$/, '')
.trim()
const attrs = Array.from(
innertag.matchAll(/([a-z]+[a-z0-9-]*)(?:=((?:"(?:\\.|[^"\\])*")|(?:'(?:\\.|[^'\\])*')))?/gi),
innertag.matchAll(
/([a-z]+[a-z0-9-]*)(?:=((?:"(?:\\.|[^"\\])*")|(?:'(?:\\.|[^'\\])*')))?/gi,
),
)
.map(([, key, value]) => [key, value])
.map(([k, v]) => {