@zohodesk/dot 1.0.0-temp-226.1 → 1.0.0-temp-228
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 +5 -0
- package/es/ActionButton/ActionButton.js +19 -9
- package/es/ActionButton/props/defaultProps.js +2 -1
- package/es/ActionButton/props/propTypes.js +4 -1
- package/es/list/Comment/Comment.module.css +29 -29
- package/es/list/Dot/Dot.module.css +15 -15
- package/es/list/ListLayout/ListLayout.module.css +79 -79
- package/lib/ActionButton/ActionButton.js +18 -9
- package/lib/ActionButton/props/defaultProps.js +2 -1
- package/lib/ActionButton/props/propTypes.js +4 -1
- package/lib/list/Comment/Comment.module.css +29 -29
- package/lib/list/Dot/Dot.module.css +15 -15
- package/lib/list/ListLayout/ListLayout.module.css +79 -79
- package/package.json +8 -8
package/README.md
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
In this Library, we Provide Some Basic Components to Build Your Application
|
|
4
4
|
|
|
5
|
+
# 1.9.8
|
|
6
|
+
|
|
7
|
+
- **DotProvider** - Variables package handled and separated the component & variable import files
|
|
8
|
+
- **Dependency**: @zohodesk/variables@1.3.0 , @zohodesk/components@1.6.6
|
|
9
|
+
|
|
5
10
|
# 1.9.7
|
|
6
11
|
|
|
7
12
|
- **Upload** => upload_overlay_bg color contrast fixed
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
2
|
+
|
|
1
3
|
import React from 'react';
|
|
2
4
|
import { defaultProps } from "./props/defaultProps";
|
|
3
5
|
import { propTypes } from "./props/propTypes";
|
|
@@ -7,13 +9,16 @@ import Button from '@zohodesk/components/es/Button/Button';
|
|
|
7
9
|
import { Container, Box } from '@zohodesk/components/es/Layout';
|
|
8
10
|
import ResponsiveDropBox from '@zohodesk/components/es/ResponsiveDropBox/ResponsiveDropBox';
|
|
9
11
|
import CssProvider from '@zohodesk/components/es/Provider/CssProvider';
|
|
12
|
+
import { getUniqueId } from '@zohodesk/components/es/Provider/IdProvider';
|
|
10
13
|
import style from "./ActionButton.module.css";
|
|
11
14
|
import btnStyle from '@zohodesk/components/es/semantic/Button/semanticButton.module.css';
|
|
12
15
|
export class ActionButton extends React.Component {
|
|
13
16
|
constructor(props) {
|
|
14
17
|
super(props);
|
|
18
|
+
this.getElementId = getUniqueId(this);
|
|
15
19
|
this.handleTogglePopup = this.handleTogglePopup.bind(this);
|
|
16
20
|
this.handlePopupOpen = this.handlePopupOpen.bind(this);
|
|
21
|
+
this.popupId = this.getElementId();
|
|
17
22
|
}
|
|
18
23
|
|
|
19
24
|
handlePopupOpen(e) {
|
|
@@ -64,8 +69,12 @@ export class ActionButton extends React.Component {
|
|
|
64
69
|
isAbsolutePositioningNeeded,
|
|
65
70
|
isRestrictScroll,
|
|
66
71
|
positionsOffset,
|
|
67
|
-
targetOffset
|
|
72
|
+
targetOffset,
|
|
73
|
+
a11yAttributes
|
|
68
74
|
} = this.props;
|
|
75
|
+
const {
|
|
76
|
+
splitButton: a11yAttributes_splitButton
|
|
77
|
+
} = a11yAttributes;
|
|
69
78
|
return /*#__PURE__*/React.createElement(Container, {
|
|
70
79
|
alignBox: "row",
|
|
71
80
|
isCover: false,
|
|
@@ -92,8 +101,7 @@ export class ActionButton extends React.Component {
|
|
|
92
101
|
dataId: dataId,
|
|
93
102
|
className: `${btnStyle.buttonReset} ${style.contentBox} ${style[palette + 'Btn']} ${style[size + '_btnBox']} ${children ? style.contentBoxBdr : style.contentBoxBdrRds} ${style.clickable} ${innerClassName} `,
|
|
94
103
|
"data-title": dataTitle,
|
|
95
|
-
tagName: "button"
|
|
96
|
-
tabIndex: "0"
|
|
104
|
+
tagName: "button"
|
|
97
105
|
}, /*#__PURE__*/React.createElement(Container, {
|
|
98
106
|
align: "both"
|
|
99
107
|
}, /*#__PURE__*/React.createElement(Box, {
|
|
@@ -113,22 +121,23 @@ export class ActionButton extends React.Component {
|
|
|
113
121
|
}, text) : null)), subText ? /*#__PURE__*/React.createElement(Box, {
|
|
114
122
|
"data-title": removeChildrenTooltip ? null : subText,
|
|
115
123
|
className: style.subTxt
|
|
116
|
-
}, subText) : null)), children ? /*#__PURE__*/React.createElement(Box, {
|
|
124
|
+
}, subText) : null)), children ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Box, _extends({}, a11yAttributes_splitButton, {
|
|
117
125
|
onClick: onClick && !onHover ? this.handleTogglePopup : this.handlePopupOpen,
|
|
118
126
|
onMouseEnter: onClick ? onHover && this.handleTogglePopup : undefined,
|
|
119
127
|
onMouseLeave: onClick ? onHover && this.handleTogglePopup : undefined,
|
|
120
128
|
className: `${btnStyle.buttonReset} ${style[arrowBoxSize + '_arrowBox']} ${style[palette + 'Arw']} ${style.arrowWrapper} ${isPopupOpen ? style.arrowActive : ''}`,
|
|
121
129
|
dataId: `${dataId}_arrowButton`,
|
|
122
|
-
tabIndex: "0",
|
|
123
130
|
tagName: "button",
|
|
124
|
-
dataSelectorId: `${dataSelectorId}_arrowButton
|
|
125
|
-
|
|
131
|
+
dataSelectorId: `${dataSelectorId}_arrowButton`,
|
|
132
|
+
"aria-expanded": isPopupOpen,
|
|
133
|
+
"aria-controls": this.popupId
|
|
134
|
+
}), /*#__PURE__*/React.createElement(Container, {
|
|
126
135
|
align: "both"
|
|
127
136
|
}, /*#__PURE__*/React.createElement(Icon, {
|
|
128
137
|
name: "ZD-down",
|
|
129
138
|
size: "6",
|
|
130
139
|
iconClass: style.arrow
|
|
131
|
-
})), isPopupOpen ? /*#__PURE__*/React.createElement(ResponsiveDropBox, {
|
|
140
|
+
}))), isPopupOpen ? /*#__PURE__*/React.createElement(ResponsiveDropBox, {
|
|
132
141
|
size: "small",
|
|
133
142
|
isActive: isPopupOpen,
|
|
134
143
|
boxPosition: position,
|
|
@@ -146,7 +155,8 @@ export class ActionButton extends React.Component {
|
|
|
146
155
|
isAbsolutePositioningNeeded: isAbsolutePositioningNeeded,
|
|
147
156
|
isRestrictScroll: isRestrictScroll,
|
|
148
157
|
positionsOffset: positionsOffset,
|
|
149
|
-
targetOffset: targetOffset
|
|
158
|
+
targetOffset: targetOffset,
|
|
159
|
+
htmlId: this.popupId
|
|
150
160
|
}, /*#__PURE__*/React.createElement(Box, {
|
|
151
161
|
flexible: true,
|
|
152
162
|
shrink: true,
|
|
@@ -33,5 +33,8 @@ export const propTypes = {
|
|
|
33
33
|
isAbsolutePositioningNeeded: PropTypes.bool,
|
|
34
34
|
isRestrictScroll: PropTypes.bool,
|
|
35
35
|
positionsOffset: PropTypes.object,
|
|
36
|
-
targetOffset: PropTypes.object
|
|
36
|
+
targetOffset: PropTypes.object,
|
|
37
|
+
a11yAttributes: PropTypes.shape({
|
|
38
|
+
splitButton: PropTypes.object
|
|
39
|
+
})
|
|
37
40
|
};
|
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
.varClass {
|
|
2
|
-
--icon_color: var(--zdt_comment_iconText);
|
|
3
|
-
}
|
|
4
|
-
.container {
|
|
5
|
-
composes: varClass;
|
|
6
|
-
composes: inlineBlockMiddle from '../listCommon.module.css';
|
|
7
|
-
position: relative;
|
|
8
|
-
color: var(--icon_color);
|
|
9
|
-
padding: 0 var(--zd_size2) ;
|
|
10
|
-
cursor: pointer;
|
|
11
|
-
}
|
|
12
|
-
.container:hover {
|
|
13
|
-
--icon_color: var(--zdt_comment_hover_iconText);
|
|
14
|
-
}
|
|
15
|
-
.count {
|
|
16
|
-
position: absolute;
|
|
17
|
-
top: var(--zd_size1) ;
|
|
18
|
-
font-size: var(--zd_font_size9) ;
|
|
19
|
-
text-align: center;
|
|
20
|
-
}
|
|
21
|
-
[dir=ltr] .count {
|
|
22
|
-
left: 100% ;
|
|
23
|
-
}
|
|
24
|
-
[dir=rtl] .count {
|
|
25
|
-
right: 100% ;
|
|
26
|
-
}
|
|
27
|
-
.commentIcon {
|
|
28
|
-
font-size: var(--zd_font_size13) ;
|
|
29
|
-
}
|
|
1
|
+
.varClass {
|
|
2
|
+
--icon_color: var(--zdt_comment_iconText);
|
|
3
|
+
}
|
|
4
|
+
.container {
|
|
5
|
+
composes: varClass;
|
|
6
|
+
composes: inlineBlockMiddle from '../listCommon.module.css';
|
|
7
|
+
position: relative;
|
|
8
|
+
color: var(--icon_color);
|
|
9
|
+
padding: 0 var(--zd_size2) ;
|
|
10
|
+
cursor: pointer;
|
|
11
|
+
}
|
|
12
|
+
.container:hover {
|
|
13
|
+
--icon_color: var(--zdt_comment_hover_iconText);
|
|
14
|
+
}
|
|
15
|
+
.count {
|
|
16
|
+
position: absolute;
|
|
17
|
+
top: var(--zd_size1) ;
|
|
18
|
+
font-size: var(--zd_font_size9) ;
|
|
19
|
+
text-align: center;
|
|
20
|
+
}
|
|
21
|
+
[dir=ltr] .count {
|
|
22
|
+
left: 100% ;
|
|
23
|
+
}
|
|
24
|
+
[dir=rtl] .count {
|
|
25
|
+
right: 100% ;
|
|
26
|
+
}
|
|
27
|
+
.commentIcon {
|
|
28
|
+
font-size: var(--zd_font_size13) ;
|
|
29
|
+
}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
.varClass {
|
|
2
|
-
--dotColor: var(--zdt_dot_text)
|
|
3
|
-
}
|
|
4
|
-
.dot {
|
|
5
|
-
composes: varClass;
|
|
6
|
-
font-size: var(--zd_font_size16) ;
|
|
7
|
-
color: var(--dotColor);
|
|
8
|
-
transform: perspective(1px);
|
|
9
|
-
}
|
|
10
|
-
.list {
|
|
11
|
-
margin: 0 var(--zd_size6) ;
|
|
12
|
-
}
|
|
13
|
-
.minimalList {
|
|
14
|
-
margin: 0 var(--zd_size6) ;
|
|
15
|
-
}
|
|
1
|
+
.varClass {
|
|
2
|
+
--dotColor: var(--zdt_dot_text)
|
|
3
|
+
}
|
|
4
|
+
.dot {
|
|
5
|
+
composes: varClass;
|
|
6
|
+
font-size: var(--zd_font_size16) ;
|
|
7
|
+
color: var(--dotColor);
|
|
8
|
+
transform: perspective(1px);
|
|
9
|
+
}
|
|
10
|
+
.list {
|
|
11
|
+
margin: 0 var(--zd_size6) ;
|
|
12
|
+
}
|
|
13
|
+
.minimalList {
|
|
14
|
+
margin: 0 var(--zd_size6) ;
|
|
15
|
+
}
|
|
@@ -1,80 +1,80 @@
|
|
|
1
|
-
.varClass {
|
|
2
|
-
--listBorder: var(--zdt_listLayout_border)
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.container {
|
|
6
|
-
position: relative;
|
|
7
|
-
composes: varClass;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
.listHover:hover, .hoveredStyle, .listHover:focus-within, .hoveredStyle:focus-within {
|
|
11
|
-
background-color: var(--zdt_listLayout_hover_bg);
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
.active, .active:hover {
|
|
15
|
-
background-color: var(--zdt_listLayout_active_bg);
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.cursorPointer {
|
|
19
|
-
cursor: pointer
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
/* View */
|
|
23
|
-
.classic .innerContainer {
|
|
24
|
-
min-height: var(--zd_size70) ;
|
|
25
|
-
padding: var(--zd_size13) 0 ;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.compact .innerContainer {
|
|
29
|
-
min-height: var(--zd_size41) ;
|
|
30
|
-
padding: var(--zd_size5) 0 ;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
.superCompact .innerContainer {
|
|
34
|
-
min-height: var(--zd_size35) ;
|
|
35
|
-
padding: var(--zd_size2) 0 ;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
.compact .innerContainer,
|
|
39
|
-
.classic .innerContainer,
|
|
40
|
-
.superCompact .innerContainer {
|
|
41
|
-
/* css:theme-validation:ignore */
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
.compact .innerContainer, .classic .innerContainer, .superCompact .innerContainer {
|
|
45
|
-
border-bottom: 1px dotted var(--listBorder);
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
[dir=ltr] .compact, [dir=ltr] .classic, [dir=ltr] .superCompact {
|
|
49
|
-
border-left: var(--zd_size2) solid transparent;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
[dir=rtl] .compact, [dir=rtl] .classic, [dir=rtl] .superCompact {
|
|
53
|
-
border-right: var(--zd_size2) solid transparent;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
[dir=ltr] .keyboardActive, [dir=ltr] .active {
|
|
57
|
-
border-top-left-radius: var(--zd_size5);
|
|
58
|
-
border-bottom-left-radius: var(--zd_size5);
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
[dir=rtl] .keyboardActive, [dir=rtl] .active {
|
|
62
|
-
border-top-right-radius: var(--zd_size5);
|
|
63
|
-
border-bottom-right-radius: var(--zd_size5);
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
[dir=ltr] .keyboardActive {
|
|
67
|
-
border-left-color: var(--zdt_listLayout_keyboard_active_border);
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
[dir=rtl] .keyboardActive {
|
|
71
|
-
border-right-color: var(--zdt_listLayout_keyboard_active_border);
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
[dir=ltr] .active {
|
|
75
|
-
border-left-color: var(--zdt_listLayout_active_border);
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
[dir=rtl] .active {
|
|
79
|
-
border-right-color: var(--zdt_listLayout_active_border);
|
|
1
|
+
.varClass {
|
|
2
|
+
--listBorder: var(--zdt_listLayout_border)
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.container {
|
|
6
|
+
position: relative;
|
|
7
|
+
composes: varClass;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.listHover:hover, .hoveredStyle, .listHover:focus-within, .hoveredStyle:focus-within {
|
|
11
|
+
background-color: var(--zdt_listLayout_hover_bg);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.active, .active:hover {
|
|
15
|
+
background-color: var(--zdt_listLayout_active_bg);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.cursorPointer {
|
|
19
|
+
cursor: pointer
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/* View */
|
|
23
|
+
.classic .innerContainer {
|
|
24
|
+
min-height: var(--zd_size70) ;
|
|
25
|
+
padding: var(--zd_size13) 0 ;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.compact .innerContainer {
|
|
29
|
+
min-height: var(--zd_size41) ;
|
|
30
|
+
padding: var(--zd_size5) 0 ;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.superCompact .innerContainer {
|
|
34
|
+
min-height: var(--zd_size35) ;
|
|
35
|
+
padding: var(--zd_size2) 0 ;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.compact .innerContainer,
|
|
39
|
+
.classic .innerContainer,
|
|
40
|
+
.superCompact .innerContainer {
|
|
41
|
+
/* css:theme-validation:ignore */
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.compact .innerContainer, .classic .innerContainer, .superCompact .innerContainer {
|
|
45
|
+
border-bottom: 1px dotted var(--listBorder);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
[dir=ltr] .compact, [dir=ltr] .classic, [dir=ltr] .superCompact {
|
|
49
|
+
border-left: var(--zd_size2) solid transparent;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
[dir=rtl] .compact, [dir=rtl] .classic, [dir=rtl] .superCompact {
|
|
53
|
+
border-right: var(--zd_size2) solid transparent;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
[dir=ltr] .keyboardActive, [dir=ltr] .active {
|
|
57
|
+
border-top-left-radius: var(--zd_size5);
|
|
58
|
+
border-bottom-left-radius: var(--zd_size5);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
[dir=rtl] .keyboardActive, [dir=rtl] .active {
|
|
62
|
+
border-top-right-radius: var(--zd_size5);
|
|
63
|
+
border-bottom-right-radius: var(--zd_size5);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
[dir=ltr] .keyboardActive {
|
|
67
|
+
border-left-color: var(--zdt_listLayout_keyboard_active_border);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
[dir=rtl] .keyboardActive {
|
|
71
|
+
border-right-color: var(--zdt_listLayout_keyboard_active_border);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
[dir=ltr] .active {
|
|
75
|
+
border-left-color: var(--zdt_listLayout_active_border);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
[dir=rtl] .active {
|
|
79
|
+
border-right-color: var(--zdt_listLayout_active_border);
|
|
80
80
|
}
|
|
@@ -25,12 +25,16 @@ var _ResponsiveDropBox = _interopRequireDefault(require("@zohodesk/components/es
|
|
|
25
25
|
|
|
26
26
|
var _CssProvider = _interopRequireDefault(require("@zohodesk/components/es/Provider/CssProvider"));
|
|
27
27
|
|
|
28
|
+
var _IdProvider = require("@zohodesk/components/es/Provider/IdProvider");
|
|
29
|
+
|
|
28
30
|
var _ActionButtonModule = _interopRequireDefault(require("./ActionButton.module.css"));
|
|
29
31
|
|
|
30
32
|
var _semanticButtonModule = _interopRequireDefault(require("@zohodesk/components/es/semantic/Button/semanticButton.module.css"));
|
|
31
33
|
|
|
32
34
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
33
35
|
|
|
36
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
37
|
+
|
|
34
38
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
35
39
|
|
|
36
40
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
@@ -62,8 +66,10 @@ var ActionButton = /*#__PURE__*/function (_React$Component) {
|
|
|
62
66
|
_classCallCheck(this, ActionButton);
|
|
63
67
|
|
|
64
68
|
_this = _super.call(this, props);
|
|
69
|
+
_this.getElementId = (0, _IdProvider.getUniqueId)(_assertThisInitialized(_this));
|
|
65
70
|
_this.handleTogglePopup = _this.handleTogglePopup.bind(_assertThisInitialized(_this));
|
|
66
71
|
_this.handlePopupOpen = _this.handlePopupOpen.bind(_assertThisInitialized(_this));
|
|
72
|
+
_this.popupId = _this.getElementId();
|
|
67
73
|
return _this;
|
|
68
74
|
}
|
|
69
75
|
|
|
@@ -117,7 +123,9 @@ var ActionButton = /*#__PURE__*/function (_React$Component) {
|
|
|
117
123
|
isAbsolutePositioningNeeded = _this$props3.isAbsolutePositioningNeeded,
|
|
118
124
|
isRestrictScroll = _this$props3.isRestrictScroll,
|
|
119
125
|
positionsOffset = _this$props3.positionsOffset,
|
|
120
|
-
targetOffset = _this$props3.targetOffset
|
|
126
|
+
targetOffset = _this$props3.targetOffset,
|
|
127
|
+
a11yAttributes = _this$props3.a11yAttributes;
|
|
128
|
+
var a11yAttributes_splitButton = a11yAttributes.splitButton;
|
|
121
129
|
return /*#__PURE__*/_react["default"].createElement(_Layout.Container, {
|
|
122
130
|
alignBox: "row",
|
|
123
131
|
isCover: false,
|
|
@@ -144,8 +152,7 @@ var ActionButton = /*#__PURE__*/function (_React$Component) {
|
|
|
144
152
|
dataId: dataId,
|
|
145
153
|
className: "".concat(_semanticButtonModule["default"].buttonReset, " ").concat(_ActionButtonModule["default"].contentBox, " ").concat(_ActionButtonModule["default"][palette + 'Btn'], " ").concat(_ActionButtonModule["default"][size + '_btnBox'], " ").concat(children ? _ActionButtonModule["default"].contentBoxBdr : _ActionButtonModule["default"].contentBoxBdrRds, " ").concat(_ActionButtonModule["default"].clickable, " ").concat(innerClassName, " "),
|
|
146
154
|
"data-title": dataTitle,
|
|
147
|
-
tagName: "button"
|
|
148
|
-
tabIndex: "0"
|
|
155
|
+
tagName: "button"
|
|
149
156
|
}, /*#__PURE__*/_react["default"].createElement(_Layout.Container, {
|
|
150
157
|
align: "both"
|
|
151
158
|
}, /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
@@ -165,22 +172,23 @@ var ActionButton = /*#__PURE__*/function (_React$Component) {
|
|
|
165
172
|
}, text) : null)), subText ? /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
166
173
|
"data-title": removeChildrenTooltip ? null : subText,
|
|
167
174
|
className: _ActionButtonModule["default"].subTxt
|
|
168
|
-
}, subText) : null)), children ? /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
175
|
+
}, subText) : null)), children ? /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement(_Layout.Box, _extends({}, a11yAttributes_splitButton, {
|
|
169
176
|
onClick: onClick && !onHover ? this.handleTogglePopup : this.handlePopupOpen,
|
|
170
177
|
onMouseEnter: onClick ? onHover && this.handleTogglePopup : undefined,
|
|
171
178
|
onMouseLeave: onClick ? onHover && this.handleTogglePopup : undefined,
|
|
172
179
|
className: "".concat(_semanticButtonModule["default"].buttonReset, " ").concat(_ActionButtonModule["default"][arrowBoxSize + '_arrowBox'], " ").concat(_ActionButtonModule["default"][palette + 'Arw'], " ").concat(_ActionButtonModule["default"].arrowWrapper, " ").concat(isPopupOpen ? _ActionButtonModule["default"].arrowActive : ''),
|
|
173
180
|
dataId: "".concat(dataId, "_arrowButton"),
|
|
174
|
-
tabIndex: "0",
|
|
175
181
|
tagName: "button",
|
|
176
|
-
dataSelectorId: "".concat(dataSelectorId, "_arrowButton")
|
|
177
|
-
|
|
182
|
+
dataSelectorId: "".concat(dataSelectorId, "_arrowButton"),
|
|
183
|
+
"aria-expanded": isPopupOpen,
|
|
184
|
+
"aria-controls": this.popupId
|
|
185
|
+
}), /*#__PURE__*/_react["default"].createElement(_Layout.Container, {
|
|
178
186
|
align: "both"
|
|
179
187
|
}, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
|
|
180
188
|
name: "ZD-down",
|
|
181
189
|
size: "6",
|
|
182
190
|
iconClass: _ActionButtonModule["default"].arrow
|
|
183
|
-
})), isPopupOpen ? /*#__PURE__*/_react["default"].createElement(_ResponsiveDropBox["default"], {
|
|
191
|
+
}))), isPopupOpen ? /*#__PURE__*/_react["default"].createElement(_ResponsiveDropBox["default"], {
|
|
184
192
|
size: "small",
|
|
185
193
|
isActive: isPopupOpen,
|
|
186
194
|
boxPosition: position,
|
|
@@ -198,7 +206,8 @@ var ActionButton = /*#__PURE__*/function (_React$Component) {
|
|
|
198
206
|
isAbsolutePositioningNeeded: isAbsolutePositioningNeeded,
|
|
199
207
|
isRestrictScroll: isRestrictScroll,
|
|
200
208
|
positionsOffset: positionsOffset,
|
|
201
|
-
targetOffset: targetOffset
|
|
209
|
+
targetOffset: targetOffset,
|
|
210
|
+
htmlId: this.popupId
|
|
202
211
|
}, /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
203
212
|
flexible: true,
|
|
204
213
|
shrink: true,
|
|
@@ -43,6 +43,9 @@ var propTypes = {
|
|
|
43
43
|
isAbsolutePositioningNeeded: _propTypes["default"].bool,
|
|
44
44
|
isRestrictScroll: _propTypes["default"].bool,
|
|
45
45
|
positionsOffset: _propTypes["default"].object,
|
|
46
|
-
targetOffset: _propTypes["default"].object
|
|
46
|
+
targetOffset: _propTypes["default"].object,
|
|
47
|
+
a11yAttributes: _propTypes["default"].shape({
|
|
48
|
+
splitButton: _propTypes["default"].object
|
|
49
|
+
})
|
|
47
50
|
};
|
|
48
51
|
exports.propTypes = propTypes;
|
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
.varClass {
|
|
2
|
-
--icon_color: var(--zdt_comment_iconText);
|
|
3
|
-
}
|
|
4
|
-
.container {
|
|
5
|
-
composes: varClass;
|
|
6
|
-
composes: inlineBlockMiddle from '../listCommon.module.css';
|
|
7
|
-
position: relative;
|
|
8
|
-
color: var(--icon_color);
|
|
9
|
-
padding: 0 var(--zd_size2) ;
|
|
10
|
-
cursor: pointer;
|
|
11
|
-
}
|
|
12
|
-
.container:hover {
|
|
13
|
-
--icon_color: var(--zdt_comment_hover_iconText);
|
|
14
|
-
}
|
|
15
|
-
.count {
|
|
16
|
-
position: absolute;
|
|
17
|
-
top: var(--zd_size1) ;
|
|
18
|
-
font-size: var(--zd_font_size9) ;
|
|
19
|
-
text-align: center;
|
|
20
|
-
}
|
|
21
|
-
[dir=ltr] .count {
|
|
22
|
-
left: 100% ;
|
|
23
|
-
}
|
|
24
|
-
[dir=rtl] .count {
|
|
25
|
-
right: 100% ;
|
|
26
|
-
}
|
|
27
|
-
.commentIcon {
|
|
28
|
-
font-size: var(--zd_font_size13) ;
|
|
29
|
-
}
|
|
1
|
+
.varClass {
|
|
2
|
+
--icon_color: var(--zdt_comment_iconText);
|
|
3
|
+
}
|
|
4
|
+
.container {
|
|
5
|
+
composes: varClass;
|
|
6
|
+
composes: inlineBlockMiddle from '../listCommon.module.css';
|
|
7
|
+
position: relative;
|
|
8
|
+
color: var(--icon_color);
|
|
9
|
+
padding: 0 var(--zd_size2) ;
|
|
10
|
+
cursor: pointer;
|
|
11
|
+
}
|
|
12
|
+
.container:hover {
|
|
13
|
+
--icon_color: var(--zdt_comment_hover_iconText);
|
|
14
|
+
}
|
|
15
|
+
.count {
|
|
16
|
+
position: absolute;
|
|
17
|
+
top: var(--zd_size1) ;
|
|
18
|
+
font-size: var(--zd_font_size9) ;
|
|
19
|
+
text-align: center;
|
|
20
|
+
}
|
|
21
|
+
[dir=ltr] .count {
|
|
22
|
+
left: 100% ;
|
|
23
|
+
}
|
|
24
|
+
[dir=rtl] .count {
|
|
25
|
+
right: 100% ;
|
|
26
|
+
}
|
|
27
|
+
.commentIcon {
|
|
28
|
+
font-size: var(--zd_font_size13) ;
|
|
29
|
+
}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
.varClass {
|
|
2
|
-
--dotColor: var(--zdt_dot_text)
|
|
3
|
-
}
|
|
4
|
-
.dot {
|
|
5
|
-
composes: varClass;
|
|
6
|
-
font-size: var(--zd_font_size16) ;
|
|
7
|
-
color: var(--dotColor);
|
|
8
|
-
transform: perspective(1px);
|
|
9
|
-
}
|
|
10
|
-
.list {
|
|
11
|
-
margin: 0 var(--zd_size6) ;
|
|
12
|
-
}
|
|
13
|
-
.minimalList {
|
|
14
|
-
margin: 0 var(--zd_size6) ;
|
|
15
|
-
}
|
|
1
|
+
.varClass {
|
|
2
|
+
--dotColor: var(--zdt_dot_text)
|
|
3
|
+
}
|
|
4
|
+
.dot {
|
|
5
|
+
composes: varClass;
|
|
6
|
+
font-size: var(--zd_font_size16) ;
|
|
7
|
+
color: var(--dotColor);
|
|
8
|
+
transform: perspective(1px);
|
|
9
|
+
}
|
|
10
|
+
.list {
|
|
11
|
+
margin: 0 var(--zd_size6) ;
|
|
12
|
+
}
|
|
13
|
+
.minimalList {
|
|
14
|
+
margin: 0 var(--zd_size6) ;
|
|
15
|
+
}
|
|
@@ -1,80 +1,80 @@
|
|
|
1
|
-
.varClass {
|
|
2
|
-
--listBorder: var(--zdt_listLayout_border)
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.container {
|
|
6
|
-
position: relative;
|
|
7
|
-
composes: varClass;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
.listHover:hover, .hoveredStyle, .listHover:focus-within, .hoveredStyle:focus-within {
|
|
11
|
-
background-color: var(--zdt_listLayout_hover_bg);
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
.active, .active:hover {
|
|
15
|
-
background-color: var(--zdt_listLayout_active_bg);
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.cursorPointer {
|
|
19
|
-
cursor: pointer
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
/* View */
|
|
23
|
-
.classic .innerContainer {
|
|
24
|
-
min-height: var(--zd_size70) ;
|
|
25
|
-
padding: var(--zd_size13) 0 ;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.compact .innerContainer {
|
|
29
|
-
min-height: var(--zd_size41) ;
|
|
30
|
-
padding: var(--zd_size5) 0 ;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
.superCompact .innerContainer {
|
|
34
|
-
min-height: var(--zd_size35) ;
|
|
35
|
-
padding: var(--zd_size2) 0 ;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
.compact .innerContainer,
|
|
39
|
-
.classic .innerContainer,
|
|
40
|
-
.superCompact .innerContainer {
|
|
41
|
-
/* css:theme-validation:ignore */
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
.compact .innerContainer, .classic .innerContainer, .superCompact .innerContainer {
|
|
45
|
-
border-bottom: 1px dotted var(--listBorder);
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
[dir=ltr] .compact, [dir=ltr] .classic, [dir=ltr] .superCompact {
|
|
49
|
-
border-left: var(--zd_size2) solid transparent;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
[dir=rtl] .compact, [dir=rtl] .classic, [dir=rtl] .superCompact {
|
|
53
|
-
border-right: var(--zd_size2) solid transparent;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
[dir=ltr] .keyboardActive, [dir=ltr] .active {
|
|
57
|
-
border-top-left-radius: var(--zd_size5);
|
|
58
|
-
border-bottom-left-radius: var(--zd_size5);
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
[dir=rtl] .keyboardActive, [dir=rtl] .active {
|
|
62
|
-
border-top-right-radius: var(--zd_size5);
|
|
63
|
-
border-bottom-right-radius: var(--zd_size5);
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
[dir=ltr] .keyboardActive {
|
|
67
|
-
border-left-color: var(--zdt_listLayout_keyboard_active_border);
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
[dir=rtl] .keyboardActive {
|
|
71
|
-
border-right-color: var(--zdt_listLayout_keyboard_active_border);
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
[dir=ltr] .active {
|
|
75
|
-
border-left-color: var(--zdt_listLayout_active_border);
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
[dir=rtl] .active {
|
|
79
|
-
border-right-color: var(--zdt_listLayout_active_border);
|
|
1
|
+
.varClass {
|
|
2
|
+
--listBorder: var(--zdt_listLayout_border)
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.container {
|
|
6
|
+
position: relative;
|
|
7
|
+
composes: varClass;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.listHover:hover, .hoveredStyle, .listHover:focus-within, .hoveredStyle:focus-within {
|
|
11
|
+
background-color: var(--zdt_listLayout_hover_bg);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.active, .active:hover {
|
|
15
|
+
background-color: var(--zdt_listLayout_active_bg);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.cursorPointer {
|
|
19
|
+
cursor: pointer
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/* View */
|
|
23
|
+
.classic .innerContainer {
|
|
24
|
+
min-height: var(--zd_size70) ;
|
|
25
|
+
padding: var(--zd_size13) 0 ;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.compact .innerContainer {
|
|
29
|
+
min-height: var(--zd_size41) ;
|
|
30
|
+
padding: var(--zd_size5) 0 ;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.superCompact .innerContainer {
|
|
34
|
+
min-height: var(--zd_size35) ;
|
|
35
|
+
padding: var(--zd_size2) 0 ;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.compact .innerContainer,
|
|
39
|
+
.classic .innerContainer,
|
|
40
|
+
.superCompact .innerContainer {
|
|
41
|
+
/* css:theme-validation:ignore */
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.compact .innerContainer, .classic .innerContainer, .superCompact .innerContainer {
|
|
45
|
+
border-bottom: 1px dotted var(--listBorder);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
[dir=ltr] .compact, [dir=ltr] .classic, [dir=ltr] .superCompact {
|
|
49
|
+
border-left: var(--zd_size2) solid transparent;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
[dir=rtl] .compact, [dir=rtl] .classic, [dir=rtl] .superCompact {
|
|
53
|
+
border-right: var(--zd_size2) solid transparent;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
[dir=ltr] .keyboardActive, [dir=ltr] .active {
|
|
57
|
+
border-top-left-radius: var(--zd_size5);
|
|
58
|
+
border-bottom-left-radius: var(--zd_size5);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
[dir=rtl] .keyboardActive, [dir=rtl] .active {
|
|
62
|
+
border-top-right-radius: var(--zd_size5);
|
|
63
|
+
border-bottom-right-radius: var(--zd_size5);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
[dir=ltr] .keyboardActive {
|
|
67
|
+
border-left-color: var(--zdt_listLayout_keyboard_active_border);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
[dir=rtl] .keyboardActive {
|
|
71
|
+
border-right-color: var(--zdt_listLayout_keyboard_active_border);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
[dir=ltr] .active {
|
|
75
|
+
border-left-color: var(--zdt_listLayout_active_border);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
[dir=rtl] .active {
|
|
79
|
+
border-right-color: var(--zdt_listLayout_active_border);
|
|
80
80
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zohodesk/dot",
|
|
3
|
-
"version": "1.0.0-temp-
|
|
3
|
+
"version": "1.0.0-temp-228",
|
|
4
4
|
"main": "lib/index",
|
|
5
5
|
"module": "es/index.js",
|
|
6
6
|
"private": false,
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"snap-update": "npm run test-clean && npm run test -- -u",
|
|
35
35
|
"sstest": "react-cli sstest",
|
|
36
36
|
"common_package_build": "cd ../common && npm run build && cd ../dot",
|
|
37
|
-
"prepublishOnly": "node prePublish.js && npm run downloadOnly
|
|
37
|
+
"prepublishOnly": "node prePublish.js && npm run downloadOnly",
|
|
38
38
|
"postpublish": "node postPublish.js",
|
|
39
39
|
"test-clean": "react-cli clean ./coverage && react-cli clean ./unittest react-cli clean ./es && react-cli clean ./lib && react-cli clean ./package-lock.json && react-cli clean ./result.json",
|
|
40
40
|
"download": "npm run downloadOnly && cd ../ && npm run download",
|
|
@@ -68,13 +68,13 @@
|
|
|
68
68
|
"@zohodesk-private/node-plugins": "1.1.13",
|
|
69
69
|
"@zohodesk-private/react-prop-validator": "1.2.3",
|
|
70
70
|
"@zohodesk/a11y": "2.3.8",
|
|
71
|
-
"@zohodesk/components": "1.
|
|
71
|
+
"@zohodesk/components": "1.6.6",
|
|
72
72
|
"@zohodesk/hooks": "2.0.8",
|
|
73
73
|
"@zohodesk/icons": "1.2.8",
|
|
74
|
-
"@zohodesk/layout": "
|
|
74
|
+
"@zohodesk/layout": "3.1.0",
|
|
75
75
|
"@zohodesk/svg": "1.3.3",
|
|
76
76
|
"@zohodesk/utils": "1.3.16",
|
|
77
|
-
"@zohodesk/variables": "1.
|
|
77
|
+
"@zohodesk/variables": "1.3.0",
|
|
78
78
|
"@zohodesk/virtualizer": "1.0.13",
|
|
79
79
|
"react-sortable-hoc": "^0.8.3",
|
|
80
80
|
"velocity-react": "1.4.3",
|
|
@@ -84,8 +84,8 @@
|
|
|
84
84
|
},
|
|
85
85
|
"peerDependencies": {
|
|
86
86
|
"velocity-react": "1.4.3",
|
|
87
|
-
"@zohodesk/variables": "1.
|
|
88
|
-
"@zohodesk/components": "1.
|
|
87
|
+
"@zohodesk/variables": "1.3.0",
|
|
88
|
+
"@zohodesk/components": "1.6.6",
|
|
89
89
|
"@zohodesk/icons": "1.2.8",
|
|
90
90
|
"@zohodesk/svg": "1.3.3",
|
|
91
91
|
"@zohodesk/virtualizer": "1.0.13",
|
|
@@ -95,4 +95,4 @@
|
|
|
95
95
|
"@zohodesk/a11y": "2.3.8",
|
|
96
96
|
"@zohodesk/layout": "3.1.0"
|
|
97
97
|
}
|
|
98
|
-
}
|
|
98
|
+
}
|