@@ -113,7 +113,10 @@ export class BaseCustomWebComponentNoAttachedTemplate extends HTMLElement {
113
113
if ( a . name == "@touch:contextmenu" )
114
114
addTouchFriendlyContextMenu ( node , this [ a . value ] . bind ( this ) ) ;
115
115
else {
116
- const sNm = a . name . substr ( 1 ) ;
116
+ let sNm = a . name . substr ( 1 ) ;
117
+ if ( sNm [ 0 ] === '@' ) {
118
+ sNm = sNm . replace ( / - ( [ a - z ] ) / g, ( g ) => g [ 1 ] . toUpperCase ( ) ) ;
119
+ }
117
120
let nm = sNm . replace ( / - ( [ a - z ] ) / g, ( g ) => g [ 1 ] . toUpperCase ( ) ) ;
118
121
if ( node [ nm ] instanceof TypedEvent ) {
119
122
( < TypedEvent < any > > node [ nm ] ) . on ( this [ a . value ] . bind ( this ) ) ;
@@ -222,9 +225,9 @@ export class BaseCustomWebComponentNoAttachedTemplate extends HTMLElement {
222
225
} else if ( a . name [ 0 ] === '@' ) { //todo remove events on repeat refresh
223
226
let nm ;
224
227
if ( a . name [ 1 ] === '@' )
225
- nm = a . name . substring ( 2 , a . name . length ) ;
228
+ nm = a . name . substring ( 2 , a . name . length ) . replace ( / - ( [ a - z ] ) / g , ( g ) => g [ 1 ] . toUpperCase ( ) ) ;
226
229
else
227
- nm = a . name . substring ( 1 , a . name . length ) . replace ( / - ( [ a - z ] ) / g , ( g ) => g [ 1 ] . toUpperCase ( ) ) ;
230
+ nm = a . name . substring ( 1 , a . name . length ) ;
228
231
const value = a . value . substring ( 2 , a . value . length - 2 ) . replaceAll ( '&' , '&' ) ;
229
232
if ( a . name == "@touch:contextmenu" )
230
233
addTouchFriendlyContextMenu ( node , ( e ) => this . _bindingRunEval ( value , repeatBindingItems , e , host , context ) ) ;
0 commit comments