@semantic-ui/templating
Advanced tools
Comparing version 0.0.34 to 0.0.35
@@ -8,9 +8,9 @@ { | ||
"dependencies": { | ||
"@semantic-ui/component": "^0.0.34", | ||
"@semantic-ui/query": "^0.0.34", | ||
"@semantic-ui/reactivity": "^0.0.34", | ||
"@semantic-ui/templating": "^0.0.34", | ||
"@semantic-ui/utils": "^0.0.34" | ||
"@semantic-ui/component": "^0.0.35", | ||
"@semantic-ui/query": "^0.0.35", | ||
"@semantic-ui/reactivity": "^0.0.35", | ||
"@semantic-ui/templating": "^0.0.35", | ||
"@semantic-ui/utils": "^0.0.35" | ||
}, | ||
"version": "0.0.34" | ||
"version": "0.0.35" | ||
} |
@@ -308,3 +308,3 @@ import { each, isString, last } from '@semantic-ui/utils'; | ||
} | ||
else if (!Number.isNaN(parseFloat(expression, 10))) { | ||
else if (!Number.isNaN(parseFloat(expression))) { | ||
return +expression; | ||
@@ -311,0 +311,0 @@ } |
@@ -33,2 +33,3 @@ import { $ } from '@semantic-ui/query'; | ||
onRendered = noop, | ||
onUpdated = noop, | ||
onDestroyed = noop, | ||
@@ -145,2 +146,6 @@ onThemeChanged = noop, | ||
}; | ||
this.onUpdated = () => { | ||
this.call(this.onRenderedCallback); | ||
this.dispatchEvent('updated', { tpl: this.tpl }, {}, { triggerCallback: false }); | ||
}; | ||
this.onThemeChanged = (...args) => { | ||
@@ -347,4 +352,4 @@ this.call(this.onThemeChangedCallback, ...args); | ||
selector, | ||
(event) => { | ||
if (!this.isNodeInTemplate(event.target)) { | ||
function(event) { | ||
if (!template.isNodeInTemplate(event.target)) { | ||
return; | ||
@@ -357,10 +362,7 @@ } | ||
} | ||
const targetElement = (selector) | ||
? $(event.target).closest(selector).get(0) // delegation | ||
: event.target | ||
; | ||
const targetElement = this; | ||
const boundEvent = eventHandler.bind(targetElement); | ||
const eventData = event?.detail || {}; | ||
const elData = targetElement.dataset; | ||
const elValue = targetElement.value; | ||
const elData = targetElement?.dataset; | ||
const elValue = targetElement?.value; | ||
template.call(boundEvent, { | ||
@@ -509,2 +511,3 @@ additionalData: { | ||
this.rendered = true; | ||
setTimeout(this.onUpdated, 0); | ||
return this.html; | ||
@@ -558,2 +561,3 @@ } | ||
afterFlush: Reaction.afterFlush, | ||
flush: Reaction.flush, | ||
@@ -560,0 +564,0 @@ data: this.data, |
81379
2332
+ Added@semantic-ui/component@0.0.35(transitive)
+ Added@semantic-ui/query@0.0.35(transitive)
+ Added@semantic-ui/reactivity@0.0.35(transitive)
+ Added@semantic-ui/utils@0.0.35(transitive)
- Removed@semantic-ui/component@0.0.34(transitive)
- Removed@semantic-ui/query@0.0.34(transitive)
- Removed@semantic-ui/reactivity@0.0.34(transitive)
- Removed@semantic-ui/utils@0.0.34(transitive)
Updated@semantic-ui/query@^0.0.35
Updated@semantic-ui/utils@^0.0.35