mirror of
https://github.com/odoo/owl.git
synced 2025-10-06 19:59:41 +07:00
6c8b401092
Closes #508
22 lines
892 B
Plaintext
22 lines
892 B
Plaintext
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
|
|
exports[`Link component can render simple cases 1`] = `
|
|
"function anonymous(context,extra
|
|
) {
|
|
let utils = this.constructor.utils;
|
|
let owner = context;
|
|
var h = this.h;
|
|
let _6 = utils.toObj({'router-link-active':context['isActive']});
|
|
var _7 = context['href'];
|
|
let c8 = [], p8 = {key:8,attrs:{href: _7},class:_6,on:{}};
|
|
var vn8 = h('a', p8, c8);
|
|
extra.handlers['click' + 8] = extra.handlers['click' + 8] || function (e) {const fn = context['navigate'];if (fn) { fn.call(owner, e); } else { context.navigate; }};
|
|
p8.on['click'] = extra.handlers['click' + 8];
|
|
const slot9 = this.constructor.slots[context.__owl__.slotId + '_' + 'default'];
|
|
if (slot9) {
|
|
slot9.call(this, context.__owl__.parent, Object.assign({}, extra, {parentNode: c8, vars: extra.vars, parent: owner}));
|
|
}
|
|
return vn8;
|
|
}"
|
|
`;
|