@zohodesk/dot 1.0.0-temp-224.1 → 1.0.0-temp-187.22
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/README.md +11 -6
- package/es/form/fields/CheckBoxField/__tests__/__snapshots__/CheckBoxField.spec.js.snap +21 -18
- package/es/form/fields/Fields.module.css +4 -1
- package/es/form/fields/TagsMultiSelect/TagsMultiSelect.js +10 -6
- package/es/form/fields/TagsMultiSelect/props/propTypes.js +2 -1
- package/es/list/DepartmentDropDown/DepartmentDropDown.js +6 -2
- package/es/list/DepartmentDropDown/__tests__/__snapshots__/DepartmentDropDown.spec.js.snap +1 -1
- package/es/list/DepartmentDropDown/props/defaultProps.js +2 -1
- package/es/list/DepartmentDropDown/props/propTypes.js +3 -0
- package/es/list/SecondaryText/AccountName.js +23 -8
- package/es/list/SecondaryText/ContactName.js +18 -6
- package/es/list/SecondaryText/DepartmentText.js +13 -6
- package/es/list/SecondaryText/Email.js +19 -7
- package/es/list/SecondaryText/PhoneNumber.js +19 -7
- package/es/list/SecondaryText/PriorityText.js +13 -6
- package/es/list/SecondaryText/SecondaryText.js +17 -8
- package/es/list/SecondaryText/SecondaryText.module.css +40 -24
- package/es/list/SecondaryText/StatusText.js +13 -6
- package/es/list/SecondaryText/TicketId.js +8 -2
- package/es/list/SecondaryText/Website.js +16 -5
- package/es/list/SecondaryText/__tests__/__snapshots__/AccountName.spec.js.snap +1 -1
- package/es/list/SecondaryText/__tests__/__snapshots__/ContactName.spec.js.snap +1 -1
- package/es/list/SecondaryText/__tests__/__snapshots__/DepartmentText.spec.js.snap +1 -1
- package/es/list/SecondaryText/__tests__/__snapshots__/Email.spec.js.snap +1 -1
- package/es/list/SecondaryText/__tests__/__snapshots__/PhoneNumber.spec.js.snap +1 -1
- package/es/list/SecondaryText/__tests__/__snapshots__/PriorityText.spec.js.snap +1 -1
- package/es/list/SecondaryText/__tests__/__snapshots__/SecondaryText.spec.js.snap +1 -1
- package/es/list/SecondaryText/__tests__/__snapshots__/StatusText.spec.js.snap +1 -1
- package/es/list/SecondaryText/__tests__/__snapshots__/Website.spec.js.snap +6 -2
- package/es/list/SecondaryText/props/defaultProps.js +18 -0
- package/es/list/SecondaryText/props/propTypes.js +21 -0
- package/es/list/Subject/Subject.js +28 -12
- package/es/list/Subject/__tests__/__snapshots__/Subject.spec.js.snap +14 -14
- package/es/list/Subject/props/defaultProps.js +3 -1
- package/es/list/Subject/props/propTypes.js +5 -1
- package/es/list/status/StatusDropdown/StatusDropdown.js +7 -2
- package/es/list/status/StatusDropdown/props/defaultProps.js +2 -1
- package/es/list/status/StatusDropdown/props/propTypes.js +4 -1
- package/es/list/status/StatusListItem/StatusListItem.js +4 -2
- package/es/list/status/StatusListItem/StatusListItem.module.css +43 -17
- package/lib/form/fields/CheckBoxField/__tests__/__snapshots__/CheckBoxField.spec.js.snap +21 -18
- package/lib/form/fields/Fields.module.css +4 -1
- package/lib/form/fields/TagsMultiSelect/TagsMultiSelect.js +12 -7
- package/lib/form/fields/TagsMultiSelect/props/propTypes.js +2 -1
- package/lib/list/DepartmentDropDown/DepartmentDropDown.js +8 -3
- package/lib/list/DepartmentDropDown/__tests__/__snapshots__/DepartmentDropDown.spec.js.snap +1 -1
- package/lib/list/DepartmentDropDown/props/defaultProps.js +2 -1
- package/lib/list/DepartmentDropDown/props/propTypes.js +2 -0
- package/lib/list/SecondaryText/AccountName.js +27 -8
- package/lib/list/SecondaryText/ContactName.js +21 -6
- package/lib/list/SecondaryText/DepartmentText.js +15 -6
- package/lib/list/SecondaryText/Email.js +22 -7
- package/lib/list/SecondaryText/PhoneNumber.js +22 -7
- package/lib/list/SecondaryText/PriorityText.js +15 -6
- package/lib/list/SecondaryText/SecondaryText.js +26 -8
- package/lib/list/SecondaryText/SecondaryText.module.css +40 -24
- package/lib/list/SecondaryText/StatusText.js +15 -6
- package/lib/list/SecondaryText/TicketId.js +10 -2
- package/lib/list/SecondaryText/Website.js +18 -5
- package/lib/list/SecondaryText/__tests__/__snapshots__/AccountName.spec.js.snap +1 -1
- package/lib/list/SecondaryText/__tests__/__snapshots__/ContactName.spec.js.snap +1 -1
- package/lib/list/SecondaryText/__tests__/__snapshots__/DepartmentText.spec.js.snap +1 -1
- package/lib/list/SecondaryText/__tests__/__snapshots__/Email.spec.js.snap +1 -1
- package/lib/list/SecondaryText/__tests__/__snapshots__/PhoneNumber.spec.js.snap +1 -1
- package/lib/list/SecondaryText/__tests__/__snapshots__/PriorityText.spec.js.snap +1 -1
- package/lib/list/SecondaryText/__tests__/__snapshots__/SecondaryText.spec.js.snap +1 -1
- package/lib/list/SecondaryText/__tests__/__snapshots__/StatusText.spec.js.snap +1 -1
- package/lib/list/SecondaryText/__tests__/__snapshots__/Website.spec.js.snap +6 -2
- package/lib/list/SecondaryText/props/defaultProps.js +18 -0
- package/lib/list/SecondaryText/props/propTypes.js +22 -0
- package/lib/list/Subject/Subject.js +40 -13
- package/lib/list/Subject/__tests__/__snapshots__/Subject.spec.js.snap +14 -14
- package/lib/list/Subject/props/defaultProps.js +3 -1
- package/lib/list/Subject/props/propTypes.js +6 -1
- package/lib/list/status/StatusDropdown/StatusDropdown.js +6 -2
- package/lib/list/status/StatusDropdown/props/defaultProps.js +2 -1
- package/lib/list/status/StatusDropdown/props/propTypes.js +3 -1
- package/lib/list/status/StatusListItem/StatusListItem.js +4 -2
- package/lib/list/status/StatusListItem/StatusListItem.module.css +43 -17
- package/package.json +4 -4
|
@@ -8,109 +8,120 @@
|
|
|
8
8
|
}[dir=rtl] .paidUserIcon {
|
|
9
9
|
margin-left: var(--zd_size5) ;
|
|
10
10
|
}
|
|
11
|
+
|
|
11
12
|
.icon {
|
|
12
13
|
display: block;
|
|
13
14
|
}
|
|
15
|
+
|
|
14
16
|
.disable {
|
|
15
17
|
cursor: not-allowed;
|
|
16
18
|
}
|
|
19
|
+
|
|
17
20
|
.textBold {
|
|
18
21
|
font-weight: var(--zd-fw-bold);
|
|
19
22
|
color: var(--zdt_secondaryText_black_text);
|
|
20
23
|
}
|
|
21
|
-
|
|
24
|
+
|
|
25
|
+
.link {
|
|
22
26
|
display: block
|
|
23
27
|
}
|
|
24
|
-
|
|
25
|
-
font-weight: var(--zd-fw-bold);
|
|
26
|
-
color: var(--zdt_secondaryText_black_text);
|
|
27
|
-
}
|
|
28
|
+
|
|
28
29
|
.ticketId,
|
|
29
30
|
.link,
|
|
30
|
-
.textStyle,
|
|
31
31
|
.secondaryText,
|
|
32
32
|
.ratingText,
|
|
33
33
|
.phoneNumber {
|
|
34
34
|
color: var(--zdt_secondaryText_secondaryText_text);
|
|
35
35
|
}
|
|
36
|
-
|
|
37
|
-
.secondaryText {
|
|
38
|
-
font-size: var(--zd_font_size12) ;
|
|
39
|
-
}
|
|
36
|
+
|
|
40
37
|
.ticketId,
|
|
41
|
-
.phoneNumber,
|
|
42
38
|
.ratingText {
|
|
43
39
|
font-size: var(--zd_font_size12) ;
|
|
44
40
|
}
|
|
45
|
-
|
|
41
|
+
|
|
42
|
+
.linkWithText {
|
|
43
|
+
color: var(--zdt_secondaryText_secondaryText_text);
|
|
44
|
+
max-width: 100% ;
|
|
45
|
+
cursor: pointer;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.linkWithText:hover {
|
|
49
|
+
color: var(--zdt_secondaryText_blue_text);
|
|
50
|
+
}
|
|
51
|
+
|
|
46
52
|
.secondaryText,
|
|
47
53
|
.phoneNumber {
|
|
48
|
-
composes: dotted from '~@zohodesk/components/es/common/common.module.css';
|
|
49
54
|
max-width: 100% ;
|
|
50
|
-
display: block;
|
|
51
55
|
}
|
|
52
|
-
|
|
56
|
+
|
|
57
|
+
.secondaryText, .phoneNumber {
|
|
53
58
|
cursor: pointer;
|
|
54
59
|
}
|
|
55
|
-
|
|
60
|
+
|
|
56
61
|
.ticketIdLink,
|
|
57
62
|
.phoneNumber:hover,
|
|
58
63
|
.link:hover {
|
|
59
64
|
color: var(--zdt_secondaryText_blue_text);
|
|
60
65
|
}
|
|
66
|
+
|
|
61
67
|
/* .link:focus, .link:focus .textStyle, .link:focus .phoneNumber{
|
|
62
68
|
color: var(--zdt_secondaryText_blue_text);
|
|
63
69
|
} */
|
|
64
70
|
.ticketIdLink {
|
|
65
71
|
cursor: pointer;
|
|
66
72
|
}
|
|
67
|
-
|
|
73
|
+
|
|
74
|
+
.ticketIdLink:hover,
|
|
75
|
+
.ticketIdLink:focus {
|
|
68
76
|
color: var(--zdt_secondaryText_blue_hover_text);
|
|
69
77
|
}
|
|
78
|
+
|
|
70
79
|
.primaryAccountNameCnt {
|
|
71
80
|
max-width: 100% ;
|
|
72
81
|
}
|
|
82
|
+
|
|
73
83
|
/* status */
|
|
74
84
|
.font_regular {
|
|
75
85
|
font-weight: var(--zd-fw-normal);
|
|
76
86
|
}
|
|
87
|
+
|
|
77
88
|
.font_semibold {
|
|
78
89
|
font-weight: var(--zd-fw-semibold);
|
|
79
90
|
}
|
|
91
|
+
|
|
80
92
|
.font_bold {
|
|
81
93
|
font-weight: var(--zd-fw-bold);
|
|
82
94
|
}
|
|
95
|
+
|
|
83
96
|
.font_semibold,
|
|
84
97
|
.font_bold,
|
|
85
98
|
.textBold {
|
|
86
99
|
composes: ftsmooth from '~@zohodesk/components/es/common/common.module.css';
|
|
87
100
|
}
|
|
88
|
-
.priorityText,
|
|
89
|
-
.statusText {
|
|
90
|
-
composes: dotted from '~@zohodesk/components/es/common/common.module.css';
|
|
91
|
-
}
|
|
92
101
|
|
|
93
102
|
.priorityText {
|
|
94
|
-
font-size: var(--zd_font_size12) ;
|
|
95
103
|
max-width: 100% ;
|
|
96
104
|
}
|
|
105
|
+
|
|
97
106
|
.departmentText {
|
|
98
|
-
font-size: var(--zd_font_size12) ;
|
|
99
107
|
color: var(--zdt_secondaryText_secondaryText_text);
|
|
100
108
|
max-width: 100% ;
|
|
101
|
-
composes: dotted from '~@zohodesk/components/es/common/common.module.css';
|
|
102
109
|
}
|
|
110
|
+
|
|
103
111
|
/* HappinessRating Style */
|
|
104
112
|
.happinessContainer {
|
|
105
113
|
composes: inlineBlockMiddle from '../listCommon.module.css';
|
|
106
114
|
}
|
|
115
|
+
|
|
107
116
|
.happinessImg {
|
|
108
117
|
width: var(--zd_size13) ;
|
|
109
118
|
vertical-align: middle;
|
|
110
119
|
}
|
|
120
|
+
|
|
111
121
|
[dir=ltr] .happinessImg {
|
|
112
122
|
margin: 0 var(--zd_size4) 0 0 ;
|
|
113
123
|
}
|
|
124
|
+
|
|
114
125
|
[dir=rtl] .happinessImg {
|
|
115
126
|
margin: 0 0 0 var(--zd_size4) ;
|
|
116
127
|
}
|
|
@@ -119,18 +130,23 @@
|
|
|
119
130
|
.gray {
|
|
120
131
|
color: var(--zdt_secondaryText_gray_text);
|
|
121
132
|
}
|
|
133
|
+
|
|
122
134
|
.orange {
|
|
123
135
|
color: var(--zdt_secondaryText_orage_text);
|
|
124
136
|
}
|
|
137
|
+
|
|
125
138
|
.green {
|
|
126
139
|
color: var(--zdt_secondaryText_green_text);
|
|
127
140
|
}
|
|
141
|
+
|
|
128
142
|
.red {
|
|
129
143
|
color: var(--zdt_secondaryText_red_text);
|
|
130
144
|
}
|
|
145
|
+
|
|
131
146
|
.blue {
|
|
132
147
|
color: var(--zdt_secondaryText_blue_text);
|
|
133
148
|
}
|
|
149
|
+
|
|
134
150
|
.black {
|
|
135
151
|
color: var(--zdt_secondaryText_black_text);
|
|
136
152
|
}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import { StatusText_defaultProps } from "./props/defaultProps";
|
|
3
3
|
import { StatusText_propTypes } from "./props/propTypes";
|
|
4
|
+
import Typography from '@zohodesk/components/es/Typography/Typography';
|
|
5
|
+
import { DUMMY_OBJECT } from '@zohodesk/components/es/utils/Common';
|
|
4
6
|
import style from "./SecondaryText.module.css";
|
|
5
7
|
export default class StatusText extends Component {
|
|
6
8
|
constructor(props) {
|
|
@@ -14,13 +16,18 @@ export default class StatusText extends Component {
|
|
|
14
16
|
text,
|
|
15
17
|
dataTitle,
|
|
16
18
|
fontWeight,
|
|
17
|
-
dataId
|
|
19
|
+
dataId,
|
|
20
|
+
isHighlighted,
|
|
21
|
+
highlightData
|
|
18
22
|
} = this.props;
|
|
19
|
-
return /*#__PURE__*/React.createElement(
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
23
|
+
return /*#__PURE__*/React.createElement(Typography, {
|
|
24
|
+
$ui_className: `${style[color]} ${className ? className : ''}`,
|
|
25
|
+
$ui_weight: fontWeight,
|
|
26
|
+
$flag_dotted: true,
|
|
27
|
+
$ui_highlightConfig: isHighlighted ? highlightData : DUMMY_OBJECT,
|
|
28
|
+
$i18n_dataTitle: dataTitle,
|
|
29
|
+
customId: dataId,
|
|
30
|
+
testId: dataId
|
|
24
31
|
}, text);
|
|
25
32
|
}
|
|
26
33
|
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import { TicketId_defaultProps } from "./props/defaultProps";
|
|
3
3
|
import { TicketId_propTypes } from "./props/propTypes";
|
|
4
|
+
import Typography from '@zohodesk/components/es/Typography/Typography';
|
|
5
|
+
import { DUMMY_OBJECT } from '@zohodesk/components/es/utils/Common';
|
|
4
6
|
import Link from "../../Link/Link";
|
|
5
7
|
import style from "./SecondaryText.module.css";
|
|
6
8
|
export default class TicketId extends Component {
|
|
@@ -20,7 +22,9 @@ export default class TicketId extends Component {
|
|
|
20
22
|
target,
|
|
21
23
|
urlName,
|
|
22
24
|
urlData,
|
|
23
|
-
customProps
|
|
25
|
+
customProps,
|
|
26
|
+
isHighlighted,
|
|
27
|
+
highlightData
|
|
24
28
|
} = this.props;
|
|
25
29
|
let {
|
|
26
30
|
LinkProps = {},
|
|
@@ -40,7 +44,9 @@ export default class TicketId extends Component {
|
|
|
40
44
|
target: target,
|
|
41
45
|
onClick: onClick,
|
|
42
46
|
...LinkProps
|
|
43
|
-
},
|
|
47
|
+
}, /*#__PURE__*/React.createElement(Typography, {
|
|
48
|
+
$ui_highlightConfig: isHighlighted ? highlightData : DUMMY_OBJECT
|
|
49
|
+
}, text)) : text);
|
|
44
50
|
}
|
|
45
51
|
|
|
46
52
|
}
|
|
@@ -6,6 +6,8 @@ import { Website_defaultProps } from "./props/defaultProps";
|
|
|
6
6
|
import { Website_propTypes } from "./props/propTypes";
|
|
7
7
|
/**** Components ****/
|
|
8
8
|
|
|
9
|
+
import Typography from '@zohodesk/components/es/Typography/Typography';
|
|
10
|
+
import { DUMMY_OBJECT } from '@zohodesk/components/es/utils/Common';
|
|
9
11
|
import ExternalLink from "../../ExternalLink/ExternalLink";
|
|
10
12
|
/**** CSS ****/
|
|
11
13
|
|
|
@@ -19,17 +21,26 @@ export default class Website extends Component {
|
|
|
19
21
|
href,
|
|
20
22
|
dataId,
|
|
21
23
|
isLink,
|
|
22
|
-
target
|
|
24
|
+
target,
|
|
25
|
+
isHighlighted,
|
|
26
|
+
highlightData
|
|
23
27
|
} = this.props;
|
|
24
28
|
return /*#__PURE__*/React.createElement(React.Fragment, null, isLink ? /*#__PURE__*/React.createElement(ExternalLink, {
|
|
25
|
-
className:
|
|
29
|
+
className: style.link,
|
|
26
30
|
href: href,
|
|
27
31
|
title: title,
|
|
28
32
|
dataId: dataId,
|
|
29
33
|
target: target
|
|
30
|
-
},
|
|
31
|
-
|
|
32
|
-
"
|
|
34
|
+
}, /*#__PURE__*/React.createElement(Typography, {
|
|
35
|
+
$flag_dotted: true,
|
|
36
|
+
$ui_size: "12",
|
|
37
|
+
$ui_className: `${style.linkWithText} ${className ? className : ''}`,
|
|
38
|
+
$ui_highlightConfig: isHighlighted ? highlightData : DUMMY_OBJECT
|
|
39
|
+
}, text)) : /*#__PURE__*/React.createElement(Typography, {
|
|
40
|
+
$ui_size: "12",
|
|
41
|
+
$flag_dotted: true,
|
|
42
|
+
$ui_className: `${style.secondaryText} ${className ? className : ''}`,
|
|
43
|
+
$i18n_dataTitle: text
|
|
33
44
|
}, text));
|
|
34
45
|
}
|
|
35
46
|
|
|
@@ -3,10 +3,14 @@
|
|
|
3
3
|
exports[`Website rendering the defult props 1`] = `
|
|
4
4
|
<DocumentFragment>
|
|
5
5
|
<a
|
|
6
|
-
class="link
|
|
6
|
+
class="link link"
|
|
7
7
|
href="javascript:void(0);"
|
|
8
8
|
rel="noopener noreferrer"
|
|
9
9
|
target="_blank"
|
|
10
|
-
|
|
10
|
+
>
|
|
11
|
+
<div
|
|
12
|
+
class="dotted size12 linkWithText "
|
|
13
|
+
/>
|
|
14
|
+
</a>
|
|
11
15
|
</DocumentFragment>
|
|
12
16
|
`;
|
|
@@ -2,6 +2,8 @@ export const AccountName_defaultProps = {
|
|
|
2
2
|
isLink: true,
|
|
3
3
|
dataId: 'accountName',
|
|
4
4
|
fontWeight: 'regular',
|
|
5
|
+
isHighlighted: false,
|
|
6
|
+
highlightData: {},
|
|
5
7
|
customProps: {}
|
|
6
8
|
};
|
|
7
9
|
export const ContactName_defaultProps = {
|
|
@@ -10,35 +12,51 @@ export const ContactName_defaultProps = {
|
|
|
10
12
|
dataId: 'contactName',
|
|
11
13
|
fontWeight: 'regular',
|
|
12
14
|
i18nKeys: {},
|
|
15
|
+
isHighlighted: false,
|
|
16
|
+
highlightData: {},
|
|
13
17
|
customProps: {}
|
|
14
18
|
};
|
|
15
19
|
export const Email_defaultProps = {
|
|
16
20
|
isLink: true,
|
|
17
21
|
fontWeight: 'regular',
|
|
22
|
+
isHighlighted: false,
|
|
23
|
+
highlightData: {},
|
|
18
24
|
customProps: {}
|
|
19
25
|
};
|
|
20
26
|
export const PhoneNumber_defaultProps = {
|
|
21
27
|
isLink: true,
|
|
22
28
|
hasReload: false,
|
|
23
29
|
fontWeight: 'regular',
|
|
30
|
+
isHighlighted: false,
|
|
31
|
+
highlightData: {},
|
|
24
32
|
customProps: {}
|
|
25
33
|
};
|
|
26
34
|
export const PriorityText_defaultProps = {
|
|
27
35
|
color: 'black',
|
|
36
|
+
isHighlighted: false,
|
|
37
|
+
highlightData: {},
|
|
28
38
|
dataId: 'priority'
|
|
29
39
|
};
|
|
30
40
|
export const SecondaryText_defaultProps = {
|
|
41
|
+
isHighlighted: false,
|
|
42
|
+
highlightData: {},
|
|
31
43
|
customProps: {}
|
|
32
44
|
};
|
|
33
45
|
export const StatusText_defaultProps = {
|
|
34
46
|
color: 'black',
|
|
35
47
|
dataId: 'statusContainer',
|
|
48
|
+
isHighlighted: false,
|
|
49
|
+
highlightData: {},
|
|
36
50
|
fontWeight: 'regular'
|
|
37
51
|
};
|
|
38
52
|
export const TicketId_defaultProps = {
|
|
39
53
|
dataId: 'ticketId',
|
|
54
|
+
isHighlighted: false,
|
|
55
|
+
highlightData: {},
|
|
40
56
|
customProps: {}
|
|
41
57
|
};
|
|
42
58
|
export const Website_defaultProps = {
|
|
59
|
+
isHighlighted: false,
|
|
60
|
+
highlightData: {},
|
|
43
61
|
isLink: true
|
|
44
62
|
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import PropTypes from 'prop-types';
|
|
2
|
+
import { propTypes as typographyProps } from '@zohodesk/components/es/Typography/props/propTypes';
|
|
2
3
|
export const AccountName_propTypes = {
|
|
3
4
|
className: PropTypes.string,
|
|
4
5
|
dataId: PropTypes.string,
|
|
@@ -14,6 +15,8 @@ export const AccountName_propTypes = {
|
|
|
14
15
|
secondaryAccountHref: PropTypes.string,
|
|
15
16
|
secondaryAccountClick: PropTypes.func,
|
|
16
17
|
secondaryAccountText: PropTypes.string,
|
|
18
|
+
isHighlighted: PropTypes.bool,
|
|
19
|
+
highlightData: typographyProps.$ui_highlightConfig,
|
|
17
20
|
customProps: PropTypes.shape({
|
|
18
21
|
LinkProps: PropTypes.object,
|
|
19
22
|
TextProps: PropTypes.object,
|
|
@@ -42,6 +45,8 @@ export const ContactName_propTypes = {
|
|
|
42
45
|
}),
|
|
43
46
|
paidTitle: PropTypes.string
|
|
44
47
|
}),
|
|
48
|
+
isHighlighted: PropTypes.bool,
|
|
49
|
+
highlightData: typographyProps.$ui_highlightConfig,
|
|
45
50
|
customProps: PropTypes.shape({
|
|
46
51
|
LinkProps: PropTypes.object,
|
|
47
52
|
TextProps: PropTypes.object
|
|
@@ -51,6 +56,8 @@ export const DepartmentText_propTypes = {
|
|
|
51
56
|
className: PropTypes.string,
|
|
52
57
|
dataId: PropTypes.string,
|
|
53
58
|
dataTitle: PropTypes.string,
|
|
59
|
+
isHighlighted: PropTypes.bool,
|
|
60
|
+
highlightData: typographyProps.$ui_highlightConfig,
|
|
54
61
|
text: PropTypes.string
|
|
55
62
|
};
|
|
56
63
|
export const Email_propTypes = {
|
|
@@ -63,6 +70,8 @@ export const Email_propTypes = {
|
|
|
63
70
|
title: PropTypes.string,
|
|
64
71
|
urlData: PropTypes.object,
|
|
65
72
|
urlName: PropTypes.string,
|
|
73
|
+
isHighlighted: PropTypes.bool,
|
|
74
|
+
highlightData: typographyProps.$ui_highlightConfig,
|
|
66
75
|
customProps: PropTypes.shape({
|
|
67
76
|
LinkProps: PropTypes.object,
|
|
68
77
|
TextProps: PropTypes.object
|
|
@@ -85,6 +94,8 @@ export const PhoneNumber_propTypes = {
|
|
|
85
94
|
title: PropTypes.string,
|
|
86
95
|
urlData: PropTypes.object,
|
|
87
96
|
urlName: PropTypes.string,
|
|
97
|
+
isHighlighted: PropTypes.bool,
|
|
98
|
+
highlightData: typographyProps.$ui_highlightConfig,
|
|
88
99
|
customProps: PropTypes.shape({
|
|
89
100
|
LinkProps: PropTypes.object,
|
|
90
101
|
TextProps: PropTypes.object
|
|
@@ -95,6 +106,8 @@ export const PriorityText_propTypes = {
|
|
|
95
106
|
color: PropTypes.oneOf(['red', 'green', 'gray', 'orange']),
|
|
96
107
|
dataId: PropTypes.string,
|
|
97
108
|
dataTitle: PropTypes.string,
|
|
109
|
+
isHighlighted: PropTypes.bool,
|
|
110
|
+
highlightData: typographyProps.$ui_highlightConfig,
|
|
98
111
|
text: PropTypes.string
|
|
99
112
|
};
|
|
100
113
|
export const SecondaryText_propTypes = {
|
|
@@ -103,6 +116,8 @@ export const SecondaryText_propTypes = {
|
|
|
103
116
|
dataTitle: PropTypes.string,
|
|
104
117
|
onClick: PropTypes.func,
|
|
105
118
|
text: PropTypes.string,
|
|
119
|
+
isHighlighted: PropTypes.bool,
|
|
120
|
+
highlightData: typographyProps.$ui_highlightConfig,
|
|
106
121
|
customProps: PropTypes.shape({
|
|
107
122
|
SecondaryTextProps: PropTypes.object
|
|
108
123
|
})
|
|
@@ -113,6 +128,8 @@ export const StatusText_propTypes = {
|
|
|
113
128
|
dataId: PropTypes.string,
|
|
114
129
|
dataTitle: PropTypes.string,
|
|
115
130
|
fontWeight: PropTypes.oneOf(['regular', 'semibold', 'bold']),
|
|
131
|
+
isHighlighted: PropTypes.bool,
|
|
132
|
+
highlightData: typographyProps.$ui_highlightConfig,
|
|
116
133
|
text: PropTypes.string
|
|
117
134
|
};
|
|
118
135
|
export const TicketId_propTypes = {
|
|
@@ -126,6 +143,8 @@ export const TicketId_propTypes = {
|
|
|
126
143
|
url: PropTypes.string,
|
|
127
144
|
urlData: PropTypes.string,
|
|
128
145
|
urlName: PropTypes.string,
|
|
146
|
+
isHighlighted: PropTypes.bool,
|
|
147
|
+
highlightData: typographyProps.$ui_highlightConfig,
|
|
129
148
|
customProps: PropTypes.shape({
|
|
130
149
|
TicketIdProps: PropTypes.object,
|
|
131
150
|
LinkProps: PropTypes.object
|
|
@@ -138,5 +157,7 @@ export const Website_propTypes = {
|
|
|
138
157
|
isLink: PropTypes.bool,
|
|
139
158
|
target: PropTypes.string,
|
|
140
159
|
text: PropTypes.string,
|
|
160
|
+
isHighlighted: PropTypes.bool,
|
|
161
|
+
highlightData: typographyProps.$ui_highlightConfig,
|
|
141
162
|
title: PropTypes.string
|
|
142
163
|
};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import { defaultProps } from "./props/defaultProps";
|
|
3
3
|
import { propTypes } from "./props/propTypes";
|
|
4
|
+
import Typography from '@zohodesk/components/es/Typography/Typography';
|
|
5
|
+
import { DUMMY_OBJECT } from '@zohodesk/components/es/utils/Common';
|
|
4
6
|
import Link from "../../Link/Link";
|
|
5
7
|
import { whiteSpaceClassMapping } from '@zohodesk/components/es/utils/cssUtils';
|
|
6
8
|
import style from "./Subject.module.css";
|
|
@@ -24,30 +26,44 @@ export default class Subject extends Component {
|
|
|
24
26
|
isDotted,
|
|
25
27
|
children,
|
|
26
28
|
customProps,
|
|
27
|
-
whiteSpace
|
|
29
|
+
whiteSpace,
|
|
30
|
+
isHighlighted,
|
|
31
|
+
highlightData
|
|
28
32
|
} = this.props;
|
|
29
33
|
let {
|
|
30
34
|
LinkProps = {},
|
|
31
35
|
TextProps = {}
|
|
32
36
|
} = customProps;
|
|
37
|
+
let tagAttributesText = { ...TextProps,
|
|
38
|
+
'data-title-wrap': whiteSpace
|
|
39
|
+
};
|
|
40
|
+
let linkTagAttributes = {
|
|
41
|
+
'data-title-wrap': whiteSpace
|
|
42
|
+
};
|
|
33
43
|
return /*#__PURE__*/React.createElement(React.Fragment, null, isLink ? /*#__PURE__*/React.createElement(Link, {
|
|
34
44
|
urlName: urlName,
|
|
35
45
|
href: href,
|
|
36
46
|
urlData: urlData,
|
|
37
47
|
onClick: onClick,
|
|
38
|
-
className: `${style.subject} ${isDotted ? style.dotted : ''} ${whiteSpaceClassMapping[whiteSpace]} ${className} ${style[`font_${fontWeight}`]} ${style.cursorPointer}`,
|
|
39
|
-
dataId: dataId,
|
|
40
|
-
title: text,
|
|
41
48
|
target: target,
|
|
42
|
-
"data-title-wrap": whiteSpace,
|
|
43
49
|
...LinkProps
|
|
44
|
-
}, children ? children :
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
50
|
+
}, children ? children : /*#__PURE__*/React.createElement(Typography, {
|
|
51
|
+
$tagAttributes_text: linkTagAttributes,
|
|
52
|
+
$i18n_dataTitle: text,
|
|
53
|
+
$ui_className: `${style.subject} ${whiteSpaceClassMapping[whiteSpace]} ${className} ${style.cursorPointer}`,
|
|
54
|
+
customId: dataId,
|
|
55
|
+
$flag_dotted: isDotted,
|
|
56
|
+
$ui_weight: fontWeight,
|
|
57
|
+
$ui_highlightConfig: isHighlighted ? highlightData : DUMMY_OBJECT
|
|
58
|
+
}, text)) : /*#__PURE__*/React.createElement(Typography, {
|
|
59
|
+
$tagAttributes_text: tagAttributesText,
|
|
60
|
+
$ui_className: `${style.subject} ${className} ${whiteSpaceClassMapping[whiteSpace]}`,
|
|
61
|
+
$flag_dotted: isDotted,
|
|
62
|
+
$ui_weight: fontWeight,
|
|
63
|
+
$i18n_dataTitle: text,
|
|
64
|
+
customId: dataId,
|
|
65
|
+
testId: dataId,
|
|
66
|
+
$ui_highlightConfig: isHighlighted ? highlightData : DUMMY_OBJECT
|
|
51
67
|
}, text));
|
|
52
68
|
}
|
|
53
69
|
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
exports[`Subject rendering the defult props 1`] = `
|
|
4
4
|
<DocumentFragment>
|
|
5
|
-
<
|
|
6
|
-
class="
|
|
5
|
+
<div
|
|
6
|
+
class="dotted font_regular subject whiteSpace_pre"
|
|
7
7
|
data-title-wrap="pre"
|
|
8
8
|
/>
|
|
9
9
|
</DocumentFragment>
|
|
@@ -11,8 +11,8 @@ exports[`Subject rendering the defult props 1`] = `
|
|
|
11
11
|
|
|
12
12
|
exports[`Subject rendering the whiteSpace of -break-spaces 1`] = `
|
|
13
13
|
<DocumentFragment>
|
|
14
|
-
<
|
|
15
|
-
class="
|
|
14
|
+
<div
|
|
15
|
+
class="dotted font_regular subject whiteSpace_breakSpaces"
|
|
16
16
|
data-title-wrap="break-spaces"
|
|
17
17
|
/>
|
|
18
18
|
</DocumentFragment>
|
|
@@ -20,8 +20,8 @@ exports[`Subject rendering the whiteSpace of -break-spaces 1`] = `
|
|
|
20
20
|
|
|
21
21
|
exports[`Subject rendering the whiteSpace of -normal 1`] = `
|
|
22
22
|
<DocumentFragment>
|
|
23
|
-
<
|
|
24
|
-
class="
|
|
23
|
+
<div
|
|
24
|
+
class="dotted font_regular subject whiteSpace_normal"
|
|
25
25
|
data-title-wrap="normal"
|
|
26
26
|
/>
|
|
27
27
|
</DocumentFragment>
|
|
@@ -29,8 +29,8 @@ exports[`Subject rendering the whiteSpace of -normal 1`] = `
|
|
|
29
29
|
|
|
30
30
|
exports[`Subject rendering the whiteSpace of -nowrap 1`] = `
|
|
31
31
|
<DocumentFragment>
|
|
32
|
-
<
|
|
33
|
-
class="
|
|
32
|
+
<div
|
|
33
|
+
class="dotted font_regular subject whiteSpace_nowrap"
|
|
34
34
|
data-title-wrap="nowrap"
|
|
35
35
|
/>
|
|
36
36
|
</DocumentFragment>
|
|
@@ -38,8 +38,8 @@ exports[`Subject rendering the whiteSpace of -nowrap 1`] = `
|
|
|
38
38
|
|
|
39
39
|
exports[`Subject rendering the whiteSpace of -pre 1`] = `
|
|
40
40
|
<DocumentFragment>
|
|
41
|
-
<
|
|
42
|
-
class="
|
|
41
|
+
<div
|
|
42
|
+
class="dotted font_regular subject whiteSpace_pre"
|
|
43
43
|
data-title-wrap="pre"
|
|
44
44
|
/>
|
|
45
45
|
</DocumentFragment>
|
|
@@ -47,8 +47,8 @@ exports[`Subject rendering the whiteSpace of -pre 1`] = `
|
|
|
47
47
|
|
|
48
48
|
exports[`Subject rendering the whiteSpace of -pre-line 1`] = `
|
|
49
49
|
<DocumentFragment>
|
|
50
|
-
<
|
|
51
|
-
class="
|
|
50
|
+
<div
|
|
51
|
+
class="dotted font_regular subject whiteSpace_preLine"
|
|
52
52
|
data-title-wrap="pre-line"
|
|
53
53
|
/>
|
|
54
54
|
</DocumentFragment>
|
|
@@ -56,8 +56,8 @@ exports[`Subject rendering the whiteSpace of -pre-line 1`] = `
|
|
|
56
56
|
|
|
57
57
|
exports[`Subject rendering the whiteSpace of -pre-wrap 1`] = `
|
|
58
58
|
<DocumentFragment>
|
|
59
|
-
<
|
|
60
|
-
class="
|
|
59
|
+
<div
|
|
60
|
+
class="dotted font_regular subject whiteSpace_preWrap"
|
|
61
61
|
data-title-wrap="pre-wrap"
|
|
62
62
|
/>
|
|
63
63
|
</DocumentFragment>
|