marko 6.0.125 → 6.0.126
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/translator/index.js +5 -5
- package/package.json +1 -1
package/dist/translator/index.js
CHANGED
|
@@ -1619,14 +1619,14 @@ function analyzeTagNameType(tag, allowDynamic) {
|
|
|
1619
1619
|
}
|
|
1620
1620
|
if (!extra.tagNameDynamic && extra.tagNameType === 1 /* CustomTag */ && !isCoreTag(tag)) {
|
|
1621
1621
|
const childFile = (0, import_babel_utils9.loadFileForTag)(tag);
|
|
1622
|
-
if (
|
|
1623
|
-
extra.tagNameType = 2 /* DynamicTag */;
|
|
1624
|
-
extra.tagNameDynamic = true;
|
|
1625
|
-
} else if (childFile.ast.program.extra.featureType === "class") {
|
|
1622
|
+
if ((0, import_babel_utils9.getTagDef)(tag)?.renderer || childFile?.ast.program.extra.featureType === "class") {
|
|
1626
1623
|
extra.tagNameType = 2 /* DynamicTag */;
|
|
1627
1624
|
extra.tagNameDynamic = true;
|
|
1628
1625
|
extra.featureType = "class";
|
|
1629
1626
|
((0, import_babel_utils9.getProgram)().node.extra ??= {}).needsCompat = true;
|
|
1627
|
+
} else if (!childFile) {
|
|
1628
|
+
extra.tagNameType = 2 /* DynamicTag */;
|
|
1629
|
+
extra.tagNameDynamic = true;
|
|
1630
1630
|
}
|
|
1631
1631
|
}
|
|
1632
1632
|
}
|
|
@@ -11889,7 +11889,7 @@ function getTagRelativePath(tag) {
|
|
|
11889
11889
|
} = tag;
|
|
11890
11890
|
let relativePath;
|
|
11891
11891
|
if (import_compiler61.types.isStringLiteral(node.name)) {
|
|
11892
|
-
const template = (0, import_babel_utils49.getTagTemplate)(tag);
|
|
11892
|
+
const template = node.extra?.featureType === "class" && (0, import_babel_utils49.getTagDef)(tag)?.renderer || (0, import_babel_utils49.getTagTemplate)(tag);
|
|
11893
11893
|
relativePath = template && (0, import_babel_utils49.resolveRelativePath)(file, template);
|
|
11894
11894
|
} else if (node.extra?.tagNameImported) {
|
|
11895
11895
|
relativePath = node.extra.tagNameImported;
|