sveld 0.14.0 → 0.14.1
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/CHANGELOG.md
CHANGED
|
@@ -10,6 +10,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
10
10
|
- add isAccessor field to API
|
|
11
11
|
- update Markdown writer to generate a separate table for accessors -->
|
|
12
12
|
|
|
13
|
+
## [0.14.1](https://github.com/carbon-design-system/sveld/releases/tag/v0.14.1) - 2022-04-09
|
|
14
|
+
|
|
15
|
+
- svg `$$restProps` should extend the correct attributes
|
|
16
|
+
|
|
13
17
|
## [0.14.0](https://github.com/carbon-design-system/sveld/releases/tag/v0.14.0) - 2022-04-09
|
|
14
18
|
|
|
15
19
|
- add `sveltekit:prefetch`, `sveltekit:noscroll` attributes to props that extend `a` attributes
|
|
@@ -123,7 +123,13 @@ function genPropDef(def) {
|
|
|
123
123
|
if (((_c = def.rest_props) === null || _c === void 0 ? void 0 : _c.type) === "Element") {
|
|
124
124
|
var extend_tag_map = def.rest_props.name
|
|
125
125
|
.split("|")
|
|
126
|
-
.map(function (name) {
|
|
126
|
+
.map(function (name) {
|
|
127
|
+
var element = name.trim();
|
|
128
|
+
if (element === "svg") {
|
|
129
|
+
return "svelte.JSX.SVGAttributes<SVGSVGElement>";
|
|
130
|
+
}
|
|
131
|
+
return "svelte.JSX.HTMLAttributes<HTMLElementTagNameMap[\"".concat(element, "\"]>");
|
|
132
|
+
})
|
|
127
133
|
.join(",");
|
|
128
134
|
prop_def = "\n export interface ".concat(props_name, " extends ").concat(def["extends"] !== undefined ? "".concat(def["extends"].interface, ", ") : "").concat(extend_tag_map, " {\n ").concat(props, "\n }\n ");
|
|
129
135
|
}
|