Skip to content

Commit b11fa47

Browse files
committed
ui updates
1 parent 4f35c7d commit b11fa47

File tree

4 files changed

+60
-38
lines changed

4 files changed

+60
-38
lines changed

src/ui/layouts/common/CustomStackBox/index.module.scss

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,16 @@
2222
display: flex;
2323
justify-content: center;
2424
align-items: center;
25-
26-
2725
.imageContainer {
26+
// max-height: 60px;
27+
// max-width: 60px;
28+
2829
height: 59px;
2930
width: 119px;
3031
background-color: #fff;
31-
display: flex;
32-
justify-content: center;
33-
align-items: center;
32+
// display: flex;
33+
// justify-content: center;
34+
// align-items: center;
3435

3536
img {
3637
height: 100%;

src/ui/layouts/common/CustomStackBox/index.tsx

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import { Box, Paragraph } from '../../../components';
33

44
import styles from './index.module.scss';
55
import { titleCase } from '../../../../utils/camelCase';
6+
import ReactTooltip from 'react-tooltip';
67

78
export const CustomStackBox: React.FC<{
89
image: any;
@@ -16,7 +17,7 @@ export const CustomStackBox: React.FC<{
1617
<Box
1718
paddingHorizontal="sm2"
1819
paddingVertical="sm2"
19-
className={styles.stackBox}
20+
className={styles.stackBox}
2021
>
2122
<input type='checkbox' className={styles.checkbox} checked={value} onClick={onCheck} />
2223
<Box className={styles.imageWrapper}>
@@ -26,13 +27,21 @@ export const CustomStackBox: React.FC<{
2627
</Box>
2728

2829
<Box style={{ marginTop: '8px' }}>
29-
<Paragraph className={styles.stackName}>{stackName?.slice(0, 15)}</Paragraph>
30+
<div data-tip data-for={stackName}>
31+
<Paragraph className={styles.stackName}>{stackName?.length > 14 ? <>{stackName?.slice(0, 15)}...</> : stackName}</Paragraph>
32+
</div>
33+
<ReactTooltip id={stackName} place="top" effect="solid">
34+
<Paragraph color="white">{stackName}</Paragraph>
35+
</ReactTooltip>
3036
</Box>
3137

3238
<Box marginTop="xs">
33-
<Paragraph className={styles.stackDesc}>
34-
{titleCase(stackDesc?.slice(0, 15))}
35-
</Paragraph>
39+
<div data-tip data-for={stackDesc}>
40+
<Paragraph className={styles.stackDesc}>{stackDesc?.length > 14 ? <>{titleCase(stackDesc?.slice(0, 15))}...</> : stackDesc}</Paragraph>
41+
</div>
42+
<ReactTooltip id={stackDesc} place="top" effect="solid">
43+
<Paragraph color="white">{titleCase(stackDesc)}</Paragraph>
44+
</ReactTooltip>
3645
</Box>
3746
</Box>
3847
);

src/ui/layouts/stacks/CreateStack/ListForAll/index.module.scss

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,13 @@
1+
.top {
2+
position: -webkit-sticky;
3+
position: sticky;
4+
top: 0;
5+
padding: 10px 0;
6+
background-color: #fff;
7+
z-index: 99;
8+
9+
}
10+
111
.selectedBox {
212
height: 60px;
313
width: 60px;

src/ui/layouts/stacks/CreateStack/ListForAll/index.tsx

Lines changed: 30 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -179,33 +179,35 @@ export const ListForAll: React.FC<Props> = () => {
179179
};
180180

181181
return (
182-
<Box style={{ width: '100%' }}>
183-
<Box>
184-
<H2 style={{ fontWeight: 'bolder' }}>Register a Stack</H2>
185-
</Box>
186-
187-
<Box marginTop="lg">
188-
<FlexBox.Row alignItems='center'>
189-
<Box style={{ width: '30%' }}>
190-
<FormTextField
191-
required={'*'}
192-
onChange={(e: any) => {
193-
setStackName(e);
194-
}}
195-
placeholder="Stack Name"
196-
label={'Enter Stack Name'}
197-
value={stackName}
198-
/>
199-
</Box>
200-
<Box marginLeft='xl' style={{ width: '30%' }}>
201-
<ToggleFieldBlock
202-
label={'Share Stack with public'}
203-
value={isShared}
204-
onHandleChange={(value: any) => setIshared(!isShared)}
205-
/>
206-
</Box>
207-
</FlexBox.Row>
208-
</Box>
182+
<Box style={{ width: '100%', position: 'relative' }}>
183+
184+
<div className={styles.top}>
185+
<Box>
186+
<H2 style={{ fontWeight: 'bolder' }}>Register a Stack</H2>
187+
</Box>
188+
<Box marginTop="lg">
189+
<FlexBox.Row alignItems='center'>
190+
<Box style={{ width: '30%' }}>
191+
<FormTextField
192+
required={'*'}
193+
onChange={(e: any) => {
194+
setStackName(e);
195+
}}
196+
placeholder="Stack Name"
197+
label={'Enter Stack Name'}
198+
value={stackName}
199+
/>
200+
</Box>
201+
<Box marginLeft='xl' style={{ width: '30%' }}>
202+
<ToggleFieldBlock
203+
label={'Share Stack with public'}
204+
value={isShared}
205+
onHandleChange={(value: any) => setIshared(!isShared)}
206+
/>
207+
</Box>
208+
</FlexBox.Row>
209+
</Box>
210+
</div>
209211

210212
{selectedStack?.length >= 0 && (
211213
<FlexBox.Row marginTop="md">
@@ -238,7 +240,7 @@ export const ListForAll: React.FC<Props> = () => {
238240
<FlexBox.Column>
239241
{stackComponentsTypes?.map((item) => {
240242
return (
241-
<Box marginTop="lg" style={{ overflow: 'auto' }}>
243+
<Box marginTop="lg" paddingBottom='lg' style={{ overflowX: 'auto' }}>
242244
<GetList
243245
type={item}
244246
flavourList={flavourList}

0 commit comments

Comments
 (0)