@fulate/ui 1.0.7 → 1.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +3 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -3180,6 +3180,7 @@ var Text = class extends Rectangle {
|
|
|
3180
3180
|
const style = this.getResolvedTextStyle();
|
|
3181
3181
|
const layoutWidth = this.getLayoutWidth();
|
|
3182
3182
|
const resolvedHeight = this.getResolvedHeight();
|
|
3183
|
+
const previousLayout = this.textBlock.layout;
|
|
3183
3184
|
const layout = this.textBlock.sync({
|
|
3184
3185
|
text: this.text,
|
|
3185
3186
|
style,
|
|
@@ -3190,6 +3191,7 @@ var Text = class extends Rectangle {
|
|
|
3190
3191
|
});
|
|
3191
3192
|
const width = layoutWidth ?? layout.naturalWidth;
|
|
3192
3193
|
this.commitTextLayoutSize(isUndefined(this.propertyState.width) ? width : void 0, isUndefined(this.propertyState.height) ? resolvedHeight ?? layout.textHeight : void 0);
|
|
3194
|
+
if (layout !== previousLayout) this.transform.invalidateLayoutBounds();
|
|
3193
3195
|
}
|
|
3194
3196
|
/** 布局 owner 提交 Text 自身的 intrinsic size;派生布局可覆写为只采用其 resolved frame。 */
|
|
3195
3197
|
commitTextLayoutSize(width, height) {
|
|
@@ -3826,7 +3828,7 @@ var GroupTransform = class extends ElementTransform {
|
|
|
3826
3828
|
this.invalidateContentBounds();
|
|
3827
3829
|
}
|
|
3828
3830
|
onDescendantDirty(_child, affectsContentBounds) {
|
|
3829
|
-
if (affectsContentBounds) this.invalidateContentBounds();
|
|
3831
|
+
if (affectsContentBounds && (this.localContentBounds !== void 0 || this.localSelectionFrameBounds !== void 0)) this.invalidateContentBounds();
|
|
3830
3832
|
}
|
|
3831
3833
|
invalidateContentBounds() {
|
|
3832
3834
|
this.invalidate(ChangeImpact.VisualBounds | ChangeImpact.HitBounds);
|