mirror of
https://github.com/konvajs/konva.git
synced 2026-01-08 18:54:40 +08:00
Merge branch 'master' of github.com:konvajs/konva
This commit is contained in:
@@ -143,10 +143,10 @@ export abstract class Node {
|
||||
|
||||
// if not cached, we need to set it using the private getter method.
|
||||
if (cache === undefined) {
|
||||
this._cache[attr] = privateGetter.call(this);
|
||||
this._cache[attr] = cache = privateGetter.call(this);
|
||||
}
|
||||
|
||||
return this._cache[attr];
|
||||
return cache;
|
||||
}
|
||||
/*
|
||||
* when the logic for a cached result depends on ancestor propagation, use this
|
||||
|
||||
@@ -159,8 +159,7 @@ export class Text extends Shape {
|
||||
}
|
||||
|
||||
if (padding) {
|
||||
context.translate(padding, 0);
|
||||
context.translate(0, alignY + padding + lineHeightPx / 2);
|
||||
context.translate(padding, alignY + padding + lineHeightPx / 2);
|
||||
} else {
|
||||
context.translate(0, alignY + lineHeightPx / 2);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user