Skip to content

Commit

Permalink
Add Prettify global
Browse files Browse the repository at this point in the history
  • Loading branch information
PrzemyslawKlys committed Jun 27, 2024
1 parent a1b6dbe commit abda18e
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion Public/New-HTMLTableOption.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,10 @@
[string] $NewLine,
[string] $Carriage,
[switch] $ArrayJoin,
[string] $ArrayJoinString = ', '
[string] $ArrayJoinString = ', ',
[switch] $PrettifyObject,
[string] $PrettifyObjectSeparator = ", ",
[string] $PrettifyObjectDateTimeFormat
)
if ($Script:HTMLSchema) {
if ($DataStore ) {
Expand Down Expand Up @@ -97,5 +100,14 @@
$Script:HTMLSchema['TableOptions']['DataStoreOptions'].ArrayJoin = $true
$Script:HTMLSchema['TableOptions']['DataStoreOptions'].ArrayJoinString = $ArrayJoinString
}
if ($PSBoundParameters.ContainsKey('PrettifyObject')) {
$Script:HTMLSchema['TableOptions']['DataStoreOptions'].PrettifyObject = $PrettifyObject.IsPresent
if ($PrettifyObjectSeparator) {
$Script:HTMLSchema['TableOptions']['DataStoreOptions'].PrettifyObjectSeparator = $PrettifyObjectSeparator
}
if ($PrettifyObjectDateTimeFormat) {
$Script:HTMLSchema['TableOptions']['DataStoreOptions'].PrettifyObjectDateTimeFormat = $PrettifyObjectDateTimeFormat
}
}
}
}

0 comments on commit abda18e

Please sign in to comment.