Skip to content

Commit 89b1e8a

Browse files
committed
Simple types
1 parent 8f6b062 commit 89b1e8a

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

inputfiles/patches/css-font.kdl

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,5 @@ enum FontDisplay {
88
}
99

1010
dictionary FontFaceDescriptors {
11-
member display {
12-
type FontDisplay
13-
}
11+
member display type=FontDisplay
1412
}

src/build/patches.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -307,10 +307,9 @@ function handleDictionary(child: Node): DeepPartial<Dictionary> {
307307
*/
308308
function handleMember(c: Node): Partial<Member> {
309309
const name = string(c.values[0]);
310-
const type: Node | undefined = c.children.find((n) => n.name === "type");
311310
return {
312311
name,
313-
...(type ? handleTyped(type) : {}),
312+
...optionalMember("type", "string", c.properties?.type),
314313
...optionalMember("required", "boolean", c.properties?.required),
315314
};
316315
}

0 commit comments

Comments
 (0)