File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -133,6 +133,13 @@ async function stateAttributes(element) {
133133 if ( element . hasAttribute ( "state_to" ) ) elements . push ( element ) ;
134134 let nestedElements = element . querySelectorAll ( "[state_to]" ) ;
135135 elements . push ( ...nestedElements ) ;
136+ let current = element ;
137+ while ( current ) {
138+ if ( current . hasAttribute ( "state_to" ) && ! elements . includes ( current ) ) {
139+ elements . push ( current ) ;
140+ }
141+ current = current . parentElement ;
142+ }
136143 // }
137144
138145 let changeState = false ;
@@ -187,7 +194,7 @@ async function _getAttributeValues(element) {
187194 } ) ;
188195 else if ( attribute . name == "state-value" && ! attribute . value )
189196 Object . assign ( attributeValues , {
190- value : await element . getvalue ( )
197+ value : await element . getValue ( )
191198 } ) ;
192199 else
193200 Object . assign ( attributeValues , {
@@ -200,7 +207,7 @@ async function _getAttributeValues(element) {
200207 ! element . hasAttribute ( "state-value" ) &&
201208 element . getvalue
202209 )
203- Object . assign ( attributeValues , { value : await element . getvalue ( ) } ) ;
210+ Object . assign ( attributeValues , { value : await element . getValue ( ) } ) ;
204211
205212 return attributeValues ;
206213}
You can’t perform that action at this time.
0 commit comments