@leafer-ui/text 1.0.0-rc.26 → 1.0.0-rc.28

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.
Files changed (2) hide show
  1. package/package.json +4 -4
  2. package/src/TextRows.ts +3 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@leafer-ui/text",
3
- "version": "1.0.0-rc.26",
3
+ "version": "1.0.0-rc.28",
4
4
  "description": "@leafer-ui/text",
5
5
  "author": "Chao (Leafer) Wan",
6
6
  "license": "MIT",
@@ -22,10 +22,10 @@
22
22
  "leaferjs"
23
23
  ],
24
24
  "dependencies": {
25
- "@leafer/core": "1.0.0-rc.26"
25
+ "@leafer/core": "1.0.0-rc.28"
26
26
  },
27
27
  "devDependencies": {
28
- "@leafer/interface": "1.0.0-rc.26",
29
- "@leafer-ui/interface": "1.0.0-rc.26"
28
+ "@leafer/interface": "1.0.0-rc.28",
29
+ "@leafer-ui/interface": "1.0.0-rc.28"
30
30
  }
31
31
  }
package/src/TextRows.ts CHANGED
@@ -69,7 +69,7 @@ export function createRows(drawData: ITextDrawData, content: string, style: ITex
69
69
  if (breakAll) {
70
70
 
71
71
  if (wordWidth) addWord() // break
72
- addRow()
72
+ if (rowWidth) addRow()
73
73
 
74
74
  } else {
75
75
  if (!afterBreak) afterBreak = charType === Letter && lastCharType == After // split ,S
@@ -77,11 +77,11 @@ export function createRows(drawData: ITextDrawData, content: string, style: ITex
77
77
  if (langBreak || afterBreak || charType === Break || charType === Before || charType === Single || (wordWidth + charWidth > realWidth)) {
78
78
 
79
79
  if (wordWidth) addWord() // break
80
- addRow()
80
+ if (rowWidth) addRow()
81
81
 
82
82
  } else {
83
83
 
84
- addRow()
84
+ if (rowWidth) addRow()
85
85
  }
86
86
  }
87
87