From d661d17fa971eb2d37ca7664c4b5ba708103592c Mon Sep 17 00:00:00 2001 From: Adam Driscoll Date: Tue, 24 Sep 2019 08:30:16 -0600 Subject: [PATCH] Fixes #1045 --- .../Scripts/avatar.ps1 | 2 +- .../Scripts/button.ps1 | 2 +- src/UniversalDashboard.MaterialUI/Scripts/card.ps1 | 14 +++++++------- .../Scripts/checkbox.ps1 | 2 +- .../Scripts/chips.ps1 | 2 +- .../Scripts/icon-button.ps1 | 2 +- src/UniversalDashboard.MaterialUI/Scripts/link.ps1 | 2 +- src/UniversalDashboard.MaterialUI/Scripts/list.ps1 | 4 ++-- .../Scripts/paper.ps1 | 2 +- src/UniversalDashboard.MaterialUI/Scripts/pdf.ps1 | 2 +- .../Scripts/typography.ps1 | 2 +- .../Scripts/button.ps1 | 2 +- .../Scripts/card.ps1 | 2 +- .../Scripts/checkbox.ps1 | 2 +- .../Scripts/collapsible.ps1 | 4 ++-- .../Scripts/collection.ps1 | 4 ++-- .../Scripts/column.ps1 | 2 +- src/UniversalDashboard.Materialize/Scripts/fab.ps1 | 4 ++-- .../Scripts/grid-layout.ps1 | 2 +- .../Scripts/grid.ps1 | 2 +- .../Scripts/image-carousel.ps1 | 4 ++-- .../Scripts/link.ps1 | 2 +- .../Scripts/radio.ps1 | 2 +- src/UniversalDashboard.Materialize/Scripts/row.ps1 | 2 +- .../Scripts/select.ps1 | 2 +- .../Scripts/switch.ps1 | 2 +- .../Scripts/table.ps1 | 2 +- .../Scripts/tabs.ps1 | 4 ++-- src/UniversalDashboard/Controls/src/heading.ps1 | 2 +- src/UniversalDashboard/Controls/src/icon.ps1 | 2 +- src/UniversalDashboard/Controls/src/iframe.ps1 | 2 +- src/UniversalDashboard/Controls/src/image.ps1 | 2 +- src/UniversalDashboard/Controls/src/span.ps1 | 2 +- src/UniversalDashboard/Controls/src/splitpane.ps1 | 2 +- src/UniversalDashboard/Controls/src/textbox.ps1 | 2 +- 35 files changed, 47 insertions(+), 47 deletions(-) diff --git a/src/UniversalDashboard.MaterialUI/Scripts/avatar.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/avatar.ps1 index d9e7df0b..6ef7e9cf 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/avatar.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/avatar.ps1 @@ -1,6 +1,6 @@ function New-UDMuAvatar { param( - [Parameter ()][string]$Id = (New-Guid).ToString(), + [Parameter ()][string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter ()][string]$Image, [Parameter ()][string]$Alt, [Parameter ()][string]$ClassName, diff --git a/src/UniversalDashboard.MaterialUI/Scripts/button.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/button.ps1 index 350bfc48..d7c10060 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/button.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/button.ps1 @@ -32,7 +32,7 @@ function New-UDMuButton { [string]$Href, [Parameter()] - [string]$Id = (New-Guid).ToString() + [string]$Id = ([Guid]::NewGuid()).ToString() ) diff --git a/src/UniversalDashboard.MaterialUI/Scripts/card.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/card.ps1 index fd7aee1a..544b0fd1 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/card.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/card.ps1 @@ -2,7 +2,7 @@ function New-UDMuCard { [CmdletBinding()] param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [string]$ClassName, @@ -111,7 +111,7 @@ function New-UDMuCardToolbar { [CmdletBinding()] param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [string]$ClassName, @@ -171,7 +171,7 @@ function New-UDMuCardHeader { [CmdletBinding()] param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [string]$ClassName, @@ -229,7 +229,7 @@ function New-UDMuCardBody { [CmdletBinding()] param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [string]$ClassName, @@ -288,7 +288,7 @@ function New-UDMuCardExpand { [CmdletBinding()] param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [string]$ClassName, @@ -345,7 +345,7 @@ function New-UDMuCardFooter { [CmdletBinding()] param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [string]$ClassName, @@ -401,7 +401,7 @@ function New-UDMuCardMedia { [OutputType([Hashtable])] param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [ValidateSet("img", "video", "audio")] diff --git a/src/UniversalDashboard.MaterialUI/Scripts/checkbox.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/checkbox.ps1 index 8ab3c200..75eb8710 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/checkbox.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/checkbox.ps1 @@ -30,7 +30,7 @@ function New-UDMuCheckBox { [string]$LabelPlacement, [Parameter(Position = 8)] - [string]$Id = (New-Guid).ToString() + [string]$Id = ([Guid]::NewGuid()).ToString() ) diff --git a/src/UniversalDashboard.MaterialUI/Scripts/chips.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/chips.ps1 index 586fa4b7..c57ecd32 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/chips.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/chips.ps1 @@ -2,7 +2,7 @@ function New-UDMuChip { [CmdletBinding(DefaultParameterSetName = 'Icon')] param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter(Position = 0)] [string]$Label, diff --git a/src/UniversalDashboard.MaterialUI/Scripts/icon-button.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/icon-button.ps1 index 96608384..22f53f7a 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/icon-button.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/icon-button.ps1 @@ -1,7 +1,7 @@ function New-UDIconButton { param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter ()] [PSTypeName('UniversalDashboard.Icon')]$Icon, [Parameter ()] diff --git a/src/UniversalDashboard.MaterialUI/Scripts/link.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/link.ps1 index 52bbf3fe..f733692f 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/link.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/link.ps1 @@ -1,6 +1,6 @@ function New-UDMuLink { param( - [Parameter (HelpMessage="Enter id for this object")][string]$Id = (New-Guid).ToString(), + [Parameter (HelpMessage="Enter id for this object")][string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter (HelpMessage="Enter url, this can be remote or local")][string]$url, [Parameter (HelpMessage="Show line under the text or content")] [ValidateSet('none','hover','always')][string]$underline = "none", diff --git a/src/UniversalDashboard.MaterialUI/Scripts/list.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/list.ps1 index fd6a628f..9151ef44 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/list.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/list.ps1 @@ -1,6 +1,6 @@ function New-UDMuList { param( - [Parameter ()][string]$Id = (New-Guid).ToString(), + [Parameter ()][string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter ()][scriptblock]$Content, [Parameter ()][string]$SubHeader, [Parameter ()][Hashtable]$Style @@ -24,7 +24,7 @@ function New-UDMuList { function New-UDMuListItem { [CmdletBinding()] param( - [Parameter ()][string]$Id = (New-Guid).ToString(), + [Parameter ()][string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter ()][ValidateSet("Icon","Avatar")][string]$AvatarType, [Parameter ()][object]$OnClick, [Parameter ()][switch]$IsButton, diff --git a/src/UniversalDashboard.MaterialUI/Scripts/paper.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/paper.ps1 index 8ea8b2a6..4bffd46d 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/paper.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/paper.ps1 @@ -1,6 +1,6 @@ function New-UDMuPaper { param( - [Parameter()][string]$Id = (New-Guid).ToString(), + [Parameter()][string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()][ScriptBlock]$Content, [Parameter()][switch]$IsEndPoint, [Parameter()][string]$Width = '500', diff --git a/src/UniversalDashboard.MaterialUI/Scripts/pdf.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/pdf.ps1 index 259f1221..f904a4ae 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/pdf.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/pdf.ps1 @@ -1,7 +1,7 @@ function New-UDPdf { param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [string]$FilePath diff --git a/src/UniversalDashboard.MaterialUI/Scripts/typography.ps1 b/src/UniversalDashboard.MaterialUI/Scripts/typography.ps1 index 144d82f5..d5a236a9 100644 --- a/src/UniversalDashboard.MaterialUI/Scripts/typography.ps1 +++ b/src/UniversalDashboard.MaterialUI/Scripts/typography.ps1 @@ -2,7 +2,7 @@ function New-UDMuTypography { [CmdletBinding(DefaultParameterSetName = "text")] param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [ValidateSet ("h1", "h2", "h3", "h4", "h5", "h6", "subtitle1", "subtitle2", "body1", "body2", "caption", "button", "overline", "srOnly", "inherit", "display4", "display3", "display2", "display1", "headline", "title", "subheading")] diff --git a/src/UniversalDashboard.Materialize/Scripts/button.ps1 b/src/UniversalDashboard.Materialize/Scripts/button.ps1 index 3dcc731b..622a5df0 100644 --- a/src/UniversalDashboard.Materialize/Scripts/button.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/button.ps1 @@ -1,7 +1,7 @@ function New-UDButton { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] $Text, [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/card.ps1 b/src/UniversalDashboard.Materialize/Scripts/card.ps1 index 36553c8a..50737dec 100644 --- a/src/UniversalDashboard.Materialize/Scripts/card.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/card.ps1 @@ -2,7 +2,7 @@ function New-UDCard { [CmdletBinding(DefaultParameterSetName = 'text')] param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] [String]$Title, [Parameter(ParameterSetName = 'content')] diff --git a/src/UniversalDashboard.Materialize/Scripts/checkbox.ps1 b/src/UniversalDashboard.Materialize/Scripts/checkbox.ps1 index db375701..1ae06292 100644 --- a/src/UniversalDashboard.Materialize/Scripts/checkbox.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/checkbox.ps1 @@ -1,7 +1,7 @@ function New-UDCheckbox { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] $Label, [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/collapsible.ps1 b/src/UniversalDashboard.Materialize/Scripts/collapsible.ps1 index 59add5db..6d6a3bfc 100644 --- a/src/UniversalDashboard.Materialize/Scripts/collapsible.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/collapsible.ps1 @@ -1,7 +1,7 @@ function New-UDCollapsible { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter(Mandatory = $true, Position = 0)] [ScriptBlock]$Items, [Parameter()] @@ -33,7 +33,7 @@ function New-UDCollapsibleItem { [CmdletBinding(DefaultParameterSetName = "content")] param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] [String]$Title, [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/collection.ps1 b/src/UniversalDashboard.Materialize/Scripts/collection.ps1 index e46ada86..73ec7975 100644 --- a/src/UniversalDashboard.Materialize/Scripts/collection.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/collection.ps1 @@ -1,7 +1,7 @@ function New-UDCollection { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] [ScriptBlock]$Content, [Parameter()] @@ -43,7 +43,7 @@ function New-UDCollectionItem { [CmdletBinding(DefaultParameterSetName = 'content')] param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] [ScriptBlock]$Content, [Parameter(ParameterSetName = 'content')] diff --git a/src/UniversalDashboard.Materialize/Scripts/column.ps1 b/src/UniversalDashboard.Materialize/Scripts/column.ps1 index c085fbf4..51d975a3 100644 --- a/src/UniversalDashboard.Materialize/Scripts/column.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/column.ps1 @@ -2,7 +2,7 @@ function New-UDColumn { [CmdletBinding(DefaultParameterSetName = 'content')] param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] [Alias('Size')] diff --git a/src/UniversalDashboard.Materialize/Scripts/fab.ps1 b/src/UniversalDashboard.Materialize/Scripts/fab.ps1 index 3e587509..9040c2ba 100644 --- a/src/UniversalDashboard.Materialize/Scripts/fab.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/fab.ps1 @@ -1,7 +1,7 @@ function New-UDFab { param( [Parameter()] - [string] $Id = (New-Guid), + [string] $Id = ([Guid]::NewGuid()), [Parameter()] [ScriptBlock]$Content, [Parameter()] @@ -61,7 +61,7 @@ function New-UDFab { function New-UDFabButton { param( [Parameter()] - [string] $Id = (New-Guid), + [string] $Id = ([Guid]::NewGuid()), [Parameter()] [UniversalDashboard.Models.DashboardColor]$ButtonColor, [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/grid-layout.ps1 b/src/UniversalDashboard.Materialize/Scripts/grid-layout.ps1 index ab8d38d5..5a47c873 100644 --- a/src/UniversalDashboard.Materialize/Scripts/grid-layout.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/grid-layout.ps1 @@ -1,7 +1,7 @@ function New-UDGridLayout { param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [int]$RowHeight = 30, [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/grid.ps1 b/src/UniversalDashboard.Materialize/Scripts/grid.ps1 index a59d5e17..5dfc5df0 100644 --- a/src/UniversalDashboard.Materialize/Scripts/grid.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/grid.ps1 @@ -1,7 +1,7 @@ function New-UDGrid { param( [Parameter()] - [string]$Id = (New-Guid), + [string]$Id = ([Guid]::NewGuid()), [Parameter()] [string]$Title, [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/image-carousel.ps1 b/src/UniversalDashboard.Materialize/Scripts/image-carousel.ps1 index a908065a..bdd692d8 100644 --- a/src/UniversalDashboard.Materialize/Scripts/image-carousel.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/image-carousel.ps1 @@ -3,7 +3,7 @@ function New-UDImageCarousel { [Parameter()] [ScriptBlock]$Items, [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [switch]$ShowIndicators, [Parameter()] @@ -63,7 +63,7 @@ function New-UDImageCarouselItem { [Parameter()] [string]$TextPosition, [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [string]$Title, [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/link.ps1 b/src/UniversalDashboard.Materialize/Scripts/link.ps1 index fe1c1619..6e8016ba 100644 --- a/src/UniversalDashboard.Materialize/Scripts/link.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/link.ps1 @@ -1,7 +1,7 @@ function New-UDLink { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] [string]$Text, [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/radio.ps1 b/src/UniversalDashboard.Materialize/Scripts/radio.ps1 index 52cf5024..daecc4a2 100644 --- a/src/UniversalDashboard.Materialize/Scripts/radio.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/radio.ps1 @@ -1,7 +1,7 @@ function New-UDRadio { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] [String]$Label, [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/row.ps1 b/src/UniversalDashboard.Materialize/Scripts/row.ps1 index 59bdb399..f804a2a5 100644 --- a/src/UniversalDashboard.Materialize/Scripts/row.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/row.ps1 @@ -2,7 +2,7 @@ function New-UDRow { [CmdletBinding(DefaultParameterSetName = 'static')] param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter(ParameterSetName = "static", Position = 0)] [ScriptBlock]$Columns, [Parameter(ParameterSetName = "dynamic")] diff --git a/src/UniversalDashboard.Materialize/Scripts/select.ps1 b/src/UniversalDashboard.Materialize/Scripts/select.ps1 index f6ca6924..c2dcf8c9 100644 --- a/src/UniversalDashboard.Materialize/Scripts/select.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/select.ps1 @@ -1,7 +1,7 @@ function New-UDSelect { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] [ScriptBlock]$Option, [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/switch.ps1 b/src/UniversalDashboard.Materialize/Scripts/switch.ps1 index 7f8c6928..902c1c8d 100644 --- a/src/UniversalDashboard.Materialize/Scripts/switch.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/switch.ps1 @@ -1,7 +1,7 @@ function New-UDSwitch { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] $OnText = "On", [Parameter()] diff --git a/src/UniversalDashboard.Materialize/Scripts/table.ps1 b/src/UniversalDashboard.Materialize/Scripts/table.ps1 index 5b5cfbe0..1d4300d9 100644 --- a/src/UniversalDashboard.Materialize/Scripts/table.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/table.ps1 @@ -1,7 +1,7 @@ function New-UDTable { param( [Parameter()] - [string]$Id = (New-Guid), + [string]$Id = ([Guid]::NewGuid()), [Parameter()] [string]$Title, [Parameter(Mandatory = $true)] diff --git a/src/UniversalDashboard.Materialize/Scripts/tabs.ps1 b/src/UniversalDashboard.Materialize/Scripts/tabs.ps1 index df6e12d5..b23176f7 100644 --- a/src/UniversalDashboard.Materialize/Scripts/tabs.ps1 +++ b/src/UniversalDashboard.Materialize/Scripts/tabs.ps1 @@ -3,7 +3,7 @@ function New-UDTabContainer { [Parameter(Mandatory, ParameterSetName = "Static")] [ScriptBlock]$Tabs, [Parameter()] - [string]$Id = (New-Guid).ToString() + [string]$Id = ([Guid]::NewGuid()).ToString() ) End { @@ -24,7 +24,7 @@ function New-UDTab { [Parameter(Mandatory, ParameterSetName = "static")] [ScriptBlock]$Content, [Parameter()] - [string]$Id = (New-Guid).ToString() + [string]$Id = ([Guid]::NewGuid()).ToString() ) End { diff --git a/src/UniversalDashboard/Controls/src/heading.ps1 b/src/UniversalDashboard/Controls/src/heading.ps1 index 36b375e4..c5212247 100644 --- a/src/UniversalDashboard/Controls/src/heading.ps1 +++ b/src/UniversalDashboard/Controls/src/heading.ps1 @@ -1,7 +1,7 @@ function New-UDHeading { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter(ParameterSetName = "Content")] [ScriptBlock]$Content, [Parameter(ParameterSetName = "Text")] diff --git a/src/UniversalDashboard/Controls/src/icon.ps1 b/src/UniversalDashboard/Controls/src/icon.ps1 index 0652417a..45e49a6f 100644 --- a/src/UniversalDashboard/Controls/src/icon.ps1 +++ b/src/UniversalDashboard/Controls/src/icon.ps1 @@ -1,7 +1,7 @@ function New-UDIcon { param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter()] [UniversalDashboard.Models.FontAwesomeIcons]$Icon, [Parameter()] diff --git a/src/UniversalDashboard/Controls/src/iframe.ps1 b/src/UniversalDashboard/Controls/src/iframe.ps1 index 79e7bec2..32d47fb0 100644 --- a/src/UniversalDashboard/Controls/src/iframe.ps1 +++ b/src/UniversalDashboard/Controls/src/iframe.ps1 @@ -1,7 +1,7 @@ function New-UDIFrame { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] $Uri ) diff --git a/src/UniversalDashboard/Controls/src/image.ps1 b/src/UniversalDashboard/Controls/src/image.ps1 index 5ffcefe8..64a7b98d 100644 --- a/src/UniversalDashboard/Controls/src/image.ps1 +++ b/src/UniversalDashboard/Controls/src/image.ps1 @@ -2,7 +2,7 @@ function New-UDImage { [CmdletBinding(DefaultParameterSetName = 'url')] param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter(ParameterSetName = 'url')] [String]$Url, [Parameter(ParameterSetName = 'path')] diff --git a/src/UniversalDashboard/Controls/src/span.ps1 b/src/UniversalDashboard/Controls/src/span.ps1 index a54346ed..8ca11151 100644 --- a/src/UniversalDashboard/Controls/src/span.ps1 +++ b/src/UniversalDashboard/Controls/src/span.ps1 @@ -1,7 +1,7 @@ function New-UDSpan { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] $Content ) diff --git a/src/UniversalDashboard/Controls/src/splitpane.ps1 b/src/UniversalDashboard/Controls/src/splitpane.ps1 index 7699b134..c56ad9e4 100644 --- a/src/UniversalDashboard/Controls/src/splitpane.ps1 +++ b/src/UniversalDashboard/Controls/src/splitpane.ps1 @@ -1,7 +1,7 @@ function New-UDSplitPane { param( [Parameter()] - [string]$Id = (New-Guid).ToString(), + [string]$Id = ([Guid]::NewGuid()).ToString(), [Parameter(Mandatory)] [ScriptBlock]$Content, [Parameter()] diff --git a/src/UniversalDashboard/Controls/src/textbox.ps1 b/src/UniversalDashboard/Controls/src/textbox.ps1 index 233ac617..90d729c8 100644 --- a/src/UniversalDashboard/Controls/src/textbox.ps1 +++ b/src/UniversalDashboard/Controls/src/textbox.ps1 @@ -1,7 +1,7 @@ function New-UDTextbox { param( [Parameter()] - [String]$Id = (New-Guid), + [String]$Id = ([Guid]::NewGuid()), [Parameter()] [string]$Label, [Parameter()]