@pandacss/parser
Advanced tools
Comparing version 0.0.0-dev-20221128124624 to 0.0.0-dev-20221128130912
@@ -211,13 +211,16 @@ "use strict"; | ||
const tag = node.getTagNameNode().getText(); | ||
if (!matchProp.tag(tag)) | ||
if (!tag || !matchProp.tag(tag)) { | ||
continue; | ||
} | ||
const props = node.getAttributes(); | ||
const data = {}; | ||
for (const prop of props) { | ||
if (!import_ts_morph3.Node.isJsxAttribute(prop)) | ||
if (!import_ts_morph3.Node.isJsxAttribute(prop)) { | ||
continue; | ||
} | ||
const name = prop.getName(); | ||
const value = prop.getInitializer(); | ||
if (!matchProp.prop({ tag, name })) | ||
if (!tag || !matchProp.prop({ tag, name })) { | ||
continue; | ||
} | ||
(0, import_ts_pattern2.match)(value).when(import_ts_morph3.Node.isStringLiteral, (value2) => { | ||
@@ -224,0 +227,0 @@ data[name] = value2.getLiteralValue(); |
{ | ||
"name": "@pandacss/parser", | ||
"version": "0.0.0-dev-20221128124624", | ||
"version": "0.0.0-dev-20221128130912", | ||
"description": "The static parser for panda css", | ||
@@ -16,9 +16,9 @@ "main": "dist/index.js", | ||
"ts-morph": "17.0.1", | ||
"@pandacss/logger": "0.0.0-dev-20221128124624", | ||
"@pandacss/shared": "0.0.0-dev-20221128124624", | ||
"@pandacss/is-valid-prop": "0.0.0-dev-20221128124624", | ||
"@pandacss/types": "0.0.0-dev-20221128124624" | ||
"@pandacss/logger": "0.0.0-dev-20221128130912", | ||
"@pandacss/shared": "0.0.0-dev-20221128130912", | ||
"@pandacss/is-valid-prop": "0.0.0-dev-20221128130912", | ||
"@pandacss/types": "0.0.0-dev-20221128130912" | ||
}, | ||
"devDependencies": { | ||
"@pandacss/fixture": "0.0.0-dev-20221128124624" | ||
"@pandacss/fixture": "0.0.0-dev-20221128130912" | ||
}, | ||
@@ -25,0 +25,0 @@ "files": [ |
Sorry, the diff of this file is not supported yet
24933
689
+ Added@pandacss/is-valid-prop@0.0.0-dev-20221128130912(transitive)
+ Added@pandacss/logger@0.0.0-dev-20221128130912(transitive)
+ Added@pandacss/shared@0.0.0-dev-20221128130912(transitive)
+ Added@pandacss/types@0.0.0-dev-20221128130912(transitive)
- Removed@pandacss/is-valid-prop@0.0.0-dev-20221128124624(transitive)
- Removed@pandacss/logger@0.0.0-dev-20221128124624(transitive)
- Removed@pandacss/shared@0.0.0-dev-20221128124624(transitive)
- Removed@pandacss/types@0.0.0-dev-20221128124624(transitive)