Skip to content

Commit

Permalink
$mol_view_tree2_to_dts remove arg chars from object prop names
Browse files Browse the repository at this point in the history
  • Loading branch information
zerkalica committed Oct 19, 2023
1 parent 691b539 commit b90b44e
Show file tree
Hide file tree
Showing 11 changed files with 16 additions and 15 deletions.
3 changes: 2 additions & 1 deletion view/tree2/to/dts/dts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,10 @@ namespace $ {
obj.struct( 'indent',
obj.kids.map( field => {
if( field.type === '^' ) return null
const field_name = field.type.replace(/\?\w*$/, '')
return field.struct( 'line', [
field.data('\''),
field.data( field.type ),
field.data( field_name ),
field.data('\''),
field.data( ': ' ),
... field.hack( belt ),
Expand Down
4 changes: 2 additions & 2 deletions view/tree2/to/dts/test/bidi_bind_in_dictionary.test.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ declare namespace _bidi_bind_in_dictionary {

export class Foo extends $mol_object {
event( ): ({
'click?': ReturnType< Foo["run"] >,
'click': ReturnType< Foo["run"] >,
})
run( next?: any ): any
}

}

//# sourceMappingURL=data:application/json,%7B%22version%22%3A3%2C%22sources%22%3A%5B%22%3F%22%5D%2C%22sourcesContent%22%3A%5B%22%5Cn%5Ct%5Ct%5Ct%5CtFoo%20%24mol_object%5Cn%5Ct%5Ct%5Ct%5Ct%5Ctevent%20*%5Cn%5Ct%5Ct%5Ct%5Ct%5Ct%5Ctclick%3F%20%3C%3D%3E%20run%3F%20null%5Cn%5Ct%5Ct%5Ct%22%5D%2C%22mappings%22%3A%22%3B%3BAAAA%3BAAAA%3BAAAA%2CAACI%2CiBAAI%2CoBAAJ%3BAACC%2CAAAA%2CYAAM%3BAAAA%2CAACL%2CaAAO%2CYAFT%2CGAES%2CEAAI%2CGAAJ%2CIAAP%3BAADK%3BAACM%2CAAAA%2CcAAK%2CGAAL%2CIAAK%3BAAFlB%3BAADJ%3BAAAA%3B%22%7D
//# sourceMappingURL=data:application/json,%7B%22version%22%3A3%2C%22sources%22%3A%5B%22%3F%22%5D%2C%22sourcesContent%22%3A%5B%22%5Cn%5Ct%5Ct%5Ct%5CtFoo%20%24mol_object%5Cn%5Ct%5Ct%5Ct%5Ct%5Ctevent%20*%5Cn%5Ct%5Ct%5Ct%5Ct%5Ct%5Ctclick%3F%20%3C%3D%3E%20run%3F%20null%5Cn%5Ct%5Ct%5Ct%22%5D%2C%22mappings%22%3A%22%3B%3BAAAA%3BAAAA%3BAAAA%2CAACI%2CiBAAI%2CoBAAJ%3BAACC%2CAAAA%2CYAAM%3BAAAA%2CAACL%2CYAAO%2CYAFT%2CGAES%2CEAAI%2CGAAJ%2CIAAP%3BAADK%3BAACM%2CAAAA%2CcAAK%2CGAAL%2CIAAK%3BAAFlB%3BAADJ%3BAAAA%3B%22%7D
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ declare namespace _bidi_bind_indexed_second_level {
expanded( ): boolean
}

type Bar__expanded_D1APEXB5 = $mol_type_enforce<
type Bar__expanded_UPXW21P6 = $mol_type_enforce<
ReturnType< Foo["owner"] >,
ReturnType< Bar["expanded"] >
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ declare namespace _bidi_bind_localized_in_object {

export class Foo extends $mol_object {
obj( ): ({
'loc?': ReturnType< Foo["outer"] >,
'loc': ReturnType< Foo["outer"] >,
})
outer( next?: string ): string
}

}

//# sourceMappingURL=data:application/json,%7B%22version%22%3A3%2C%22sources%22%3A%5B%22%3F%22%5D%2C%22sourcesContent%22%3A%5B%22%5Cn%5Ct%5Ct%5Ct%5CtFoo%20%24mol_object%5Cn%5Ct%5Ct%5Ct%5Ct%5Ctobj%20*%5Cn%5Ct%5Ct%5Ct%5Ct%5Ct%5Ctloc%3F%20%3C%3D%3E%20outer%3F%20%40%20%5C%5Ctest1%5Cn%5Ct%5Ct%5Ct%22%5D%2C%22mappings%22%3A%22%3B%3BAAAA%3BAAAA%3BAAAA%2CAACI%2CiBAAI%2CoBAAJ%3BAACC%2CAAAA%2CUAAI%3BAAAA%2CAACH%2CWAAK%2CYAFP%2CGAEO%2CEAAI%2CKAAJ%2CIAAL%3BAADG%3BAACM%2CAAAA%2CgBAAU%2CMAAV%2CIAAU%3BAAFrB%3BAADJ%3BAAAA%3B%22%7D
//# sourceMappingURL=data:application/json,%7B%22version%22%3A3%2C%22sources%22%3A%5B%22%3F%22%5D%2C%22sourcesContent%22%3A%5B%22%5Cn%5Ct%5Ct%5Ct%5CtFoo%20%24mol_object%5Cn%5Ct%5Ct%5Ct%5Ct%5Ctobj%20*%5Cn%5Ct%5Ct%5Ct%5Ct%5Ct%5Ctloc%3F%20%3C%3D%3E%20outer%3F%20%40%20%5C%5Ctest1%5Cn%5Ct%5Ct%5Ct%22%5D%2C%22mappings%22%3A%22%3B%3BAAAA%3BAAAA%3BAAAA%2CAACI%2CiBAAI%2CoBAAJ%3BAACC%2CAAAA%2CUAAI%3BAAAA%2CAACH%2CUAAK%2CYAFP%2CGAEO%2CEAAI%2CKAAJ%2CIAAL%3BAADG%3BAACM%2CAAAA%2CgBAAU%2CMAAV%2CIAAU%3BAAFrB%3BAADJ%3BAAAA%3B%22%7D
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
declare namespace _left_bind_in_array_and_object {

type $mol_object__rows_V83EJ9P9 = $mol_type_enforce<
type $mol_object__rows_Y0ZPGRXV = $mol_type_enforce<
ReturnType< Foo["content"] >,
ReturnType< $mol_object["rows"] >
>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
declare namespace _left_bind_second_level_index {

type $mol_object__localized_KDIAWS5L = $mol_type_enforce<
type $mol_object__localized_ECYILDJF = $mol_type_enforce<
ReturnType< Foo["some"] >,
ReturnType< $mol_object["localized"] >
>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
declare namespace _left_bind_with_separate_default_and_comment {

type $mol_object__rows_L4S07X4S = $mol_type_enforce<
type $mol_object__rows_7IN1BUGB = $mol_type_enforce<
ReturnType< Foo["content"] >,
ReturnType< $mol_object["rows"] >
>
Expand Down
2 changes: 1 addition & 1 deletion view/tree2/to/dts/test/right_bind_in_left_bind.test.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ declare namespace _right_bind_in_left_bind {
a( ): any
}

type Foo__a_UIYUO0JW = $mol_type_enforce<
type Foo__a_5ZQWI0UX = $mol_type_enforce<
ReturnType< Bar["b"] >,
ReturnType< Foo["a"] >
>
Expand Down
2 changes: 1 addition & 1 deletion view/tree2/to/dts/test/right_bind_indexed.test.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ declare namespace _right_bind_indexed {
})
}

type Foo__a_QYLYNT1E = $mol_type_enforce<
type Foo__a_9T0KZJNH = $mol_type_enforce<
ReturnType< Bar["b"] >,
ReturnType< Foo["a"] >
>
Expand Down
2 changes: 1 addition & 1 deletion view/tree2/to/dts/test/right_bind_read_only.test.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ declare namespace _right_bind_read_only {
a( id: any, next?: any ): any
}

type Foo__a_2HF0Z2KM = $mol_type_enforce<
type Foo__a_OWGUONH0 = $mol_type_enforce<
ReturnType< Bar["b"] >,
ReturnType< Foo["a"] >
>
Expand Down
6 changes: 3 additions & 3 deletions view/tree2/to/dts/test/simple_factory_props.test.d.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
declare namespace _simple_factory_props {

type $mol_object__some_ODAWC5JF = $mol_type_enforce<
type $mol_object__some_NIWV42PT = $mol_type_enforce<
boolean,
ReturnType< $mol_object["some"] >
>
type $mol_object__loc_UDO07ACF = $mol_type_enforce<
type $mol_object__loc_SAA9OV61 = $mol_type_enforce<
string,
ReturnType< $mol_object["loc"] >
>
type $mol_object__sub_XVYAJKRH = $mol_type_enforce<
type $mol_object__sub_E1IRQUFO = $mol_type_enforce<
readonly any[],
ReturnType< $mol_object["sub"] >
>
Expand Down

0 comments on commit b90b44e

Please sign in to comment.