hds-web 1.2.0 → 1.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.css +2 -2
- package/dist/index.es.css +2 -2
- package/dist/index.es.js +6 -6
- package/dist/index.js +6 -6
- package/package.json +1 -1
- package/src/HDS/assets/icons/hasura-1.svg +3 -0
- package/src/HDS/assets/icons/hasura-2.svg +3 -0
- package/src/HDS/assets/icons/hasura-3.svg +3 -0
- package/src/HDS/components/Buttons/button.js +3 -3
- package/src/HDS/components/Cards/Menu/flyout.js +5 -4
- package/src/HDS/components/Cards/Menu/flyoutA.js +5 -4
- package/src/HDS/components/Cards/Menu/flyoutFull.js +1 -0
- package/src/HDS/components/Cards/Misc/iconCard.js +68 -59
- package/src/HDS/components/Cards/Misc/talkCard.js +41 -35
- package/src/HDS/components/Cards/TalkDetailCard/talkDetailCard.js +70 -51
- package/src/HDS/components/Headers/v3Header.js +2 -2
- package/src/HDS/components/Hero/h2.js +8 -6
- package/src/HDS/components/Tables/tableB.js +0 -1
- package/src/HDS/components/Tabs/tab.js +1 -1
- package/src/HDS/components/common-components/Icon/IconMap.js +6 -0
- package/src/HDS/foundation/Typography/Typography.js +1 -1
- package/src/HDS/helpers/Media/index.js +1 -0
- package/src/HDS/helpers/Media/mediabox.js +76 -0
- package/src/HDS/modules/index.js +2 -1
- package/src/HDS/modules/navCard/index.js +1 -0
- package/src/HDS/modules/navCard/navCard.js +106 -0
- package/src/styles/tailwind.css +93 -54
- package/tailwind.config.js +1 -0
@@ -0,0 +1,76 @@
|
|
1
|
+
import React, { useState } from 'react';
|
2
|
+
import { Icon } from '../../components/common-components/Icon';
|
3
|
+
|
4
|
+
const MediaViewer = ({ img_url, video_url, video_poster, width }) => {
|
5
|
+
const [isVideoPlaying, setIsVideoPlaying] = useState(false);
|
6
|
+
|
7
|
+
const handleVideoClick = () => {
|
8
|
+
setIsVideoPlaying(true);
|
9
|
+
};
|
10
|
+
|
11
|
+
const handleVideoClose = () => {
|
12
|
+
setIsVideoPlaying(false);
|
13
|
+
};
|
14
|
+
|
15
|
+
return (
|
16
|
+
<div>
|
17
|
+
{img_url && (
|
18
|
+
<div className='flex justify-center'>
|
19
|
+
<img src={img_url} alt="Image" style={{ width }} onClick={handleVideoClick} />
|
20
|
+
</div>
|
21
|
+
)}
|
22
|
+
|
23
|
+
{video_url && (
|
24
|
+
<div>
|
25
|
+
{!isVideoPlaying ? (
|
26
|
+
<div className='relative flex justify-center'>
|
27
|
+
<div className='flex items-center'>
|
28
|
+
|
29
|
+
<a
|
30
|
+
className=" left-[45%] z-10 cursor-pointer absolute w-12 h-12 flex justify-center items-center rounded-full border border-neutral-0"
|
31
|
+
onClick={() => {
|
32
|
+
setIsVideoPlaying(true);
|
33
|
+
}}
|
34
|
+
>
|
35
|
+
|
36
|
+
<Icon variant='play' height='h-6 w-6' strokeClass='stroke-neutral-0' />
|
37
|
+
</a>
|
38
|
+
</div>
|
39
|
+
<div>
|
40
|
+
<img
|
41
|
+
src={video_poster}
|
42
|
+
alt="Video Poster"
|
43
|
+
style={{ width }}
|
44
|
+
onClick={handleVideoClick}
|
45
|
+
className="cursor-pointer"
|
46
|
+
/>
|
47
|
+
</div>
|
48
|
+
</div>
|
49
|
+
) : (
|
50
|
+
<div className="fixed inset-0 flex justify-center items-center z-50">
|
51
|
+
<div className="relative w-screen h-screen flex items-start p-10">
|
52
|
+
<a
|
53
|
+
className=" z-10 cursor-pointer left-14 top-2 relative w-12 h-12 bg-neutral-0 flex justify-center items-center rounded-full"
|
54
|
+
onClick={handleVideoClose}
|
55
|
+
>
|
56
|
+
<Icon variant='xclose' height='h-6 w-6' strokeClass='stroke-neutral-800' />
|
57
|
+
</a>
|
58
|
+
<video
|
59
|
+
controls={false}
|
60
|
+
autoPlay
|
61
|
+
muted
|
62
|
+
className="object-contain max-w-full max-h-full"
|
63
|
+
>
|
64
|
+
<source src={video_url} type="video/mp4" />
|
65
|
+
</video>
|
66
|
+
|
67
|
+
</div>
|
68
|
+
</div>
|
69
|
+
)}
|
70
|
+
</div>
|
71
|
+
)}
|
72
|
+
</div>
|
73
|
+
);
|
74
|
+
};
|
75
|
+
|
76
|
+
export default MediaViewer;
|
package/src/HDS/modules/index.js
CHANGED
@@ -1 +1,2 @@
|
|
1
|
-
export * from './TextCard';
|
1
|
+
export * from './TextCard';
|
2
|
+
export * from './navCard';
|
@@ -0,0 +1 @@
|
|
1
|
+
export {default as NavCard} from './navCard'
|
@@ -0,0 +1,106 @@
|
|
1
|
+
import { React, useState } from 'react';
|
2
|
+
import { MediaBox } from '../../helpers/Media';
|
3
|
+
import { Typography } from '../../foundation/Typography';
|
4
|
+
import { HDSButton } from '../../components/Buttons';
|
5
|
+
import { HDSColor } from '../../foundation/ColorPalette';
|
6
|
+
import { Tab } from '../../components/Tabs';
|
7
|
+
import PropTypes from 'prop-types';
|
8
|
+
|
9
|
+
const tabCard = (tabContent) => (
|
10
|
+
<>
|
11
|
+
<div className='px-3'>
|
12
|
+
<Typography textStyle='h4' className={HDSColor(tabContent.title_color)}>{tabContent.title}</Typography>
|
13
|
+
|
14
|
+
<Typography textStyle='body1c' className={HDSColor(tabContent.sub_title_color)}>{tabContent.sub_title}</Typography>
|
15
|
+
</div>
|
16
|
+
<div className='flex pl-3 pt-6 pb-8'>
|
17
|
+
<HDSButton
|
18
|
+
label={tabContent.btnLabel}
|
19
|
+
type='secondaryLink'
|
20
|
+
leftIconVariant='none'
|
21
|
+
rightIconVariant='none'
|
22
|
+
state='default'
|
23
|
+
size='sm'
|
24
|
+
rightAnimatedArrow={true}
|
25
|
+
rightAnimatedArrowColor='#1E56E3'
|
26
|
+
animatedHoverStroke='group-hover:stroke-neutral-900'
|
27
|
+
className='flex'
|
28
|
+
btnTextColorClass='text-blue-600'
|
29
|
+
/>
|
30
|
+
</div>
|
31
|
+
<div className=''>
|
32
|
+
<MediaBox
|
33
|
+
img_url={tabContent.img_url}
|
34
|
+
video_url={tabContent.video_url}
|
35
|
+
video_poster={tabContent.video_poster}
|
36
|
+
width={400}
|
37
|
+
/>
|
38
|
+
</div>
|
39
|
+
</>
|
40
|
+
)
|
41
|
+
|
42
|
+
export default function NavCard(props) {
|
43
|
+
const tabNames = Object.keys(props.tabContent);
|
44
|
+
const [activeTab, setActiveTab] = useState(tabNames[0]);
|
45
|
+
|
46
|
+
function handleTabClick(tab) {
|
47
|
+
setActiveTab(tab.name);
|
48
|
+
// Perform any other actions based on the clicked tab
|
49
|
+
}
|
50
|
+
return (
|
51
|
+
<>
|
52
|
+
{props.navTabs &&
|
53
|
+
|
54
|
+
<div className='max-w-[44.44rem] p-16 bg-neutral-0 shadow rounded-2xl'>
|
55
|
+
|
56
|
+
<div className='flex justify-center pb-8'>
|
57
|
+
<Tab
|
58
|
+
onTabClick={handleTabClick}
|
59
|
+
tabs={props.navTabs}
|
60
|
+
/>
|
61
|
+
</div>
|
62
|
+
<div className='transition-all ease-in-out duration-1000'>
|
63
|
+
{props.tabContent &&
|
64
|
+
props.tabContent[activeTab] &&
|
65
|
+
tabCard(props.tabContent[activeTab])}
|
66
|
+
</div>
|
67
|
+
|
68
|
+
</div>}
|
69
|
+
</>
|
70
|
+
)
|
71
|
+
}
|
72
|
+
|
73
|
+
NavCard.defaultProps = {
|
74
|
+
tabContent: {
|
75
|
+
'Performance': {
|
76
|
+
title: '1Get blazing-fast APIs without the extra work',
|
77
|
+
sub_title: 'Hasura simplifies data access and reduces latency for optimizing performance via a Haskell core, JIT query compiler, predicate pushdown, and application-level caching out of the box.',
|
78
|
+
},
|
79
|
+
'Company': {
|
80
|
+
title: '2Get blazing-fast APIs without the extra work',
|
81
|
+
sub_title: 'Hasura simplifies data access and reduces latency for optimizing performance via a Haskell core, JIT query compiler, predicate pushdown, and application-level caching out of the box.',
|
82
|
+
},
|
83
|
+
'Authorization': {
|
84
|
+
title: '3Get blazing-fast APIs without the extra work',
|
85
|
+
sub_title: 'Hasura simplifies data access and reduces latency for optimizing performance via a Haskell core, JIT query compiler, predicate pushdown, and application-level caching out of the box.',
|
86
|
+
},
|
87
|
+
},
|
88
|
+
|
89
|
+
navTabs: [
|
90
|
+
{
|
91
|
+
current: true,
|
92
|
+
href: '',
|
93
|
+
name: 'Performance'
|
94
|
+
},
|
95
|
+
{
|
96
|
+
current: 'Insant Api',
|
97
|
+
href: '',
|
98
|
+
name: 'Company'
|
99
|
+
},
|
100
|
+
{
|
101
|
+
current: '[Circular]',
|
102
|
+
href: '',
|
103
|
+
name: 'Authorization'
|
104
|
+
},
|
105
|
+
]
|
106
|
+
}
|
package/src/styles/tailwind.css
CHANGED
@@ -879,6 +879,10 @@ select {
|
|
879
879
|
left: 50%;
|
880
880
|
}
|
881
881
|
|
882
|
+
.left-14 {
|
883
|
+
left: 3.5rem;
|
884
|
+
}
|
885
|
+
|
882
886
|
.left-2 {
|
883
887
|
left: 0.5rem;
|
884
888
|
}
|
@@ -891,6 +895,10 @@ select {
|
|
891
895
|
left: 17.6%;
|
892
896
|
}
|
893
897
|
|
898
|
+
.left-\[45\%\] {
|
899
|
+
left: 45%;
|
900
|
+
}
|
901
|
+
|
894
902
|
.left-\[82\.3\%\] {
|
895
903
|
left: 82.3%;
|
896
904
|
}
|
@@ -915,6 +923,10 @@ select {
|
|
915
923
|
top: 0px;
|
916
924
|
}
|
917
925
|
|
926
|
+
.top-2 {
|
927
|
+
top: 0.5rem;
|
928
|
+
}
|
929
|
+
|
918
930
|
.isolate {
|
919
931
|
isolation: isolate;
|
920
932
|
}
|
@@ -1093,10 +1105,6 @@ select {
|
|
1093
1105
|
margin-left: -1px;
|
1094
1106
|
}
|
1095
1107
|
|
1096
|
-
.-mr-2 {
|
1097
|
-
margin-right: -0.5rem;
|
1098
|
-
}
|
1099
|
-
|
1100
1108
|
.-mt-5 {
|
1101
1109
|
margin-top: -1.25rem;
|
1102
1110
|
}
|
@@ -1241,6 +1249,13 @@ select {
|
|
1241
1249
|
margin-top: 2.25rem;
|
1242
1250
|
}
|
1243
1251
|
|
1252
|
+
.line-clamp-3 {
|
1253
|
+
overflow: hidden;
|
1254
|
+
display: -webkit-box;
|
1255
|
+
-webkit-box-orient: vertical;
|
1256
|
+
-webkit-line-clamp: 3;
|
1257
|
+
}
|
1258
|
+
|
1244
1259
|
.block {
|
1245
1260
|
display: block;
|
1246
1261
|
}
|
@@ -1353,6 +1368,10 @@ select {
|
|
1353
1368
|
height: 130px;
|
1354
1369
|
}
|
1355
1370
|
|
1371
|
+
.h-\[33px\] {
|
1372
|
+
height: 33px;
|
1373
|
+
}
|
1374
|
+
|
1356
1375
|
.h-\[60px\] {
|
1357
1376
|
height: 60px;
|
1358
1377
|
}
|
@@ -1365,14 +1384,18 @@ select {
|
|
1365
1384
|
height: 100%;
|
1366
1385
|
}
|
1367
1386
|
|
1368
|
-
.h
|
1369
|
-
height:
|
1387
|
+
.h-screen {
|
1388
|
+
height: 100vh;
|
1370
1389
|
}
|
1371
1390
|
|
1372
1391
|
.max-h-\[26\.25\] {
|
1373
1392
|
max-height: 26.25;
|
1374
1393
|
}
|
1375
1394
|
|
1395
|
+
.max-h-full {
|
1396
|
+
max-height: 100%;
|
1397
|
+
}
|
1398
|
+
|
1376
1399
|
.w-1\/2 {
|
1377
1400
|
width: 50%;
|
1378
1401
|
}
|
@@ -1441,6 +1464,10 @@ select {
|
|
1441
1464
|
width: 24rem;
|
1442
1465
|
}
|
1443
1466
|
|
1467
|
+
.w-\[103px\] {
|
1468
|
+
width: 103px;
|
1469
|
+
}
|
1470
|
+
|
1444
1471
|
.w-\[22\.5rem\] {
|
1445
1472
|
width: 22.5rem;
|
1446
1473
|
}
|
@@ -1495,14 +1522,6 @@ select {
|
|
1495
1522
|
width: 100vw;
|
1496
1523
|
}
|
1497
1524
|
|
1498
|
-
.w-\[104px\] {
|
1499
|
-
width: 104px;
|
1500
|
-
}
|
1501
|
-
|
1502
|
-
.w-\[103px\] {
|
1503
|
-
width: 103px;
|
1504
|
-
}
|
1505
|
-
|
1506
1525
|
.min-w-\[15rem\] {
|
1507
1526
|
min-width: 15rem;
|
1508
1527
|
}
|
@@ -1549,6 +1568,14 @@ select {
|
|
1549
1568
|
max-width: 22rem;
|
1550
1569
|
}
|
1551
1570
|
|
1571
|
+
.max-w-\[29\.18rem\] {
|
1572
|
+
max-width: 29.18rem;
|
1573
|
+
}
|
1574
|
+
|
1575
|
+
.max-w-\[44\.44rem\] {
|
1576
|
+
max-width: 44.44rem;
|
1577
|
+
}
|
1578
|
+
|
1552
1579
|
.max-w-\[6rem\] {
|
1553
1580
|
max-width: 6rem;
|
1554
1581
|
}
|
@@ -1557,6 +1584,10 @@ select {
|
|
1557
1584
|
max-width: 882px;
|
1558
1585
|
}
|
1559
1586
|
|
1587
|
+
.max-w-full {
|
1588
|
+
max-width: 100%;
|
1589
|
+
}
|
1590
|
+
|
1560
1591
|
.max-w-max {
|
1561
1592
|
max-width: -webkit-max-content;
|
1562
1593
|
max-width: max-content;
|
@@ -1571,10 +1602,6 @@ select {
|
|
1571
1602
|
max-width: min-content;
|
1572
1603
|
}
|
1573
1604
|
|
1574
|
-
.max-w-\[29\.18rem\] {
|
1575
|
-
max-width: 29.18rem;
|
1576
|
-
}
|
1577
|
-
|
1578
1605
|
.flex-1 {
|
1579
1606
|
flex: 1 1 0%;
|
1580
1607
|
}
|
@@ -1813,6 +1840,10 @@ select {
|
|
1813
1840
|
gap: 3rem;
|
1814
1841
|
}
|
1815
1842
|
|
1843
|
+
.gap-16 {
|
1844
|
+
gap: 4rem;
|
1845
|
+
}
|
1846
|
+
|
1816
1847
|
.gap-2 {
|
1817
1848
|
gap: 0.5rem;
|
1818
1849
|
}
|
@@ -1981,6 +2012,14 @@ select {
|
|
1981
2012
|
border-color: rgb(229 231 235 / var(--tw-divide-opacity));
|
1982
2013
|
}
|
1983
2014
|
|
2015
|
+
.self-start {
|
2016
|
+
align-self: flex-start;
|
2017
|
+
}
|
2018
|
+
|
2019
|
+
.self-end {
|
2020
|
+
align-self: flex-end;
|
2021
|
+
}
|
2022
|
+
|
1984
2023
|
.overflow-auto {
|
1985
2024
|
overflow: auto;
|
1986
2025
|
}
|
@@ -5080,6 +5119,10 @@ select {
|
|
5080
5119
|
padding: 2.5rem;
|
5081
5120
|
}
|
5082
5121
|
|
5122
|
+
.p-16 {
|
5123
|
+
padding: 4rem;
|
5124
|
+
}
|
5125
|
+
|
5083
5126
|
.p-2 {
|
5084
5127
|
padding: 0.5rem;
|
5085
5128
|
}
|
@@ -5256,10 +5299,6 @@ select {
|
|
5256
5299
|
padding-bottom: 2.5rem;
|
5257
5300
|
}
|
5258
5301
|
|
5259
|
-
.pb-14 {
|
5260
|
-
padding-bottom: 3.5rem;
|
5261
|
-
}
|
5262
|
-
|
5263
5302
|
.pb-16 {
|
5264
5303
|
padding-bottom: 4rem;
|
5265
5304
|
}
|
@@ -5392,6 +5431,10 @@ select {
|
|
5392
5431
|
text-align: right;
|
5393
5432
|
}
|
5394
5433
|
|
5434
|
+
.font-petrona {
|
5435
|
+
font-family: Petrona, sans;
|
5436
|
+
}
|
5437
|
+
|
5395
5438
|
.text-2xl {
|
5396
5439
|
font-size: 1.5rem;
|
5397
5440
|
line-height: 2rem;
|
@@ -6365,6 +6408,10 @@ select {
|
|
6365
6408
|
transition-duration: 100ms;
|
6366
6409
|
}
|
6367
6410
|
|
6411
|
+
.duration-1000 {
|
6412
|
+
transition-duration: 1000ms;
|
6413
|
+
}
|
6414
|
+
|
6368
6415
|
.duration-150 {
|
6369
6416
|
transition-duration: 150ms;
|
6370
6417
|
}
|
@@ -7886,6 +7933,10 @@ select {
|
|
7886
7933
|
stroke: #FFFFFF;
|
7887
7934
|
}
|
7888
7935
|
|
7936
|
+
.group:hover .group-hover\:stroke-neutral-900 {
|
7937
|
+
stroke: #111927;
|
7938
|
+
}
|
7939
|
+
|
7889
7940
|
.group:hover .group-hover\:opacity-30 {
|
7890
7941
|
opacity: 0.3;
|
7891
7942
|
}
|
@@ -8124,6 +8175,10 @@ select {
|
|
8124
8175
|
padding-right: 2rem;
|
8125
8176
|
}
|
8126
8177
|
|
8178
|
+
.tb\:pb-14 {
|
8179
|
+
padding-bottom: 3.5rem;
|
8180
|
+
}
|
8181
|
+
|
8127
8182
|
.tb\:pb-8 {
|
8128
8183
|
padding-bottom: 2rem;
|
8129
8184
|
}
|
@@ -8500,30 +8555,14 @@ select {
|
|
8500
8555
|
margin-left: 3rem;
|
8501
8556
|
}
|
8502
8557
|
|
8503
|
-
.md\:flex {
|
8504
|
-
display: flex;
|
8505
|
-
}
|
8506
|
-
|
8507
8558
|
.md\:hidden {
|
8508
8559
|
display: none;
|
8509
8560
|
}
|
8510
8561
|
|
8511
|
-
.md\:flex-1 {
|
8512
|
-
flex: 1 1 0%;
|
8513
|
-
}
|
8514
|
-
|
8515
|
-
.md\:items-center {
|
8516
|
-
align-items: center;
|
8517
|
-
}
|
8518
|
-
|
8519
8562
|
.md\:justify-start {
|
8520
8563
|
justify-content: flex-start;
|
8521
8564
|
}
|
8522
8565
|
|
8523
|
-
.md\:justify-between {
|
8524
|
-
justify-content: space-between;
|
8525
|
-
}
|
8526
|
-
|
8527
8566
|
.md\:space-x-6 > :not([hidden]) ~ :not([hidden]) {
|
8528
8567
|
--tw-space-x-reverse: 0;
|
8529
8568
|
margin-right: calc(1.5rem * var(--tw-space-x-reverse));
|
@@ -8560,14 +8599,6 @@ select {
|
|
8560
8599
|
width: 50%;
|
8561
8600
|
}
|
8562
8601
|
|
8563
|
-
.tb-l\:w-\[70\%\] {
|
8564
|
-
width: 70%;
|
8565
|
-
}
|
8566
|
-
|
8567
|
-
.tb-l\:w-full {
|
8568
|
-
width: 100%;
|
8569
|
-
}
|
8570
|
-
|
8571
8602
|
.tb-l\:w-\[38\%\] {
|
8572
8603
|
width: 38%;
|
8573
8604
|
}
|
@@ -8576,6 +8607,14 @@ select {
|
|
8576
8607
|
width: 62%;
|
8577
8608
|
}
|
8578
8609
|
|
8610
|
+
.tb-l\:w-\[70\%\] {
|
8611
|
+
width: 70%;
|
8612
|
+
}
|
8613
|
+
|
8614
|
+
.tb-l\:w-full {
|
8615
|
+
width: 100%;
|
8616
|
+
}
|
8617
|
+
|
8579
8618
|
.tb-l\:min-w-\[400px\] {
|
8580
8619
|
min-width: 400px;
|
8581
8620
|
}
|
@@ -8596,10 +8635,6 @@ select {
|
|
8596
8635
|
justify-content: flex-start;
|
8597
8636
|
}
|
8598
8637
|
|
8599
|
-
.tb-l\:justify-end {
|
8600
|
-
justify-content: flex-end;
|
8601
|
-
}
|
8602
|
-
|
8603
8638
|
.tb-l\:justify-between {
|
8604
8639
|
justify-content: space-between;
|
8605
8640
|
}
|
@@ -8749,6 +8784,10 @@ select {
|
|
8749
8784
|
gap: 0px;
|
8750
8785
|
}
|
8751
8786
|
|
8787
|
+
.db\:gap-28 {
|
8788
|
+
gap: 7rem;
|
8789
|
+
}
|
8790
|
+
|
8752
8791
|
.db\:gap-36 {
|
8753
8792
|
gap: 9rem;
|
8754
8793
|
}
|
@@ -9084,10 +9123,6 @@ select {
|
|
9084
9123
|
padding-bottom: 0.5rem;
|
9085
9124
|
}
|
9086
9125
|
|
9087
|
-
.\[\&\>p\]\:last\:pb-0:last-child>p {
|
9088
|
-
padding-bottom: 0px;
|
9089
|
-
}
|
9090
|
-
|
9091
9126
|
.last\:\[\&\>p\]\:pb-0>p:last-child {
|
9092
9127
|
padding-bottom: 0px;
|
9093
9128
|
}
|
@@ -9108,6 +9143,10 @@ select {
|
|
9108
9143
|
padding-bottom: 0px;
|
9109
9144
|
}
|
9110
9145
|
|
9146
|
+
.last\:\[\&\>ul\>li\]\:pb-0>ul>li:last-child {
|
9147
|
+
padding-bottom: 0px;
|
9148
|
+
}
|
9149
|
+
|
9111
9150
|
.\[\&\>ul\]\:ps-4>ul {
|
9112
9151
|
-webkit-padding-start: 1rem;
|
9113
9152
|
padding-inline-start: 1rem;
|