Showing
2 changed files
with
8 additions
and
4 deletions
| @@ -165,8 +165,8 @@ class Paragraph extends StatelessWidget { | @@ -165,8 +165,8 @@ class Paragraph extends StatelessWidget { | ||
| 165 | } | 165 | } |
| 166 | 166 | ||
| 167 | class Bullet extends StatelessWidget { | 167 | class Bullet extends StatelessWidget { |
| 168 | - Bullet( | ||
| 169 | - {this.text, | 168 | + Bullet({ |
| 169 | + this.text, | ||
| 170 | this.textAlign = TextAlign.left, | 170 | this.textAlign = TextAlign.left, |
| 171 | this.style, | 171 | this.style, |
| 172 | this.margin = const EdgeInsets.only(bottom: 2.0 * PdfPageFormat.mm), | 172 | this.margin = const EdgeInsets.only(bottom: 2.0 * PdfPageFormat.mm), |
| @@ -178,7 +178,8 @@ class Bullet extends StatelessWidget { | @@ -178,7 +178,8 @@ class Bullet extends StatelessWidget { | ||
| 178 | right: 2.0 * PdfPageFormat.mm, | 178 | right: 2.0 * PdfPageFormat.mm, |
| 179 | ), | 179 | ), |
| 180 | this.bulletShape = BoxShape.circle, | 180 | this.bulletShape = BoxShape.circle, |
| 181 | - this.bulletColor = PdfColors.black}); | 181 | + this.bulletColor = PdfColors.black, |
| 182 | + }); | ||
| 182 | 183 | ||
| 183 | final String? text; | 184 | final String? text; |
| 184 | 185 | ||
| @@ -213,7 +214,9 @@ class Bullet extends StatelessWidget { | @@ -213,7 +214,9 @@ class Bullet extends StatelessWidget { | ||
| 213 | decoration: BoxDecoration(color: bulletColor, shape: bulletShape), | 214 | decoration: BoxDecoration(color: bulletColor, shape: bulletShape), |
| 214 | ), | 215 | ), |
| 215 | Expanded( | 216 | Expanded( |
| 216 | - child: Text( | 217 | + child: text == null |
| 218 | + ? SizedBox() | ||
| 219 | + : Text( | ||
| 217 | text!, | 220 | text!, |
| 218 | textAlign: textAlign, | 221 | textAlign: textAlign, |
| 219 | style: Theme.of(context).bulletStyle.merge(style), | 222 | style: Theme.of(context).bulletStyle.merge(style), |
-
Please register or login to post a comment