Skip to content

Commit 0960101

Browse files
authored
fix: accept any string in <iframe> name attribute (#5349)
Fixes https://discord.com/channels/955905230107738152/1400906922235920445/1400906922235920445 The spec does not clearly indicate possible values and in case of iframe and object name attribute accepts any string.
1 parent c2bf7d4 commit 0960101

File tree

3 files changed

+7
-15
lines changed

3 files changed

+7
-15
lines changed

packages/html-data/bin/attributes.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ for (const row of rows) {
163163
.split(/\s*;\s*/)
164164
.filter((item) => item.startsWith('"') && item.endsWith('"'))
165165
.map((item) => item.slice(1, -1));
166-
if (value.includes("valid navigable target name or keyword")) {
166+
if (attribute === "target" || attribute === "formtarget") {
167167
possibleOptions = ["_blank", "_self", "_parent", "_top"];
168168
}
169169
if (value.includes("input type keyword")) {

packages/html-data/src/__generated__/attributes-jsx-test.tsx

Lines changed: 2 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/html-data/src/__generated__/attributes.ts

Lines changed: 4 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)