beem-component 1.5.8 → 1.5.9
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/.babelrc +17 -0
- package/.eslintrc +62 -0
- package/.prettierrc +6 -0
- package/dist/components/Accordion/Accordion.js +31 -64
- package/dist/components/Accordion/Accordion.stories.js +29 -29
- package/dist/components/Avatars/avatars.js +31 -46
- package/dist/components/Avatars/avatars.stories.js +18 -18
- package/dist/components/BannerCard/bannerCard.stories.js +14 -14
- package/dist/components/BannerCard/bannerCards.js +30 -48
- package/dist/components/Buttons/Stories/basicbutton.stories.js +24 -24
- package/dist/components/Buttons/Stories/buttonAlertIcons.stories.js +17 -17
- package/dist/components/Buttons/Stories/buttonIconsOnly.stories.js +17 -17
- package/dist/components/Buttons/buttonAlertIcons.js +28 -44
- package/dist/components/Buttons/buttonDropdown copy.js +15 -18
- package/dist/components/Buttons/buttonDropdown.js +2 -2
- package/dist/components/Buttons/buttonIconsOnly.js +35 -49
- package/dist/components/Buttons/buttons.js +75 -86
- package/dist/components/Cards/cards.js +15 -11
- package/dist/components/Cards/cards.stories.js +8 -8
- package/dist/components/ChatComponents/ChatBody/chatBody.js +80 -69
- package/dist/components/ChatComponents/ChatBody/chatBody.stories.js +6 -6
- package/dist/components/ChatComponents/ChatBody/sessionDetails.js +9 -16
- package/dist/components/ChatComponents/ChatHeader/chatHeader.js +5 -7
- package/dist/components/ChatComponents/ChatHeader/chatHeader.stories.js +3 -3
- package/dist/components/ChatComponents/ColorPicker/colorPicker.js +5 -7
- package/dist/components/ChatComponents/ColorPicker/colorPicker.stories.js +7 -3
- package/dist/components/ChatComponents/ContactCards/contactCards.js +15 -12
- package/dist/components/ChatComponents/ContactCards/contactCards.stories.js +3 -3
- package/dist/components/ChatComponents/FormAccordion/FormAccordion.js +14 -10
- package/dist/components/ChatComponents/FormAccordion/FormAccordion.stories.js +9 -5
- package/dist/components/ChatComponents/InfoTab/infoTab.js +11 -9
- package/dist/components/ChatComponents/InfoTab/infoTab.stories.js +6 -6
- package/dist/components/ChatComponents/LabelAccordion/LabelAccordion.js +5 -7
- package/dist/components/ChatComponents/LabelAccordion/LabelAccordion.stories.js +12 -7
- package/dist/components/ChatComponents/NoteAccordion/NoteAccordion.js +11 -9
- package/dist/components/ChatComponents/NoteAccordion/NoteAccordion.stories.js +15 -13
- package/dist/components/Chats/chat.js +41 -32
- package/dist/components/Chats/chatInput.js +18 -14
- package/dist/components/Chats/chatwrapper.js +20 -12
- package/dist/components/Checkbox/checkboxToggler.js +61 -0
- package/dist/components/Checkbox/checkboxToggler.stories.js +81 -0
- package/dist/components/Lists/listBox.js +14 -30
- package/dist/components/Lists/listBox.stories.js +12 -23
- package/dist/components/Lists/listHeader.stories.js +13 -13
- package/dist/components/Lists/listheader.js +12 -27
- package/dist/components/Lists/rowLabels.js +19 -30
- package/dist/components/Lists/rowLabels.stories.js +22 -25
- package/dist/components/Loader/loader.js +17 -31
- package/dist/components/Loader/loader.stories.js +13 -13
- package/dist/components/MainWrapper/index.js +5 -7
- package/dist/components/MessageCounter/MessageCounter.stories.js +14 -14
- package/dist/components/MessageCounter/messageCounter.js +16 -18
- package/dist/components/Modals/modal.js +37 -57
- package/dist/components/Modals/modals.stories.js +15 -28
- package/dist/components/NoteBar/noteBar.js +28 -57
- package/dist/components/NoteBar/noteBar.stories.js +17 -17
- package/dist/components/PerformanceIndicator/performaceIndicator.stories.js +15 -15
- package/dist/components/PerformanceIndicator/performanceIndicator.js +21 -34
- package/dist/components/Pills/pills.js +24 -56
- package/dist/components/Pills/pills.stories.js +21 -23
- package/dist/components/ProfileIcon/ProfileIcon.js +28 -29
- package/dist/components/ProfileIcon/profileIcon.stories.js +18 -18
- package/dist/components/ProgressBar/progressbar.js +15 -17
- package/dist/components/ProgressBar/progressbar.stories.js +8 -10
- package/dist/components/ProgressRing/progressRing.js +38 -54
- package/dist/components/ProgressRing/progressRing.stories.js +16 -16
- package/dist/components/RouteLink/link.js +8 -10
- package/dist/components/RouteLink/link.stories.js +3 -3
- package/dist/components/ScrollBar/scrollBar.js +19 -17
- package/dist/components/SuperFluid/Content/index.js +5 -7
- package/dist/components/SuperFluid/ContentTitle.js/index.js +14 -10
- package/dist/components/SuperFluid/SegmentCard/index.js +22 -13
- package/dist/components/Tabs/tabs.js +16 -35
- package/dist/components/Tabs/tabs.stories.js +19 -19
- package/dist/components/Tags/tags.js +33 -65
- package/dist/components/Tags/tags.stories.js +18 -18
- package/dist/components/breakpoints.js +3 -3
- package/dist/components/chatHeader.js +17 -11
- package/dist/components/checkbox.js +27 -26
- package/dist/components/colors.js +32 -30
- package/dist/components/contacts.js +39 -25
- package/dist/components/dropdown.js +29 -35
- package/dist/components/dropdownButton.js +50 -53
- package/dist/components/dropdownItems.js +26 -19
- package/dist/components/examples/App.js +2 -2
- package/dist/components/examples/InfoAccordion.js +2 -3
- package/dist/components/examples/chatBodyExample.js +1 -5
- package/dist/components/examples/selectExample.js +6 -20
- package/dist/components/globalStyles.js +1 -5
- package/dist/components/iconStyles.js +56 -58
- package/dist/components/index.js +27 -23
- package/dist/components/input.js +33 -36
- package/dist/components/logo.js +9 -16
- package/dist/components/navbar.js +24 -13
- package/dist/components/search.js +20 -21
- package/dist/components/typography.js +14 -14
- package/dist/components/wrapper.js +8 -8
- package/package.json +54 -31
- package/src/App.js +10 -7
- package/src/index.js +6 -8
- package/src/lib/components/Accordion/Accordion.js +32 -14
- package/src/lib/components/Accordion/Accordion.stories.js +31 -31
- package/src/lib/components/Avatars/avatars.js +33 -28
- package/src/lib/components/Avatars/avatars.stories.js +18 -18
- package/src/lib/components/BannerCard/bannerCard.stories.js +16 -17
- package/src/lib/components/BannerCard/bannerCards.js +18 -18
- package/src/lib/components/Buttons/Stories/basicbutton.stories.js +29 -29
- package/src/lib/components/Buttons/Stories/buttonAlertIcons.stories.js +17 -17
- package/src/lib/components/Buttons/Stories/buttonIconsOnly.stories.js +24 -24
- package/src/lib/components/Buttons/buttonAlertIcons.js +22 -25
- package/src/lib/components/Buttons/buttonIconsOnly.js +32 -28
- package/src/lib/components/Buttons/buttons.js +70 -73
- package/src/lib/components/Cards/cards.js +2 -3
- package/src/lib/components/Cards/cards.stories.js +10 -10
- package/src/lib/components/ChatComponents/ChatBody/chatBody.js +46 -45
- package/src/lib/components/ChatComponents/ChatBody/chatBody.stories.js +34 -28
- package/src/lib/components/ChatComponents/ChatBody/sessionDetails.js +2 -2
- package/src/lib/components/ChatComponents/ChatHeader/chatHeader.js +2 -2
- package/src/lib/components/ChatComponents/ChatHeader/chatHeader.stories.js +4 -4
- package/src/lib/components/ChatComponents/ColorPicker/colorPicker.js +2 -2
- package/src/lib/components/ChatComponents/ColorPicker/colorPicker.stories.js +4 -3
- package/src/lib/components/ChatComponents/ContactCards/contactCards.js +7 -5
- package/src/lib/components/ChatComponents/ContactCards/contactCards.stories.js +6 -6
- package/src/lib/components/ChatComponents/FormAccordion/FormAccordion.js +3 -3
- package/src/lib/components/ChatComponents/FormAccordion/FormAccordion.stories.js +4 -3
- package/src/lib/components/ChatComponents/InfoTab/infoTab.js +2 -2
- package/src/lib/components/ChatComponents/InfoTab/infoTab.stories.js +7 -7
- package/src/lib/components/ChatComponents/LabelAccordion/LabelAccordion.stories.js +5 -3
- package/src/lib/components/ChatComponents/NoteAccordion/NoteAccordion.js +2 -2
- package/src/lib/components/ChatComponents/NoteAccordion/NoteAccordion.stories.js +6 -5
- package/src/lib/components/Checkbox/checkboxToggler.js +89 -0
- package/src/lib/components/Checkbox/checkboxToggler.stories.js +48 -0
- package/src/lib/components/Lists/listBox.js +7 -7
- package/src/lib/components/Lists/listBox.stories.js +8 -11
- package/src/lib/components/Lists/listHeader.stories.js +13 -13
- package/src/lib/components/Lists/listheader.js +7 -7
- package/src/lib/components/Lists/rowLabels.js +6 -6
- package/src/lib/components/Lists/rowLabels.stories.js +18 -18
- package/src/lib/components/Loader/loader.js +13 -13
- package/src/lib/components/Loader/loader.stories.js +14 -14
- package/src/lib/components/MainWrapper/index.js +2 -2
- package/src/lib/components/MessageCounter/MessageCounter.stories.js +14 -14
- package/src/lib/components/MessageCounter/messageCounter.js +16 -16
- package/src/lib/components/Modals/modal.js +25 -23
- package/src/lib/components/Modals/modals.stories.js +9 -9
- package/src/lib/components/NoteBar/noteBar.js +20 -20
- package/src/lib/components/NoteBar/noteBar.stories.js +18 -17
- package/src/lib/components/PerformanceIndicator/performaceIndicator.stories.js +15 -15
- package/src/lib/components/PerformanceIndicator/performanceIndicator.js +11 -10
- package/src/lib/components/Pills/pills.js +16 -16
- package/src/lib/components/Pills/pills.stories.js +22 -23
- package/src/lib/components/ProfileIcon/ProfileIcon.js +50 -52
- package/src/lib/components/ProfileIcon/profileIcon.stories.js +22 -22
- package/src/lib/components/ProgressBar/progressbar.js +4 -5
- package/src/lib/components/ProgressBar/progressbar.stories.js +8 -9
- package/src/lib/components/ProgressRing/progressRing.js +25 -24
- package/src/lib/components/ProgressRing/progressRing.stories.js +18 -18
- package/src/lib/components/RouteLink/link.js +10 -8
- package/src/lib/components/RouteLink/link.stories.js +4 -4
- package/src/lib/components/ScrollBar/scrollBar.js +15 -14
- package/src/lib/components/SuperFluid/Content/index.js +2 -2
- package/src/lib/components/SuperFluid/ContentTitle.js/index.js +2 -2
- package/src/lib/components/SuperFluid/SegmentCard/index.js +9 -8
- package/src/lib/components/Tabs/tabs.js +11 -11
- package/src/lib/components/Tabs/tabs.stories.js +20 -20
- package/src/lib/components/Tags/tags.js +26 -24
- package/src/lib/components/Tags/tags.stories.js +19 -19
- package/src/lib/components/breakpoints.js +3 -3
- package/src/lib/components/checkbox.js +7 -6
- package/src/lib/components/colors.js +30 -28
- package/src/lib/components/dropdownButton.js +36 -39
- package/src/lib/components/examples/InfoAccordion.js +1 -1
- package/src/lib/components/globalStyles.js +2 -2
- package/src/lib/components/iconStyles.js +45 -48
- package/src/lib/components/index.js +47 -46
- package/src/lib/components/input.js +20 -20
- package/src/lib/components/text.js +1 -1
- package/src/lib/components/typography.js +14 -14
- package/src/reportWebVitals.js +1 -1
- package/babel.config.js +0 -12
- package/dist/components/checkboxToggler.js +0 -50
- package/src/lib/components/checkboxToggler.js +0 -19
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { KeyboardArrowDown } from
|
|
3
|
-
import styled from
|
|
4
|
-
import { BmBtnIcon } from
|
|
5
|
-
import { BmButton } from
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { KeyboardArrowDown } from '@material-ui/icons';
|
|
3
|
+
import styled from 'styled-components';
|
|
4
|
+
import { BmBtnIcon } from './Buttons/buttonIconsOnly';
|
|
5
|
+
import { BmButton } from './Buttons/buttons';
|
|
6
6
|
import {
|
|
7
7
|
BmPrimaryWhite,
|
|
8
8
|
BmPrimaryBlue,
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
BmSecondaryDarkGreen,
|
|
11
11
|
BmGrey400,
|
|
12
12
|
BmGrey100,
|
|
13
|
-
} from
|
|
13
|
+
} from './colors';
|
|
14
14
|
|
|
15
15
|
const Wrapper = styled.div`
|
|
16
16
|
display: flex;
|
|
@@ -21,51 +21,48 @@ const Wrapper = styled.div`
|
|
|
21
21
|
export const Drop = styled(BmBtnIcon)`
|
|
22
22
|
background: ${({ variant, disabled, color }) => {
|
|
23
23
|
if (!disabled) {
|
|
24
|
-
if (variant ===
|
|
25
|
-
if (variant ===
|
|
26
|
-
if (variant ===
|
|
27
|
-
if (variant ===
|
|
28
|
-
if (variant ===
|
|
29
|
-
if (variant ===
|
|
30
|
-
return `${color
|
|
31
|
-
} else {
|
|
32
|
-
if (variant === "primary") return `${BmGrey100}`;
|
|
33
|
-
if (variant === "secondary") return "none";
|
|
34
|
-
if (variant === "tertiary") return "none";
|
|
35
|
-
return `${BmGrey100}`;
|
|
24
|
+
if (variant === 'primary') return `${color || BmPrimaryBlue}`;
|
|
25
|
+
if (variant === 'secondary') return 'none';
|
|
26
|
+
if (variant === 'tertiary') return 'none';
|
|
27
|
+
if (variant === 'destructive') return `${BmSecondaryRed}`;
|
|
28
|
+
if (variant === 'success') return `${BmSecondaryDarkGreen}`;
|
|
29
|
+
if (variant === 'neutral') return `${BmPrimaryWhite}`;
|
|
30
|
+
return `${color || BmPrimaryBlue}`;
|
|
36
31
|
}
|
|
32
|
+
if (variant === 'primary') return `${BmGrey100}`;
|
|
33
|
+
if (variant === 'secondary') return 'none';
|
|
34
|
+
if (variant === 'tertiary') return 'none';
|
|
35
|
+
return `${BmGrey100}`;
|
|
37
36
|
}};
|
|
38
37
|
border: 0.071rem solid
|
|
39
38
|
${({ variant, disabled, color }) => {
|
|
40
39
|
if (!disabled) {
|
|
41
|
-
if (variant ===
|
|
42
|
-
if (variant ===
|
|
43
|
-
if (variant ===
|
|
44
|
-
if (variant ===
|
|
45
|
-
if (variant ===
|
|
46
|
-
if (variant ===
|
|
47
|
-
return `${color
|
|
48
|
-
} else {
|
|
49
|
-
if (variant === "primary") return `${BmGrey100}`;
|
|
50
|
-
if (variant === "secondary") return `${BmGrey400}`;
|
|
51
|
-
if (variant === "tertiary") return "transparent";
|
|
40
|
+
if (variant === 'primary') return `${color || BmPrimaryBlue}`;
|
|
41
|
+
if (variant === 'secondary') return `${color || BmPrimaryBlue}`;
|
|
42
|
+
if (variant === 'tertiary') return 'transparent';
|
|
43
|
+
if (variant === 'destructive') return `${BmSecondaryRed}`;
|
|
44
|
+
if (variant === 'success') return `${BmSecondaryDarkGreen}`;
|
|
45
|
+
if (variant === 'neutral') return `${BmGrey400}`;
|
|
46
|
+
return `${color || BmPrimaryBlue}`;
|
|
52
47
|
}
|
|
48
|
+
if (variant === 'primary') return `${BmGrey100}`;
|
|
49
|
+
if (variant === 'secondary') return `${BmGrey400}`;
|
|
50
|
+
if (variant === 'tertiary') return 'transparent';
|
|
53
51
|
}};
|
|
54
52
|
border-left: 0.071rem solid
|
|
55
53
|
${({ variant, disabled, color }) => {
|
|
56
54
|
if (!disabled) {
|
|
57
|
-
if (variant ===
|
|
58
|
-
if (variant ===
|
|
59
|
-
if (variant ===
|
|
60
|
-
if (variant ===
|
|
61
|
-
if (variant ===
|
|
62
|
-
if (variant ===
|
|
55
|
+
if (variant === 'primary') return `${BmPrimaryWhite}`;
|
|
56
|
+
if (variant === 'secondary') return `${color || BmPrimaryBlue}`;
|
|
57
|
+
if (variant === 'tertiary') return 'transparent';
|
|
58
|
+
if (variant === 'destructive') return `${BmSecondaryRed}`;
|
|
59
|
+
if (variant === 'success') return `${BmSecondaryDarkGreen}`;
|
|
60
|
+
if (variant === 'neutral') return `${BmGrey400}`;
|
|
63
61
|
return `${BmPrimaryWhite}`;
|
|
64
|
-
} else {
|
|
65
|
-
if (variant === "primary") return `${BmGrey400}`;
|
|
66
|
-
if (variant === "secondary") return `${BmGrey400}`;
|
|
67
|
-
if (variant === "tertiary") return "transparent";
|
|
68
62
|
}
|
|
63
|
+
if (variant === 'primary') return `${BmGrey400}`;
|
|
64
|
+
if (variant === 'secondary') return `${BmGrey400}`;
|
|
65
|
+
if (variant === 'tertiary') return 'transparent';
|
|
69
66
|
}};
|
|
70
67
|
border-top-left-radius: 0.071rem; */}
|
|
71
68
|
border-bottom-left-radius: 0.071rem; */}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { createGlobalStyle } from
|
|
2
|
-
import { h1, h2, h3, h4, h5, h6, p, input, a } from
|
|
1
|
+
import { createGlobalStyle } from 'styled-components';
|
|
2
|
+
import { h1, h2, h3, h4, h5, h6, p, input, a } from './text';
|
|
3
3
|
|
|
4
4
|
export const GlobalStyle = createGlobalStyle`
|
|
5
5
|
* { font-size: 14px; cursor: pointer}
|
|
@@ -1,23 +1,22 @@
|
|
|
1
|
-
import React from
|
|
1
|
+
import React from 'react';
|
|
2
2
|
|
|
3
|
-
import { withStyles } from
|
|
3
|
+
import { withStyles } from '@material-ui/core/styles';
|
|
4
|
+
import SvgIcon from '@material-ui/core/SvgIcon';
|
|
4
5
|
import {
|
|
5
6
|
BmPrimaryWhite,
|
|
6
7
|
BmPrimaryBlue,
|
|
7
8
|
BmGrey400,
|
|
8
9
|
BmPrimaryBlack,
|
|
9
10
|
BmSecondaryGrey,
|
|
10
|
-
} from
|
|
11
|
-
|
|
12
|
-
import SvgIcon from "@material-ui/core/SvgIcon";
|
|
11
|
+
} from './colors';
|
|
13
12
|
|
|
14
13
|
const size = (props) => {
|
|
15
|
-
if (props.size ===
|
|
16
|
-
if (props.size ===
|
|
17
|
-
if (props.size ===
|
|
18
|
-
if (props.size ===
|
|
19
|
-
if (props.size ===
|
|
20
|
-
if (!props.size) return
|
|
14
|
+
if (props.size === 'xsmall') return '1.143rem !important';
|
|
15
|
+
if (props.size === 'small') return '1.429rem !important';
|
|
16
|
+
if (props.size === 'medium') return '1.714rem !important';
|
|
17
|
+
if (props.size === 'large') return '1.714rem !important';
|
|
18
|
+
if (props.size === 'xlarge') return '2.286rem !important';
|
|
19
|
+
if (!props.size) return '1.714rem !important';
|
|
21
20
|
return props.size;
|
|
22
21
|
};
|
|
23
22
|
|
|
@@ -28,34 +27,32 @@ const ButtonIcon = {
|
|
|
28
27
|
width: (props) => size(props),
|
|
29
28
|
fill: ({ variant, disabled, color }) => {
|
|
30
29
|
if (!disabled) {
|
|
31
|
-
if (variant ===
|
|
32
|
-
if (variant ===
|
|
33
|
-
if (variant ===
|
|
34
|
-
if (variant ===
|
|
35
|
-
if (variant ===
|
|
36
|
-
if (variant ===
|
|
37
|
-
if (variant ===
|
|
38
|
-
if (variant ===
|
|
30
|
+
if (variant === 'active') return `${BmPrimaryWhite}`;
|
|
31
|
+
if (variant === 'enabled') return `${BmPrimaryBlack}`;
|
|
32
|
+
if (variant === 'destructive') return `${BmPrimaryWhite}`;
|
|
33
|
+
if (variant === 'success') return `${BmPrimaryWhite}`;
|
|
34
|
+
if (variant === 'neutral') return `${color || BmPrimaryBlue}`;
|
|
35
|
+
if (variant === 'primary') return `${BmPrimaryWhite}`;
|
|
36
|
+
if (variant === 'secondary') return `${color || BmPrimaryBlue}`;
|
|
37
|
+
if (variant === 'tertiary') return `${color || BmPrimaryBlue}`;
|
|
39
38
|
return `${BmPrimaryWhite}`;
|
|
40
|
-
} else {
|
|
41
|
-
return `${BmGrey400}`;
|
|
42
39
|
}
|
|
40
|
+
return `${BmGrey400}`;
|
|
43
41
|
},
|
|
44
42
|
color: ({ variant, disabled, color }) => {
|
|
45
43
|
if (color) return color;
|
|
46
44
|
if (!disabled) {
|
|
47
|
-
if (variant ===
|
|
48
|
-
if (variant ===
|
|
49
|
-
if (variant ===
|
|
50
|
-
if (variant ===
|
|
51
|
-
if (variant ===
|
|
52
|
-
if (variant ===
|
|
53
|
-
if (variant ===
|
|
54
|
-
if (variant ===
|
|
45
|
+
if (variant === 'active') return `${BmPrimaryWhite}`;
|
|
46
|
+
if (variant === 'enabled') return `${BmPrimaryBlack}`;
|
|
47
|
+
if (variant === 'destructive') return `${BmPrimaryWhite}`;
|
|
48
|
+
if (variant === 'success') return `${BmPrimaryWhite}`;
|
|
49
|
+
if (variant === 'neutral') return `${BmPrimaryBlue}`;
|
|
50
|
+
if (variant === 'primary') return `${BmPrimaryWhite}`;
|
|
51
|
+
if (variant === 'secondary') return `${color || BmPrimaryBlue}`;
|
|
52
|
+
if (variant === 'tertiary') return `${color || BmPrimaryBlue}`;
|
|
55
53
|
return `${BmPrimaryWhite}`;
|
|
56
|
-
} else {
|
|
57
|
-
return `${BmGrey400}`;
|
|
58
54
|
}
|
|
55
|
+
return `${BmGrey400}`;
|
|
59
56
|
},
|
|
60
57
|
},
|
|
61
58
|
};
|
|
@@ -71,13 +68,13 @@ export const BmButtonIcon = withStyles(ButtonIcon)((props) => {
|
|
|
71
68
|
// Tags
|
|
72
69
|
const TagIcon = {
|
|
73
70
|
root: {
|
|
74
|
-
height: (props) => size(props) ||
|
|
75
|
-
width: (props) => size(props) ||
|
|
71
|
+
height: (props) => size(props) || '1.143rem !important',
|
|
72
|
+
width: (props) => size(props) || '1.143rem !important',
|
|
76
73
|
fill: ({ variant, color }) => {
|
|
77
74
|
if (color) {
|
|
78
75
|
return color;
|
|
79
76
|
}
|
|
80
|
-
if (variant ===
|
|
77
|
+
if (variant === 'neutral' || variant === 'light')
|
|
81
78
|
return `${BmPrimaryBlack}`;
|
|
82
79
|
return `${BmPrimaryWhite}`;
|
|
83
80
|
},
|
|
@@ -85,7 +82,7 @@ const TagIcon = {
|
|
|
85
82
|
if (color) {
|
|
86
83
|
return color;
|
|
87
84
|
}
|
|
88
|
-
if (variant ===
|
|
85
|
+
if (variant === 'neutral' || variant === 'light')
|
|
89
86
|
return `${BmPrimaryBlack}`;
|
|
90
87
|
return `${BmPrimaryWhite}`;
|
|
91
88
|
},
|
|
@@ -101,11 +98,11 @@ export const BmTagIcon = withStyles(TagIcon)((props) => {
|
|
|
101
98
|
|
|
102
99
|
// Avatar Icons
|
|
103
100
|
const Avatarsize = (props) => {
|
|
104
|
-
if (props.size ===
|
|
105
|
-
if (props.size ===
|
|
106
|
-
if (props.size ===
|
|
107
|
-
if (props.size ===
|
|
108
|
-
if (!props.size) return
|
|
101
|
+
if (props.size === 'xsmall') return '0.857rem !important';
|
|
102
|
+
if (props.size === 'small') return '1.143rem !important';
|
|
103
|
+
if (props.size === 'medium') return '1.429rem !important';
|
|
104
|
+
if (props.size === 'large') return '2.286rem !important';
|
|
105
|
+
if (!props.size) return '2.286rem !important';
|
|
109
106
|
return props.size;
|
|
110
107
|
};
|
|
111
108
|
|
|
@@ -126,13 +123,13 @@ export const BmAvatarIcon = withStyles(AvatarIcon)((props) => {
|
|
|
126
123
|
return null;
|
|
127
124
|
});
|
|
128
125
|
|
|
129
|
-
//check on sizing
|
|
126
|
+
// check on sizing
|
|
130
127
|
export const BmChatbotIcon = withStyles(AvatarIcon)((props) => {
|
|
131
128
|
return (
|
|
132
129
|
<SvgIcon action {...props}>
|
|
133
130
|
<path
|
|
134
131
|
d="M19 8.975V6C19 5.46957 18.7893 4.96086 18.4142 4.58579C18.0391 4.21072 17.5304 4 17 4H11V2.688C11.305 2.414 11.5 2.02 11.5 1.578C11.5 1.18018 11.342 0.798647 11.0607 0.517343C10.7794 0.236038 10.3978 0.0780029 10 0.0780029C9.60218 0.0780029 9.22064 0.236038 8.93934 0.517343C8.65804 0.798647 8.5 1.18018 8.5 1.578C8.5 2.02 8.695 2.414 9 2.688V4H3C2.46957 4 1.96086 4.21072 1.58579 4.58579C1.21071 4.96086 1 5.46957 1 6V8.998L0.928 9.003C0.675888 9.02097 0.439955 9.13382 0.26775 9.31883C0.095544 9.50384 -0.000132994 9.74725 1.38752e-07 10V12C1.38752e-07 12.2652 0.105357 12.5196 0.292893 12.7071C0.48043 12.8946 0.734784 13 1 13V18C1 18.5304 1.21071 19.0391 1.58579 19.4142C1.96086 19.7893 2.46957 20 3 20H17C17.5304 20 18.0391 19.7893 18.4142 19.4142C18.7893 19.0391 19 18.5304 19 18V13C19.2652 13 19.5196 12.8946 19.7071 12.7071C19.8946 12.5196 20 12.2652 20 12V10.062C20.0116 9.90681 19.9869 9.75104 19.928 9.607C19.726 9.119 19.293 9.002 19 8.975ZM5 10C5 8.896 5.672 8 6.5 8C7.328 8 8 8.896 8 10C8 11.104 7.328 12 6.5 12C5.672 12 5 11.104 5 10ZM13.998 16C12.997 15.997 6.001 16 6 16V14C6 14 13.001 13.998 14.002 14L13.998 16ZM13.5 12C12.672 12 12 11.104 12 10C12 8.896 12.672 8 13.5 8C14.328 8 15 8.896 15 10C15 11.104 14.328 12 13.5 12Z"
|
|
135
|
-
fill={props.color ||
|
|
132
|
+
fill={props.color || 'white'}
|
|
136
133
|
/>
|
|
137
134
|
</SvgIcon>
|
|
138
135
|
);
|
|
@@ -144,7 +141,7 @@ const EmojiSize = () => {
|
|
|
144
141
|
// if (props.size === "small") return "1.429rem";
|
|
145
142
|
// if (props.size === "medium") return "1.714rem";
|
|
146
143
|
// if (props.size === "large") return "1.714rem";
|
|
147
|
-
return
|
|
144
|
+
return '2.286rem !important';
|
|
148
145
|
};
|
|
149
146
|
|
|
150
147
|
const EmojiIcon = {
|
|
@@ -169,7 +166,7 @@ export const BmQuickReplyIcon = withStyles(EmojiIcon)((props) => {
|
|
|
169
166
|
<SvgIcon action {...props}>
|
|
170
167
|
<path
|
|
171
168
|
d="M5.33332 23.3932V5.83317H26.6667V13.8332H29.3333V5.83317C29.3333 4.3665 28.1333 3.1665 26.6667 3.1665H5.33332C3.86666 3.1665 2.67999 4.3665 2.67999 5.83317L2.66666 29.8332L7.99999 24.4998H20V21.8332H6.89332L5.33332 23.3932Z"
|
|
172
|
-
fill={props.color ||
|
|
169
|
+
fill={props.color || '#575757'}
|
|
173
170
|
/>
|
|
174
171
|
</SvgIcon>
|
|
175
172
|
);
|
|
@@ -208,19 +205,19 @@ export const BmSupport = withStyles(icon)((props) => {
|
|
|
208
205
|
<SvgIcon action {...props}>
|
|
209
206
|
<path
|
|
210
207
|
d="M21 12.22C21 6.73 16.74 3 12 3C7.31 3 3 6.65 3 12.28C2.4 12.62 2 13.26 2 14V16C2 17.1 2.9 18 4 18H5V11.9C5 8.03 8.13 4.9 12 4.9C15.87 4.9 19 8.03 19 11.9V19H11V21H19C20.1 21 21 20.1 21 19V17.78C21.59 17.47 22 16.86 22 16.14V13.84C22 13.14 21.59 12.53 21 12.22Z"
|
|
211
|
-
fill={props.color ||
|
|
208
|
+
fill={props.color || 'black'}
|
|
212
209
|
/>
|
|
213
210
|
<path
|
|
214
211
|
d="M9 14C9.55228 14 10 13.5523 10 13C10 12.4477 9.55228 12 9 12C8.44772 12 8 12.4477 8 13C8 13.5523 8.44772 14 9 14Z"
|
|
215
|
-
fill={props.color ||
|
|
212
|
+
fill={props.color || 'black'}
|
|
216
213
|
/>
|
|
217
214
|
<path
|
|
218
215
|
d="M15 14C15.5523 14 16 13.5523 16 13C16 12.4477 15.5523 12 15 12C14.4477 12 14 12.4477 14 13C14 13.5523 14.4477 14 15 14Z"
|
|
219
|
-
fill={props.color ||
|
|
216
|
+
fill={props.color || 'black'}
|
|
220
217
|
/>
|
|
221
218
|
<path
|
|
222
219
|
d="M18 11.03C17.7615 9.62413 17.0334 8.34796 15.9444 7.42738C14.8555 6.5068 13.4759 6.00117 12.05 6C9.01997 6 5.75997 8.51 6.01997 12.45C7.2531 11.9454 8.34221 11.1435 9.1902 10.1158C10.0382 9.08808 10.6187 7.86652 10.88 6.56C12.19 9.19 14.88 11 18 11.03Z"
|
|
223
|
-
fill={props.color ||
|
|
220
|
+
fill={props.color || 'black'}
|
|
224
221
|
/>
|
|
225
222
|
</SvgIcon>
|
|
226
223
|
);
|
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
import BmAccordion from
|
|
2
|
-
import BmAvatar from
|
|
3
|
-
import { BmAlertIcon } from
|
|
4
|
-
import { BmBtnIcon } from
|
|
5
|
-
import { BmButton } from
|
|
6
|
-
import BmCard from
|
|
7
|
-
import { BmButtonDropDown } from
|
|
8
|
-
import { GlobalStyle } from
|
|
9
|
-
import { BmInput } from
|
|
10
|
-
import { BmRouteLink } from
|
|
11
|
-
import { BmListHeader } from
|
|
12
|
-
import { BmRowLabel } from
|
|
13
|
-
import { BmListBox } from
|
|
14
|
-
import BmModal from
|
|
15
|
-
import { BmProgressBar } from
|
|
16
|
-
import { BmTab } from
|
|
17
|
-
import * as BmColors from
|
|
18
|
-
import { BmLoader } from
|
|
19
|
-
import { BmCheckbox } from
|
|
20
|
-
import { BmTag } from
|
|
21
|
-
import BmBanner from
|
|
22
|
-
import BmProgressRing from
|
|
23
|
-
import {BmProfileIcon} from './ProfileIcon/ProfileIcon';
|
|
24
|
-
|
|
1
|
+
import BmAccordion from './Accordion/Accordion';
|
|
2
|
+
import BmAvatar from './Avatars/avatars';
|
|
3
|
+
import { BmAlertIcon } from './Buttons/buttonAlertIcons';
|
|
4
|
+
import { BmBtnIcon } from './Buttons/buttonIconsOnly';
|
|
5
|
+
import { BmButton } from './Buttons/buttons';
|
|
6
|
+
import BmCard from './Cards/cards';
|
|
7
|
+
import { BmButtonDropDown } from './dropdownButton';
|
|
8
|
+
import { GlobalStyle } from './globalStyles';
|
|
9
|
+
import { BmInput } from './input';
|
|
10
|
+
import { BmRouteLink } from './RouteLink/link';
|
|
11
|
+
import { BmListHeader } from './Lists/listheader';
|
|
12
|
+
import { BmRowLabel } from './Lists/rowLabels';
|
|
13
|
+
import { BmListBox } from './Lists/listBox';
|
|
14
|
+
import BmModal from './Modals/modal';
|
|
15
|
+
import { BmProgressBar } from './ProgressBar/progressbar';
|
|
16
|
+
import { BmTab } from './Tabs/tabs';
|
|
17
|
+
import * as BmColors from './colors';
|
|
18
|
+
import { BmLoader } from './Loader/loader';
|
|
19
|
+
import { BmCheckbox } from './checkbox';
|
|
20
|
+
import { BmTag } from './Tags/tags';
|
|
21
|
+
import BmBanner from './BannerCard/bannerCards';
|
|
22
|
+
import BmProgressRing from './ProgressRing/progressRing';
|
|
23
|
+
import { BmProfileIcon } from './ProfileIcon/ProfileIcon';
|
|
24
|
+
import { BmCheckboxToggle } from './Checkbox/checkboxToggler';
|
|
25
25
|
import {
|
|
26
26
|
BmTagIcon,
|
|
27
27
|
BmAvatarIcon,
|
|
@@ -31,30 +31,30 @@ import {
|
|
|
31
31
|
BmQuickReplyIcon,
|
|
32
32
|
BmSupport,
|
|
33
33
|
CopyToClipBoard,
|
|
34
|
-
} from
|
|
35
|
-
import { BmNoteBar } from
|
|
36
|
-
import { MainWrapper } from
|
|
34
|
+
} from './iconStyles';
|
|
35
|
+
import { BmNoteBar } from './NoteBar/noteBar';
|
|
36
|
+
import { MainWrapper } from './MainWrapper';
|
|
37
37
|
|
|
38
|
-
//Chat Components
|
|
39
|
-
import BmChat from
|
|
40
|
-
import { BmChatHeader } from
|
|
41
|
-
import BmContactCard from
|
|
42
|
-
import BmInfoTab from
|
|
43
|
-
import BmCounter from
|
|
44
|
-
//Chat Accordion components
|
|
45
|
-
import BmChatForm from
|
|
46
|
-
import BmChatLabels from
|
|
47
|
-
import BmChatNotes from
|
|
48
|
-
import { BmColorPicker } from
|
|
38
|
+
// Chat Components
|
|
39
|
+
import BmChat from './ChatComponents/ChatBody/chatBody';
|
|
40
|
+
import { BmChatHeader } from './ChatComponents/ChatHeader/chatHeader';
|
|
41
|
+
import BmContactCard from './ChatComponents/ContactCards/contactCards';
|
|
42
|
+
import BmInfoTab from './ChatComponents/InfoTab/infoTab';
|
|
43
|
+
import BmCounter from './MessageCounter/messageCounter';
|
|
44
|
+
// Chat Accordion components
|
|
45
|
+
import BmChatForm from './ChatComponents/FormAccordion/FormAccordion';
|
|
46
|
+
import BmChatLabels from './ChatComponents/LabelAccordion/LabelAccordion';
|
|
47
|
+
import BmChatNotes from './ChatComponents/NoteAccordion/NoteAccordion';
|
|
48
|
+
import { BmColorPicker } from './ChatComponents/ColorPicker/colorPicker';
|
|
49
49
|
|
|
50
|
-
//SuperFluid Components
|
|
51
|
-
import { BmContent } from
|
|
50
|
+
// SuperFluid Components
|
|
51
|
+
import { BmContent } from './SuperFluid/Content/index';
|
|
52
52
|
import {
|
|
53
53
|
BmContentFooter,
|
|
54
54
|
BmContentTitle,
|
|
55
55
|
BmFooterLeft,
|
|
56
56
|
BmFooterRight,
|
|
57
|
-
} from
|
|
57
|
+
} from './SuperFluid/ContentTitle.js';
|
|
58
58
|
import {
|
|
59
59
|
BmSegmentCard,
|
|
60
60
|
BmSegmentSelector,
|
|
@@ -63,7 +63,7 @@ import {
|
|
|
63
63
|
BmSegmentCompleteContent,
|
|
64
64
|
BmSegmentCompleteIcon,
|
|
65
65
|
BmSegmentCreateContent,
|
|
66
|
-
} from
|
|
66
|
+
} from './SuperFluid/SegmentCard/index';
|
|
67
67
|
|
|
68
68
|
export {
|
|
69
69
|
BmAccordion,
|
|
@@ -79,6 +79,7 @@ export {
|
|
|
79
79
|
BmBanner,
|
|
80
80
|
BmProgressRing,
|
|
81
81
|
BmProfileIcon,
|
|
82
|
+
BmCheckboxToggle,
|
|
82
83
|
// Fix height and if there is dropdown option inside the modal body
|
|
83
84
|
BmModal,
|
|
84
85
|
BmNoteBar,
|
|
@@ -93,7 +94,7 @@ export {
|
|
|
93
94
|
BmButtonDropDown,
|
|
94
95
|
BmCheckbox,
|
|
95
96
|
BmInput,
|
|
96
|
-
//Old SFL componets to be refactored
|
|
97
|
+
// Old SFL componets to be refactored
|
|
97
98
|
BmContent,
|
|
98
99
|
BmContentFooter,
|
|
99
100
|
BmContentTitle,
|
|
@@ -106,7 +107,7 @@ export {
|
|
|
106
107
|
BmSegmentCompleteContent,
|
|
107
108
|
BmSegmentCompleteIcon,
|
|
108
109
|
BmSegmentCreateContent,
|
|
109
|
-
//Icons (Remove unused ones and check on the sizing for custom icons)
|
|
110
|
+
// Icons (Remove unused ones and check on the sizing for custom icons)
|
|
110
111
|
BmAvatarIcon,
|
|
111
112
|
BmIcons,
|
|
112
113
|
BmTagIcon,
|
|
@@ -115,13 +116,13 @@ export {
|
|
|
115
116
|
BmQuickReplyIcon,
|
|
116
117
|
BmSupport,
|
|
117
118
|
CopyToClipBoard,
|
|
118
|
-
//Chat Components
|
|
119
|
+
// Chat Components
|
|
119
120
|
BmChatHeader,
|
|
120
121
|
BmChat,
|
|
121
122
|
BmInfoTab,
|
|
122
123
|
BmContactCard,
|
|
123
124
|
BmCounter,
|
|
124
|
-
//Chat Accordion Components
|
|
125
|
+
// Chat Accordion Components
|
|
125
126
|
BmChatForm,
|
|
126
127
|
BmChatLabels,
|
|
127
128
|
BmChatNotes,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Done, ErrorOutline } from
|
|
2
|
-
import React from
|
|
3
|
-
import styled from
|
|
4
|
-
import { BmIcons } from
|
|
1
|
+
import { Done, ErrorOutline } from '@material-ui/icons';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import styled from 'styled-components';
|
|
4
|
+
import { BmIcons } from './iconStyles';
|
|
5
5
|
import {
|
|
6
6
|
BmPrimaryWhite,
|
|
7
7
|
BmGrey400,
|
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
BmSecondaryDarkGreen,
|
|
14
14
|
BmSecondaryRed15,
|
|
15
15
|
BmGrey100,
|
|
16
|
-
} from
|
|
16
|
+
} from './colors';
|
|
17
17
|
|
|
18
18
|
const BmInputLabel = styled.div`
|
|
19
19
|
font-family: Open Sans;
|
|
@@ -25,7 +25,7 @@ const BmInputLabel = styled.div`
|
|
|
25
25
|
letter-spacing: -0.02em;
|
|
26
26
|
color: ${({ state }) => {
|
|
27
27
|
if (state) {
|
|
28
|
-
if (state ===
|
|
28
|
+
if (state === 'incomplete') return `${BmSecondaryRed}`;
|
|
29
29
|
return `${BmSecondaryGrey}`;
|
|
30
30
|
}
|
|
31
31
|
return `${BmSecondaryGrey}`;
|
|
@@ -38,7 +38,7 @@ export const BmInputField = styled.input`
|
|
|
38
38
|
letter-spacing: -0.02em;
|
|
39
39
|
color: ${({ state }) => {
|
|
40
40
|
if (state) {
|
|
41
|
-
if (state ===
|
|
41
|
+
if (state === 'disabled') return `${BmGrey400}`;
|
|
42
42
|
return `${BmPrimaryBlack}`;
|
|
43
43
|
}
|
|
44
44
|
return `${BmPrimaryBlack}`;
|
|
@@ -53,10 +53,10 @@ export const BmInputField = styled.input`
|
|
|
53
53
|
}
|
|
54
54
|
background: ${({ state }) => {
|
|
55
55
|
if (state) {
|
|
56
|
-
if (state ===
|
|
57
|
-
if (state ===
|
|
58
|
-
if (state ===
|
|
59
|
-
if (state ===
|
|
56
|
+
if (state === 'pressed') return `${BmGrey50}`; // TODO: to be reviewed
|
|
57
|
+
if (state === 'positive') return `${BmSecondaryGreen15}`;
|
|
58
|
+
if (state === 'negative') return `${BmSecondaryRed15}`;
|
|
59
|
+
if (state === 'disabled') return `${BmGrey100}`;
|
|
60
60
|
return `${BmPrimaryWhite}`;
|
|
61
61
|
}
|
|
62
62
|
return `${BmPrimaryWhite}`;
|
|
@@ -80,9 +80,9 @@ const BmInputWrapper = styled.div`
|
|
|
80
80
|
padding: 0rem;
|
|
81
81
|
background: ${({ state }) => {
|
|
82
82
|
if (state) {
|
|
83
|
-
if (state ===
|
|
84
|
-
if (state ===
|
|
85
|
-
if (state ===
|
|
83
|
+
if (state === 'pressed') return `${BmGrey50}`;
|
|
84
|
+
if (state === 'positive') return `${BmSecondaryGreen15}`;
|
|
85
|
+
if (state === 'disabled') return `${BmGrey100}`;
|
|
86
86
|
return `${BmPrimaryWhite}`;
|
|
87
87
|
}
|
|
88
88
|
return `${BmPrimaryWhite}`;
|
|
@@ -90,9 +90,9 @@ const BmInputWrapper = styled.div`
|
|
|
90
90
|
|
|
91
91
|
border: ${({ state }) => {
|
|
92
92
|
if (state) {
|
|
93
|
-
if (state ===
|
|
94
|
-
if (state ===
|
|
95
|
-
if (state ===
|
|
93
|
+
if (state === 'positive') return `0.071rem solid ${BmSecondaryDarkGreen}`;
|
|
94
|
+
if (state === 'negative') return `0.071rem solid ${BmSecondaryRed}`;
|
|
95
|
+
if (state === 'disabled') return `0.071rem solid ${BmGrey100}`;
|
|
96
96
|
return `0.071rem solid ${BmGrey400}`;
|
|
97
97
|
}
|
|
98
98
|
return `0.071rem solid ${BmGrey400}`;
|
|
@@ -113,12 +113,12 @@ export const BmInput = ({ id, iconSize, label, state, ...rest }) => {
|
|
|
113
113
|
id={id}
|
|
114
114
|
{...rest}
|
|
115
115
|
state={state}
|
|
116
|
-
disabled={state ===
|
|
116
|
+
disabled={state === 'disabled'}
|
|
117
117
|
/>
|
|
118
|
-
{state && state ===
|
|
118
|
+
{state && state === 'complete' && (
|
|
119
119
|
<BmIcons icon={<ErrorOutline />} size="small" />
|
|
120
120
|
)}
|
|
121
|
-
{state && state ===
|
|
121
|
+
{state && state === 'incomplete' && (
|
|
122
122
|
<BmIcons icon={<Done />} size="small" />
|
|
123
123
|
)}
|
|
124
124
|
</BmInputWrapper>
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
export const H1 =
|
|
2
|
-
export const H2 =
|
|
3
|
-
export const H3 =
|
|
4
|
-
export const H4 =
|
|
5
|
-
export const H5 =
|
|
6
|
-
export const H6 =
|
|
7
|
-
export const P =
|
|
1
|
+
export const H1 = '2.286rem';
|
|
2
|
+
export const H2 = '1.714rem';
|
|
3
|
+
export const H3 = '1.286rem';
|
|
4
|
+
export const H4 = '1.143rem';
|
|
5
|
+
export const H5 = '0.857rem';
|
|
6
|
+
export const H6 = '0.714rem';
|
|
7
|
+
export const P = '0.929rem';
|
|
8
8
|
|
|
9
|
-
export const QuoteMark =
|
|
10
|
-
export const PullQuote =
|
|
11
|
-
export const Captions =
|
|
12
|
-
export const Hero =
|
|
9
|
+
export const QuoteMark = '3.429rem';
|
|
10
|
+
export const PullQuote = '1.286rem';
|
|
11
|
+
export const Captions = '0.714rem';
|
|
12
|
+
export const Hero = '1rem';
|
|
13
13
|
|
|
14
|
-
export const PoppinsMedium =
|
|
15
|
-
export const Poppins =
|
|
16
|
-
export const OpenSans =
|
|
14
|
+
export const PoppinsMedium = 'PoppinsMedium';
|
|
15
|
+
export const Poppins = 'Poppins';
|
|
16
|
+
export const OpenSans = 'OpenSans';
|
package/src/reportWebVitals.js
CHANGED