|
|
@ -72,6 +72,8 @@ export default function createBinding ( generator, node, attribute, current, loc
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} while ( fragment = fragment.parent );
|
|
|
|
} while ( fragment = fragment.parent );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
generator.expectedProperties[ prop ] = true;
|
|
|
|
|
|
|
|
|
|
|
|
const listName = current.listNames[ parts[0] ];
|
|
|
|
const listName = current.listNames[ parts[0] ];
|
|
|
|
const indexName = current.indexNames[ parts[0] ];
|
|
|
|
const indexName = current.indexNames[ parts[0] ];
|
|
|
|
|
|
|
|
|
|
|
@ -84,7 +86,8 @@ export default function createBinding ( generator, node, attribute, current, loc
|
|
|
|
|
|
|
|
|
|
|
|
component._set({ ${prop}: component.get( '${prop}' ) });
|
|
|
|
component._set({ ${prop}: component.get( '${prop}' ) });
|
|
|
|
`;
|
|
|
|
`;
|
|
|
|
} else if ( deep ) {
|
|
|
|
} else {
|
|
|
|
|
|
|
|
if ( deep ) {
|
|
|
|
setter = deindent`
|
|
|
|
setter = deindent`
|
|
|
|
var ${parts[0]} = component.get( '${parts[0]}' );
|
|
|
|
var ${parts[0]} = component.get( '${parts[0]}' );
|
|
|
|
${parts[0]}.${parts.slice( 1 ).join( '.' )} = ${value};
|
|
|
|
${parts[0]}.${parts.slice( 1 ).join( '.' )} = ${value};
|
|
|
@ -94,6 +97,9 @@ export default function createBinding ( generator, node, attribute, current, loc
|
|
|
|
setter = `component._set({ ${attribute.value}: ${value} });`;
|
|
|
|
setter = `component._set({ ${attribute.value}: ${value} });`;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
generator.expectedProperties[ parts[0] ] = true;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// special case
|
|
|
|
// special case
|
|
|
|
if ( node.name === 'select' ) {
|
|
|
|
if ( node.name === 'select' ) {
|
|
|
|
setter = `var selectedOption = ${local.name}.selectedOptions[0] || ${local.name}.options[0];\n` + setter;
|
|
|
|
setter = `var selectedOption = ${local.name}.selectedOptions[0] || ${local.name}.options[0];\n` + setter;
|
|
|
|