Skip to content

Commit c9e00ca

Browse files
author
donald
committed
fix issue 21
1 parent 369bd43 commit c9e00ca

File tree

2 files changed

+12
-6
lines changed

2 files changed

+12
-6
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Changelog
22

3+
## v0.5.1 - 2022-06-26
4+
5+
### Fixed
6+
7+
- missing messages, comments when using .NET style API. [#21](https://github.com/fresh2dev/AnyBox/issues/21)
8+
39
## v0.5.0 - 2022-06-01
410

511
### Added

Public/Show-AnyBox.ps1

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,8 @@ function Show-AnyBox
9090
[Parameter(ParameterSetName = 'create')]
9191
[string]$Image,
9292
[Parameter(ParameterSetName = 'create')]
93-
[Alias('m', 'Message')]
94-
[string[]]$Messages,
93+
[Alias('m')]
94+
[string[]]$Message,
9595
[Parameter(ParameterSetName = 'create')]
9696
[Alias('p', 'Prompt')]
9797
[object[]]$Prompts,
@@ -110,8 +110,8 @@ function Show-AnyBox
110110
[ValidateScript({ $_ -gt 0 })]
111111
[uint16]$ButtonRows = 1,
112112
[Parameter(ParameterSetName = 'create')]
113-
[Alias('c', 'Comment')]
114-
[string[]]$Comments,
113+
[Alias('c')]
114+
[string[]]$Comment,
115115
[Parameter(ParameterSetName = 'create')]
116116
[ValidateSet('Left', 'Center')]
117117
[Alias('Alignment')]
@@ -359,7 +359,7 @@ function Show-AnyBox
359359
}
360360

361361
# Add message textblocks.
362-
if (($txtMsg = New-TextBlock -RefForm ([ref]$form) -Text $($Messages -join [environment]::NewLine) -Name 'Message' -FontFamily $FontFamily -FontSize $FontSize -FontColor $FontColor -ContentAlignment $ContentAlignment))
362+
if (($txtMsg = New-TextBlock -RefForm ([ref]$form) -Text $($Message -join [environment]::NewLine) -Name 'Message' -FontFamily $FontFamily -FontSize $FontSize -FontColor $FontColor -ContentAlignment $ContentAlignment))
363363
{
364364
$form.highStack.AddChild($txtMsg)
365365
}
@@ -1169,7 +1169,7 @@ function Show-AnyBox
11691169
}
11701170

11711171
# Add comment textblocks.
1172-
if (($txtMsg = New-TextBlock -RefForm ([ref]$form) -text $($Comments -join [environment]::NewLine) -name 'txt_Explain' -FontFamily $FontFamily -FontSize $FontSize -FontColor $FontColor -ContentAlignment $ContentAlignment))
1172+
if (($txtMsg = New-TextBlock -RefForm ([ref]$form) -text $($Comment -join [environment]::NewLine) -name 'txt_Explain' -FontFamily $FontFamily -FontSize $FontSize -FontColor $FontColor -ContentAlignment $ContentAlignment))
11731173
{
11741174
$txtMsg.FontStyle = 'Italic'
11751175
$txtMsg.FontWeight = 'Normal'

0 commit comments

Comments
 (0)