sag_components 2.0.0-beta75 → 2.0.0-beta76
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.esm.js +175 -181
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +175 -181
- package/dist/index.js.map +1 -1
- package/dist/types/components/BubbleChart/BubbleChart.stories.d.ts +1 -0
- package/dist/types/components/TabMenu/TabMenu.d.ts +1 -1
- package/dist/types/components/TabMenu/TabMenu.stories.d.ts +27 -37
- package/dist/types/components/TabMenu/TabMenu.style.d.ts +2 -34
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -3482,154 +3482,6 @@ const LinnerDataBox = props => {
|
|
|
3482
3482
|
}))));
|
|
3483
3483
|
};
|
|
3484
3484
|
|
|
3485
|
-
const SagIconButtonWrapper = styled__default["default"].button`
|
|
3486
|
-
height: ${props => props.height};
|
|
3487
|
-
font-size: 14px;
|
|
3488
|
-
font-weight: 400;
|
|
3489
|
-
display: flex;
|
|
3490
|
-
gap: 8px;
|
|
3491
|
-
align-items: center;
|
|
3492
|
-
justify-content: center;
|
|
3493
|
-
padding: 8px 18px;
|
|
3494
|
-
white-space: nowrap;
|
|
3495
|
-
color: ${props => props.color};
|
|
3496
|
-
border-radius: 8px;
|
|
3497
|
-
border: 1px solid ${props => props.color};
|
|
3498
|
-
background: ${props => props.backgroundColor ? props.backgroundColor : 'transparent'};
|
|
3499
|
-
transition: box-shadow 0.3s ease;
|
|
3500
|
-
&:hover, &:focus {
|
|
3501
|
-
cursor: pointer;
|
|
3502
|
-
box-shadow: 5px 5px 10px 0px rgba(0, 0, 0, 0.1);
|
|
3503
|
-
}
|
|
3504
|
-
`;
|
|
3505
|
-
const SpanText$1 = styled__default["default"].span`
|
|
3506
|
-
`;
|
|
3507
|
-
|
|
3508
|
-
const SagIconButton = props => {
|
|
3509
|
-
const {
|
|
3510
|
-
iconName,
|
|
3511
|
-
color,
|
|
3512
|
-
backgroundColor,
|
|
3513
|
-
activeColor,
|
|
3514
|
-
height,
|
|
3515
|
-
buttonText,
|
|
3516
|
-
iconWidth,
|
|
3517
|
-
iconHeight,
|
|
3518
|
-
disabled,
|
|
3519
|
-
openState,
|
|
3520
|
-
onButtonClick,
|
|
3521
|
-
className
|
|
3522
|
-
} = props;
|
|
3523
|
-
const [activeState, setActiveState] = React$1.useState(openState);
|
|
3524
|
-
const onClickHandler = event => {
|
|
3525
|
-
onButtonClick(event);
|
|
3526
|
-
setActiveState(prevState => !prevState);
|
|
3527
|
-
};
|
|
3528
|
-
const getIcon = icon => {
|
|
3529
|
-
switch (icon.toLowerCase()) {
|
|
3530
|
-
case 'filter':
|
|
3531
|
-
return /*#__PURE__*/React__default["default"].createElement(FilterIcon, {
|
|
3532
|
-
height: iconHeight,
|
|
3533
|
-
width: iconWidth,
|
|
3534
|
-
color: activeState ? activeColor : color
|
|
3535
|
-
});
|
|
3536
|
-
case 'options':
|
|
3537
|
-
return /*#__PURE__*/React__default["default"].createElement(OptionsIcon, {
|
|
3538
|
-
height: iconHeight,
|
|
3539
|
-
width: iconWidth,
|
|
3540
|
-
color: activeState ? activeColor : color
|
|
3541
|
-
});
|
|
3542
|
-
case 'download':
|
|
3543
|
-
return /*#__PURE__*/React__default["default"].createElement(DownloadIcon, {
|
|
3544
|
-
height: iconHeight,
|
|
3545
|
-
width: iconWidth,
|
|
3546
|
-
color: activeState ? activeColor : color
|
|
3547
|
-
});
|
|
3548
|
-
case 'document':
|
|
3549
|
-
return /*#__PURE__*/React__default["default"].createElement(DocumentIcon, {
|
|
3550
|
-
height: iconHeight,
|
|
3551
|
-
width: iconWidth,
|
|
3552
|
-
color: activeState ? activeColor : color
|
|
3553
|
-
});
|
|
3554
|
-
case 'fly':
|
|
3555
|
-
return /*#__PURE__*/React__default["default"].createElement(FlyIcon, {
|
|
3556
|
-
height: iconHeight,
|
|
3557
|
-
width: iconWidth,
|
|
3558
|
-
color: activeState ? activeColor : color
|
|
3559
|
-
});
|
|
3560
|
-
case 'bell':
|
|
3561
|
-
return /*#__PURE__*/React__default["default"].createElement(BellIcon, {
|
|
3562
|
-
height: iconHeight,
|
|
3563
|
-
width: iconWidth,
|
|
3564
|
-
color: activeState ? activeColor : color
|
|
3565
|
-
});
|
|
3566
|
-
case 'maintenance':
|
|
3567
|
-
return /*#__PURE__*/React__default["default"].createElement(MaintenanceIcon, {
|
|
3568
|
-
height: iconHeight,
|
|
3569
|
-
width: iconWidth,
|
|
3570
|
-
color: activeState ? activeColor : color
|
|
3571
|
-
});
|
|
3572
|
-
case 'exit':
|
|
3573
|
-
return /*#__PURE__*/React__default["default"].createElement(ExitIcon, {
|
|
3574
|
-
height: iconHeight,
|
|
3575
|
-
width: iconWidth,
|
|
3576
|
-
color: activeState ? activeColor : color
|
|
3577
|
-
});
|
|
3578
|
-
case 'eye':
|
|
3579
|
-
return /*#__PURE__*/React__default["default"].createElement(EyeIcon, {
|
|
3580
|
-
height: iconHeight,
|
|
3581
|
-
width: iconWidth,
|
|
3582
|
-
color: activeState ? activeColor : color
|
|
3583
|
-
});
|
|
3584
|
-
default:
|
|
3585
|
-
return /*#__PURE__*/React__default["default"].createElement(EyeIcon, {
|
|
3586
|
-
height: iconHeight,
|
|
3587
|
-
width: iconWidth,
|
|
3588
|
-
color: activeState ? activeColor : color
|
|
3589
|
-
});
|
|
3590
|
-
}
|
|
3591
|
-
};
|
|
3592
|
-
return /*#__PURE__*/React__default["default"].createElement(SagIconButtonWrapper, {
|
|
3593
|
-
className: className,
|
|
3594
|
-
height: height,
|
|
3595
|
-
color: activeState ? activeColor : color,
|
|
3596
|
-
backgroundColor: backgroundColor,
|
|
3597
|
-
disabled: disabled,
|
|
3598
|
-
onClick: event => {
|
|
3599
|
-
onClickHandler(event);
|
|
3600
|
-
}
|
|
3601
|
-
}, getIcon(iconName), buttonText && /*#__PURE__*/React__default["default"].createElement(SpanText$1, null, buttonText));
|
|
3602
|
-
};
|
|
3603
|
-
SagIconButton.propTypes = {
|
|
3604
|
-
className: PropTypes.string,
|
|
3605
|
-
iconName: PropTypes.string,
|
|
3606
|
-
buttonText: PropTypes.string,
|
|
3607
|
-
height: PropTypes.string,
|
|
3608
|
-
color: PropTypes.string,
|
|
3609
|
-
backgroundColor: PropTypes.string,
|
|
3610
|
-
activeColor: PropTypes.string,
|
|
3611
|
-
iconHeight: PropTypes.number,
|
|
3612
|
-
iconWidth: PropTypes.number,
|
|
3613
|
-
openState: PropTypes.bool,
|
|
3614
|
-
disabled: PropTypes.bool,
|
|
3615
|
-
onButtonClick: PropTypes.func
|
|
3616
|
-
};
|
|
3617
|
-
SagIconButton.defaultProps = {
|
|
3618
|
-
className: '',
|
|
3619
|
-
iconName: 'filter',
|
|
3620
|
-
buttonText: 'Filter',
|
|
3621
|
-
height: '40px',
|
|
3622
|
-
color: '#212121',
|
|
3623
|
-
activeColor: '#229E38',
|
|
3624
|
-
backgroundColor: 'transparent',
|
|
3625
|
-
// '#E8F5EB',
|
|
3626
|
-
iconHeight: 12,
|
|
3627
|
-
iconWidth: 12,
|
|
3628
|
-
openState: false,
|
|
3629
|
-
disabled: false,
|
|
3630
|
-
onButtonClick: () => {}
|
|
3631
|
-
};
|
|
3632
|
-
|
|
3633
3485
|
const TextFieldContainer = styled__default["default"].div`
|
|
3634
3486
|
position: relative;
|
|
3635
3487
|
width: ${props => props.width};
|
|
@@ -3738,16 +3590,6 @@ const TopRow = styled__default["default"].div`
|
|
|
3738
3590
|
display: flex;
|
|
3739
3591
|
align-items: center;
|
|
3740
3592
|
gap: 20px;
|
|
3741
|
-
`;
|
|
3742
|
-
const Headline$1 = styled__default["default"].span`
|
|
3743
|
-
font-size: 18px;
|
|
3744
|
-
font-weight: 500;
|
|
3745
|
-
margin-right: auto;
|
|
3746
|
-
`;
|
|
3747
|
-
const Nav = styled__default["default"].nav`
|
|
3748
|
-
display: flex;
|
|
3749
|
-
flex-direction: row;
|
|
3750
|
-
|
|
3751
3593
|
`;
|
|
3752
3594
|
const TabActionLine = styled__default["default"].div`
|
|
3753
3595
|
margin-left: auto;
|
|
@@ -3755,20 +3597,28 @@ const TabActionLine = styled__default["default"].div`
|
|
|
3755
3597
|
align-items: center;
|
|
3756
3598
|
height: 100%;
|
|
3757
3599
|
`;
|
|
3600
|
+
const Headline$1 = styled__default["default"].span`
|
|
3601
|
+
font-size: 18px;
|
|
3602
|
+
font-weight: 500;
|
|
3603
|
+
margin-right: auto;
|
|
3604
|
+
`;
|
|
3758
3605
|
const Tabs = styled__default["default"].div`
|
|
3759
3606
|
position: relative;
|
|
3760
3607
|
display: flex;
|
|
3761
3608
|
align-items: center;
|
|
3762
3609
|
width: 100%;
|
|
3763
3610
|
`;
|
|
3764
|
-
const Tab = styled__default["default"].
|
|
3611
|
+
const Tab = styled__default["default"].button`
|
|
3765
3612
|
cursor: pointer;
|
|
3766
3613
|
position: relative;
|
|
3767
3614
|
text-align: center;
|
|
3768
3615
|
padding: 8px 12px;
|
|
3769
3616
|
font-size: 16px;
|
|
3770
3617
|
color: #000000;
|
|
3618
|
+
border: none;
|
|
3771
3619
|
border-bottom: 2px solid #D0D0D0;
|
|
3620
|
+
background: transparent;
|
|
3621
|
+
z-index: 2;
|
|
3772
3622
|
&.active {
|
|
3773
3623
|
font-weight: 600;
|
|
3774
3624
|
color: ${props => props.color};
|
|
@@ -3826,12 +3676,158 @@ const ActionsWrapper = styled__default["default"].div`
|
|
|
3826
3676
|
gap: 10px;
|
|
3827
3677
|
width: 100%;
|
|
3828
3678
|
`;
|
|
3829
|
-
const SagIconButtonWrap = styled__default["default"](SagIconButton)`
|
|
3830
|
-
`;
|
|
3831
3679
|
const SearchInputWrap = styled__default["default"](SearchInput)`
|
|
3832
3680
|
margin-left: auto;
|
|
3833
3681
|
`;
|
|
3834
3682
|
|
|
3683
|
+
const SagIconButtonWrapper = styled__default["default"].button`
|
|
3684
|
+
height: ${props => props.height};
|
|
3685
|
+
font-size: 14px;
|
|
3686
|
+
font-weight: 400;
|
|
3687
|
+
display: flex;
|
|
3688
|
+
gap: 8px;
|
|
3689
|
+
align-items: center;
|
|
3690
|
+
justify-content: center;
|
|
3691
|
+
padding: 8px 18px;
|
|
3692
|
+
white-space: nowrap;
|
|
3693
|
+
color: ${props => props.color};
|
|
3694
|
+
border-radius: 8px;
|
|
3695
|
+
border: 1px solid ${props => props.color};
|
|
3696
|
+
background: ${props => props.backgroundColor ? props.backgroundColor : 'transparent'};
|
|
3697
|
+
transition: box-shadow 0.3s ease;
|
|
3698
|
+
&:hover, &:focus {
|
|
3699
|
+
cursor: pointer;
|
|
3700
|
+
box-shadow: 5px 5px 10px 0px rgba(0, 0, 0, 0.1);
|
|
3701
|
+
}
|
|
3702
|
+
`;
|
|
3703
|
+
const SpanText$1 = styled__default["default"].span`
|
|
3704
|
+
`;
|
|
3705
|
+
|
|
3706
|
+
const SagIconButton = props => {
|
|
3707
|
+
const {
|
|
3708
|
+
iconName,
|
|
3709
|
+
color,
|
|
3710
|
+
backgroundColor,
|
|
3711
|
+
activeColor,
|
|
3712
|
+
height,
|
|
3713
|
+
buttonText,
|
|
3714
|
+
iconWidth,
|
|
3715
|
+
iconHeight,
|
|
3716
|
+
disabled,
|
|
3717
|
+
openState,
|
|
3718
|
+
onButtonClick,
|
|
3719
|
+
className
|
|
3720
|
+
} = props;
|
|
3721
|
+
const [activeState, setActiveState] = React$1.useState(openState);
|
|
3722
|
+
const onClickHandler = event => {
|
|
3723
|
+
onButtonClick(event);
|
|
3724
|
+
setActiveState(prevState => !prevState);
|
|
3725
|
+
};
|
|
3726
|
+
const getIcon = icon => {
|
|
3727
|
+
switch (icon.toLowerCase()) {
|
|
3728
|
+
case 'filter':
|
|
3729
|
+
return /*#__PURE__*/React__default["default"].createElement(FilterIcon, {
|
|
3730
|
+
height: iconHeight,
|
|
3731
|
+
width: iconWidth,
|
|
3732
|
+
color: activeState ? activeColor : color
|
|
3733
|
+
});
|
|
3734
|
+
case 'options':
|
|
3735
|
+
return /*#__PURE__*/React__default["default"].createElement(OptionsIcon, {
|
|
3736
|
+
height: iconHeight,
|
|
3737
|
+
width: iconWidth,
|
|
3738
|
+
color: activeState ? activeColor : color
|
|
3739
|
+
});
|
|
3740
|
+
case 'download':
|
|
3741
|
+
return /*#__PURE__*/React__default["default"].createElement(DownloadIcon, {
|
|
3742
|
+
height: iconHeight,
|
|
3743
|
+
width: iconWidth,
|
|
3744
|
+
color: activeState ? activeColor : color
|
|
3745
|
+
});
|
|
3746
|
+
case 'document':
|
|
3747
|
+
return /*#__PURE__*/React__default["default"].createElement(DocumentIcon, {
|
|
3748
|
+
height: iconHeight,
|
|
3749
|
+
width: iconWidth,
|
|
3750
|
+
color: activeState ? activeColor : color
|
|
3751
|
+
});
|
|
3752
|
+
case 'fly':
|
|
3753
|
+
return /*#__PURE__*/React__default["default"].createElement(FlyIcon, {
|
|
3754
|
+
height: iconHeight,
|
|
3755
|
+
width: iconWidth,
|
|
3756
|
+
color: activeState ? activeColor : color
|
|
3757
|
+
});
|
|
3758
|
+
case 'bell':
|
|
3759
|
+
return /*#__PURE__*/React__default["default"].createElement(BellIcon, {
|
|
3760
|
+
height: iconHeight,
|
|
3761
|
+
width: iconWidth,
|
|
3762
|
+
color: activeState ? activeColor : color
|
|
3763
|
+
});
|
|
3764
|
+
case 'maintenance':
|
|
3765
|
+
return /*#__PURE__*/React__default["default"].createElement(MaintenanceIcon, {
|
|
3766
|
+
height: iconHeight,
|
|
3767
|
+
width: iconWidth,
|
|
3768
|
+
color: activeState ? activeColor : color
|
|
3769
|
+
});
|
|
3770
|
+
case 'exit':
|
|
3771
|
+
return /*#__PURE__*/React__default["default"].createElement(ExitIcon, {
|
|
3772
|
+
height: iconHeight,
|
|
3773
|
+
width: iconWidth,
|
|
3774
|
+
color: activeState ? activeColor : color
|
|
3775
|
+
});
|
|
3776
|
+
case 'eye':
|
|
3777
|
+
return /*#__PURE__*/React__default["default"].createElement(EyeIcon, {
|
|
3778
|
+
height: iconHeight,
|
|
3779
|
+
width: iconWidth,
|
|
3780
|
+
color: activeState ? activeColor : color
|
|
3781
|
+
});
|
|
3782
|
+
default:
|
|
3783
|
+
return /*#__PURE__*/React__default["default"].createElement(EyeIcon, {
|
|
3784
|
+
height: iconHeight,
|
|
3785
|
+
width: iconWidth,
|
|
3786
|
+
color: activeState ? activeColor : color
|
|
3787
|
+
});
|
|
3788
|
+
}
|
|
3789
|
+
};
|
|
3790
|
+
return /*#__PURE__*/React__default["default"].createElement(SagIconButtonWrapper, {
|
|
3791
|
+
className: className,
|
|
3792
|
+
height: height,
|
|
3793
|
+
color: activeState ? activeColor : color,
|
|
3794
|
+
backgroundColor: backgroundColor,
|
|
3795
|
+
disabled: disabled,
|
|
3796
|
+
onClick: event => {
|
|
3797
|
+
onClickHandler(event);
|
|
3798
|
+
}
|
|
3799
|
+
}, getIcon(iconName), buttonText && /*#__PURE__*/React__default["default"].createElement(SpanText$1, null, buttonText));
|
|
3800
|
+
};
|
|
3801
|
+
SagIconButton.propTypes = {
|
|
3802
|
+
className: PropTypes.string,
|
|
3803
|
+
iconName: PropTypes.string,
|
|
3804
|
+
buttonText: PropTypes.string,
|
|
3805
|
+
height: PropTypes.string,
|
|
3806
|
+
color: PropTypes.string,
|
|
3807
|
+
backgroundColor: PropTypes.string,
|
|
3808
|
+
activeColor: PropTypes.string,
|
|
3809
|
+
iconHeight: PropTypes.number,
|
|
3810
|
+
iconWidth: PropTypes.number,
|
|
3811
|
+
openState: PropTypes.bool,
|
|
3812
|
+
disabled: PropTypes.bool,
|
|
3813
|
+
onButtonClick: PropTypes.func
|
|
3814
|
+
};
|
|
3815
|
+
SagIconButton.defaultProps = {
|
|
3816
|
+
className: '',
|
|
3817
|
+
iconName: 'filter',
|
|
3818
|
+
buttonText: 'Filter',
|
|
3819
|
+
height: '40px',
|
|
3820
|
+
color: '#212121',
|
|
3821
|
+
activeColor: '#229E38',
|
|
3822
|
+
backgroundColor: 'transparent',
|
|
3823
|
+
// '#E8F5EB',
|
|
3824
|
+
iconHeight: 12,
|
|
3825
|
+
iconWidth: 12,
|
|
3826
|
+
openState: false,
|
|
3827
|
+
disabled: false,
|
|
3828
|
+
onButtonClick: () => {}
|
|
3829
|
+
};
|
|
3830
|
+
|
|
3835
3831
|
const TabMenu = props => {
|
|
3836
3832
|
const {
|
|
3837
3833
|
activeColor,
|
|
@@ -3839,7 +3835,6 @@ const TabMenu = props => {
|
|
|
3839
3835
|
className,
|
|
3840
3836
|
color,
|
|
3841
3837
|
currentTab,
|
|
3842
|
-
headlineInsteadTabs,
|
|
3843
3838
|
headlineText,
|
|
3844
3839
|
inputWidth,
|
|
3845
3840
|
onFilterButtonClick,
|
|
@@ -3871,14 +3866,14 @@ const TabMenu = props => {
|
|
|
3871
3866
|
}, [currentTab]);
|
|
3872
3867
|
return /*#__PURE__*/React__default["default"].createElement(TabMenuContainer, {
|
|
3873
3868
|
className: className
|
|
3874
|
-
}, /*#__PURE__*/React__default["default"].createElement(TopRow, null, showFilterButton && /*#__PURE__*/React__default["default"].createElement(
|
|
3869
|
+
}, /*#__PURE__*/React__default["default"].createElement(TopRow, null, showFilterButton && /*#__PURE__*/React__default["default"].createElement(SagIconButton, {
|
|
3875
3870
|
id: "filterButton",
|
|
3876
3871
|
iconName: "Filter",
|
|
3877
3872
|
buttonText: "",
|
|
3878
3873
|
openState: panelIsOpen,
|
|
3879
3874
|
activeColor: activeColor,
|
|
3880
3875
|
onButtonClick: onFilterButtonClick
|
|
3881
|
-
}),
|
|
3876
|
+
}), headlineText && headlineText !== '' ? /*#__PURE__*/React__default["default"].createElement(Headline$1, null, headlineText) : /*#__PURE__*/React__default["default"].createElement("nav", {
|
|
3882
3877
|
className: "Nav"
|
|
3883
3878
|
}, /*#__PURE__*/React__default["default"].createElement(Tabs, {
|
|
3884
3879
|
className: "Tabs"
|
|
@@ -24010,22 +24005,21 @@ const DeleteIcon = styled__default["default"].div`
|
|
|
24010
24005
|
position: absolute;
|
|
24011
24006
|
`;
|
|
24012
24007
|
|
|
24013
|
-
const QuickFilterDropdownSingle =
|
|
24014
|
-
|
|
24015
|
-
|
|
24016
|
-
|
|
24017
|
-
|
|
24018
|
-
|
|
24019
|
-
|
|
24020
|
-
|
|
24021
|
-
|
|
24022
|
-
|
|
24023
|
-
|
|
24024
|
-
|
|
24025
|
-
|
|
24026
|
-
|
|
24027
|
-
|
|
24028
|
-
} = _ref;
|
|
24008
|
+
const QuickFilterDropdownSingle = ({
|
|
24009
|
+
label,
|
|
24010
|
+
hoverColor,
|
|
24011
|
+
options,
|
|
24012
|
+
selectedValue,
|
|
24013
|
+
placeHolder,
|
|
24014
|
+
onChange,
|
|
24015
|
+
disabled,
|
|
24016
|
+
width,
|
|
24017
|
+
error,
|
|
24018
|
+
errorMessage,
|
|
24019
|
+
xIconShow,
|
|
24020
|
+
labelColor,
|
|
24021
|
+
showLabelOnTop
|
|
24022
|
+
}) => {
|
|
24029
24023
|
const [isFocused, setIsFocused] = React$1.useState(false);
|
|
24030
24024
|
const [showOptions, setShowOptions] = React$1.useState(false);
|
|
24031
24025
|
const [inputValue, setInputValue] = React$1.useState("");
|
|
@@ -30805,7 +30799,7 @@ const BubbleChart = _ref => {
|
|
|
30805
30799
|
onMouseMove: handleChartMouseMove,
|
|
30806
30800
|
cursor: curosrMouse,
|
|
30807
30801
|
margin: {
|
|
30808
|
-
top:
|
|
30802
|
+
top: 100,
|
|
30809
30803
|
right: 190,
|
|
30810
30804
|
bottom: 50,
|
|
30811
30805
|
left: 180
|