Skip to content

Commit 1afd703

Browse files
committed
feat: more refinements to the hello component
- profiles now have an icon and subtext - new profile tile clicks still do nothing (TODO)
1 parent 5463725 commit 1afd703

File tree

3 files changed

+28
-5
lines changed

3 files changed

+28
-5
lines changed

plugins/plugin-client-default/notebooks/hello.md

+7-4
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,15 @@ layout:
1313
maximized: true
1414
---
1515

16-
<img alt="CodeFlare Icon" src="@kui-shell/client/icons/svg/codeflare.svg" width="200" height="200" align="left" />
17-
CodeFlare is a framework to simplify the integration, scaling and acceleration of complex multi-step analytics and machine learning pipelines on the cloud.
16+
<img alt="CodeFlare Icon" src="@kui-shell/client/icons/svg/codeflare.svg" width="225" height="225" align="left" />
1817

19-
> #### Next Steps
18+
[CodeFlare](https://codeflare.dev) is a framework to simplify the
19+
integration, scaling and acceleration of complex multi-step analytics
20+
and machine learning pipelines on the cloud.
21+
22+
> ### Next Steps
2023
>
21-
> From your terminal, try `codeflare` to be guided through running jobs against the Cloud.
24+
> - To start running jobs against the Cloud, from your terminal, try `codeflare` .
2225
2326
---
2427

plugins/plugin-codeflare/src/controller/profile/get.tsx

+13-1
Original file line numberDiff line numberDiff line change
@@ -15,19 +15,31 @@
1515
*/
1616

1717
import React from "react"
18+
import prettyMillis from "pretty-ms"
1819
import { Profiles } from "madwizard"
1920
import { Flex, FlexItem, Tile } from "@patternfly/react-core"
2021

22+
import PlusIcon from "@patternfly/react-icons/dist/esm/icons/user-plus-icon"
23+
import ProfileIcon from "@patternfly/react-icons/dist/esm/icons/user-icon"
24+
2125
// eslint-disable-next-line @typescript-eslint/no-unused-vars
2226
export default async function getProfiles() {
2327
const profiles = await Profiles.list({})
2428

2529
return {
2630
react: (
2731
<Flex className="flex-fill sans-serif top-pad left-pad right-pad bottom-pad">
32+
<FlexItem>
33+
<Tile className="codeflare--tile codeflare--tile-new" title="New Profile" icon={<PlusIcon />} isStacked>
34+
Customize a profile
35+
</Tile>
36+
</FlexItem>
37+
2838
{profiles.map((_) => (
2939
<FlexItem key={_.profile.name}>
30-
<Tile className="codeflare--tile" title={_.profile.name} />
40+
<Tile className="codeflare--tile" title={_.profile.name} icon={<ProfileIcon />} isStacked>
41+
{`Last used ${prettyMillis(Date.now() - _.profile.lastUsedTime, { compact: true })} ago`}
42+
</Tile>
3143
</FlexItem>
3244
))}
3345
</Flex>

plugins/plugin-codeflare/web/scss/components/Hello/_index.scss

+8
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,10 @@ $cell: 1.5em;
104104
&[data-status="ERROR"] {
105105
background-color: var(--color-red);
106106
}
107+
108+
svg {
109+
fill: var(--color-text-02);
110+
}
107111
}
108112

109113
.pf-c-tile__header {
@@ -116,3 +120,7 @@ $cell: 1.5em;
116120
color: var(--color-tile-title);
117121
font-size: 1rem;
118122
}
123+
124+
.pf-c-tile__body {
125+
color: var(--color-text-02);
126+
}

0 commit comments

Comments
 (0)