How to make a card a link?

I’m planning on using this from my mobile mainly so I wanted a card on the home screen that goes to a page instead of using the smaller hamburger menu. Is there a way to make the whole card a link? I can only find info on adding a link to the bottom of the card (new-udcard -links), instead of the entire card.

With the new link component you can make this.
Download the version from github or wait that adam will release a beta vesion

Where do i find that info? I can’t find it on demo site or in docs. Is there somewhere else that i can find what included?

BTW you can take a look in the link.tests.ps1 in github to see how to make card as link.
if its help you

Hey @GarySmithPS without using the cool NEW stuff @AlonGvili has been cooking up you are limited. We will hopefully have that documented / putting out tutorials / training materials soon to get people up and running on the new material UI components!

Especially for mobile I could see building a “Tile based” navigation UI using these methods that would be a good experience!

For now on UD Cards you can can embed links but you don’t have as much flexibility, but here are some options that might work for you for now:

New-UDCard -Title "Card With Links" -Content {
        
        #UDLink
        New-UDLink -Text "This is a UD Link in a CARD Content" -Url "https://github.com"
        
        #HTML
        New-UDHtml -Markup '<a href="https://github.com">This is a UDHTML in CARD Content</a>'

        #BUTTON
        New-UDButton -Flat -Text "BUTTON In Card Content" -Icon fast_forward -OnClick {
            Invoke-UDRedirect -Url "https://github.com"
        }

    } -Links @(
        New-UDLink -Text "This is a UDLink in CARD LINKS" -Url "https://github.com"
    )

While the whole card is not a link there are at least some links in the card:

image

@artvandelay440 has also been doing some really cool ui work, that he has been nice enough to show off as well and give some examples:

if you are using the new UDMuLink command you can just do this

        new-udmulink -Content {
            $card
        } -Id 'card-link' -url '#'         

and you have a card object as link .

give it a try

1 Like

Hey @AlonGvili where can I download these from?

Github or u can wait for adam to release the beta version

Awesome, I guess I’ll wait :wink:

the beta was released so you can try the new components

1 Like

next silly question. How do i download the beta?

All it should take to download the beta is this:

INSTALL-MODULE UNIVERSALDASHBOARD -ALLOWPRERELEASE -FORCE -AcceptLicense

The “-ALLOWPRERELEASE” is the key!

OK. that was easier then I thought! I’ll try it out.
Ideally, I’m just trying to knock up a few things so I can show work the benefits and get them to buy the full edition so that I can have people sign in.

I updated the version and gave it a go today but I get an error.

 New-UDColumn -SmallSize 12 -MediumSize 6 -LargeSize 3 -Content {
            New-UDMuLink -Content {
            New-UDCard -Title 'LAPS Password' -Image (New-UDImage -Url 'https://stuart-mcintyre.com/wp-content/uploads/2016/10/Ihate-Passwords-2.jpg') -Content {
                'Pull the LAPS password from Active Directory'
            } -Size small 
            } -Id 'card-link' -url 'http://Server:1000/PageTitle'
        }

Error: The term ‘New-UDMuLink’ is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.

However, if I open PowerShell on the host and type the start of the cmdlet then hit tab its finding it.

I posted how to do something like this here with a standard udcard:

strange look like UD don’t import the module, i will take a look at this .

I found the problem

it should be folder in with the name UniversalDashboard.MaterialUI but it’s not exist
C:\Program Files\WindowsPowerShell\Modules\UniversalDashboard.Community\2.4.0\Modules

maybe a bug with the main ud build script.

will talk with adam on this error.

When I had the beta and the latest normal build the type ahead would find it for a second when opening powershell but then when you try a few seconds later it’s gone. Once I removed the stable version then it would alway show in the tab complete but would throw the error.
Not sure if that helps, it’s just what I noticed.

Assuming it’s a problem with the module, was how I coded it correct?

Also while I have you guys, is there a trial or something of full version? I’d really like to show these to my boss so others can use it, but without being able to show how it would work with signing in from other IT/Users views for security and also to customise the UD view dependent on current logged on user, then I just can’t even get my foot in the door to get them to buy it. And buy it they will :wink: whether they like it or not.

One last thing. Every time I come back to UD after a while of inactivity I find that the icon names/format had changed. I realise this is probably a font awesome thing but that error where it lists all available icons in csv format is horrible.
Could you not update the sample page on poshud.com to show a grid with available icons and there names, and direct people there when script fails due to unknown icons? This would make picking icons that match easier too.
Failing that maybe a line break after each icon that starts with a new letter of the alphabet to find them a bit easier. I’ve been coping the list and then splitting on “,” but that’s a long list too.

@GarySmithPS: You can run the Enterprise version as a trial, it limits the Dashboard to running for 60 minutes at a time and has a window that you can hide, that will give you the full functionality to demo with.

Thanks, that’s exactly what I needed.