]> apps.delaporte.us Git - dotfiles.git/commitdiff
dashboard prototype
authorEdward Delaporte <delaport@illinois.edu>
Mon, 3 May 2021 12:38:21 +0000 (07:38 -0500)
committerEdward Delaporte <delaport@illinois.edu>
Mon, 3 May 2021 12:38:21 +0000 (07:38 -0500)
psmodules/dash.psm1 [new file with mode: 0644]

diff --git a/psmodules/dash.psm1 b/psmodules/dash.psm1
new file mode 100644 (file)
index 0000000..caccf72
--- /dev/null
@@ -0,0 +1,20 @@
+
+function Get-MyDashboard() {
+  $MyDashboard = New-UDDashboard -Title "Hello, World" -Content {
+    New-UDCard -Title "Hello, Universal Dashboard" -Content {
+      New-UDParagraph -Text 'I am a very simple card. I am good at containing small bits of information. I am convenient because I require little markup to use effectively.'
+    } -Links @(
+      New-UDLink -Text 'This is a link' -Url '#!'
+      New-UDLink -Text 'This is a link' -Url '#!'
+      ) -Size 'small'
+    }
+  }
+  return $MyDashboard
+}
+
+function Inovke-MyDashboard() {
+  Start-UDDashboard -Port 1000 -Dashboard Get-MyDashboard
+  Write-Host "http://localhost:1000"
+}
+
+Export-ModuleMember -Function Invoke-MyDashboard
\ No newline at end of file