File tree 2 files changed +4
-5
lines changed
2 files changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -37,12 +37,11 @@ pub fn file_collect_css_variables(file: &figma_schema::File) -> CSSVariablesMap
37
37
pub fn find_figma_node_by_id < ' a > (
38
38
file : & ' a figma_schema:: File ,
39
39
node_id : & str ,
40
- ) -> Option < & ' a figma_schema:: Node > {
41
- let ( node , _ ) = file
40
+ ) -> Option < ( & ' a figma_schema:: Node , Vec < & ' a Node > ) > {
41
+ file
42
42
. document
43
43
. depth_first_stack_iter ( )
44
- . find ( |( n, _) | n. id == node_id) ?;
45
- Some ( node)
44
+ . find ( |( n, _) | n. id == node_id)
46
45
}
47
46
48
47
pub fn figma_node_to_intermediate_node < ' a > (
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ pub fn main(
12
12
_stderr : & mut impl Write ,
13
13
node_id : & str ,
14
14
) -> Result < ( ) > {
15
- let body = find_figma_node_by_id ( file, node_id)
15
+ let ( body, _ ) = find_figma_node_by_id ( file, node_id)
16
16
. with_context ( || format ! ( "Failed to find node with id {}" , node_id) ) ?;
17
17
18
18
let mut css_variables = file_collect_css_variables ( file) ;
You can’t perform that action at this time.
0 commit comments