Update Bootstrap to 5.3.0-alpha3
This commit is contained in:
6
paige/node_modules/bootstrap/js/src/util/sanitizer.js
generated
vendored
6
paige/node_modules/bootstrap/js/src/util/sanitizer.js
generated
vendored
@@ -16,8 +16,6 @@ const uriAttributes = new Set([
|
||||
'xlink:href'
|
||||
])
|
||||
|
||||
const ARIA_ATTRIBUTE_PATTERN = /^aria-[\w-]*$/i
|
||||
|
||||
/**
|
||||
* A pattern that recognizes a commonly useful subset of URLs that are safe.
|
||||
*
|
||||
@@ -48,6 +46,9 @@ const allowedAttribute = (attribute, allowedAttributeList) => {
|
||||
.some(regex => regex.test(attributeName))
|
||||
}
|
||||
|
||||
// js-docs-start allow-list
|
||||
const ARIA_ATTRIBUTE_PATTERN = /^aria-[\w-]*$/i
|
||||
|
||||
export const DefaultAllowlist = {
|
||||
// Global attributes allowed on any supplied element below.
|
||||
'*': ['class', 'dir', 'id', 'lang', 'role', ARIA_ATTRIBUTE_PATTERN],
|
||||
@@ -81,6 +82,7 @@ export const DefaultAllowlist = {
|
||||
u: [],
|
||||
ul: []
|
||||
}
|
||||
// js-docs-end allow-list
|
||||
|
||||
export function sanitizeHtml(unsafeHtml, allowList, sanitizeFunction) {
|
||||
if (!unsafeHtml.length) {
|
||||
|
Reference in New Issue
Block a user