dtable-ui-component 0.1.95 → 0.1.96-test3

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.
@@ -2,10 +2,6 @@
2
2
  position: relative;
3
3
  }
4
4
 
5
- .dtable-ui-collaborator-editor-container .collaborators-container {
6
- margin-top: 8px;
7
- }
8
-
9
5
  .dtable-ui-collaborator-editor-popover .collaborator-search-container {
10
6
  padding: 10px 10px 0 10px;
11
7
  }
@@ -197,9 +197,9 @@ var CollaboratorEditor = /*#__PURE__*/function (_React$Component) {
197
197
  }, /*#__PURE__*/React.createElement(EditEditorButton, {
198
198
  text: getLocale('Add_a_collaborator'),
199
199
  onClick: this.onAddOptionToggle
200
- }), /*#__PURE__*/React.createElement("div", {
201
- className: "collaborators-container"
202
- }, selectedCollaborators.length > 0 && selectedCollaborators.map(function (collaborator) {
200
+ }), selectedCollaborators.length > 0 && /*#__PURE__*/React.createElement("div", {
201
+ className: "collaborators-container mt-2"
202
+ }, selectedCollaborators.map(function (collaborator) {
203
203
  return /*#__PURE__*/React.createElement(CollaboratorItem, {
204
204
  key: collaborator.email,
205
205
  collaborator: collaborator,
@@ -0,0 +1,17 @@
1
+ .dtable-ui-editor-button {
2
+ display: inline-block;
3
+ padding: 0 12px;
4
+ height: 28px;
5
+ line-height: 28px;
6
+ font-size: 14px;
7
+ background-color: #f0f0f0;
8
+ color: #8f8f8f;
9
+ border-radius: 4px;
10
+ cursor: pointer;
11
+ user-select: none;
12
+ }
13
+
14
+ .dtable-ui-editor-button:hover {
15
+ background-color: #dbdbdb;
16
+ color: #666;
17
+ }
@@ -3,6 +3,7 @@ import _createClass from "@babel/runtime/helpers/esm/createClass";
3
3
  import _inherits from "@babel/runtime/helpers/esm/inherits";
4
4
  import _createSuper from "@babel/runtime/helpers/esm/createSuper";
5
5
  import React from 'react';
6
+ import './index.css';
6
7
 
7
8
  var EditEditorButton = /*#__PURE__*/function (_React$Component) {
8
9
  _inherits(EditEditorButton, _React$Component);
@@ -10,41 +11,17 @@ var EditEditorButton = /*#__PURE__*/function (_React$Component) {
10
11
  var _super = _createSuper(EditEditorButton);
11
12
 
12
13
  function EditEditorButton() {
13
- var _this;
14
-
15
14
  _classCallCheck(this, EditEditorButton);
16
15
 
17
- for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
18
- args[_key] = arguments[_key];
19
- }
20
-
21
- _this = _super.call.apply(_super, [this].concat(args));
22
-
23
- _this.getStyle = function () {
24
- return {
25
- display: 'inline-block',
26
- padding: '0 12px',
27
- height: '28px',
28
- lineHeight: '28px',
29
- fontSize: '14px',
30
- backgroundColor: '#f0f0f0',
31
- color: '#8f8f8f',
32
- borderRadius: '4px',
33
- cursor: 'pointer',
34
- userSelect: 'none'
35
- };
36
- };
37
-
38
- return _this;
16
+ return _super.apply(this, arguments);
39
17
  }
40
18
 
41
19
  _createClass(EditEditorButton, [{
42
20
  key: "render",
43
21
  value: function render() {
44
22
  var text = this.props.text;
45
- var style = this.getStyle();
46
23
  return /*#__PURE__*/React.createElement("span", {
47
- style: style,
24
+ className: "dtable-ui-editor-button",
48
25
  onClick: this.props.onClick
49
26
  }, text);
50
27
  }
@@ -1,9 +1,3 @@
1
1
  .dtable-ui-link-editor {
2
2
  position: relative;
3
3
  }
4
-
5
- .dtable-ui-link-editor-container {
6
- display: inline-block;
7
- height: 30px;
8
- padding: 0 10px;
9
- }
@@ -1,3 +1 @@
1
- .dtable-ui-mtime-formatter {
2
- max-width: 320px;
3
- }
1
+ @import url('../css/cell-formatter.css');
@@ -36,7 +36,7 @@ var MTimeFormatter = /*#__PURE__*/function (_React$Component) {
36
36
  var _this$props = this.props,
37
37
  date = _this$props.value,
38
38
  containerClassName = _this$props.containerClassName;
39
- var classname = cn('form-control dtable-ui-mtime-formatter', containerClassName);
39
+ var classname = cn('dtable-ui cell-formatter-container ctime-formatter', containerClassName);
40
40
 
41
41
  if (date !== '') {
42
42
  date = this.formatDate(date);
@@ -2,13 +2,13 @@
2
2
  position: relative;
3
3
  }
4
4
 
5
- .dtable-ui-select-editor-container {
5
+ .dtable-ui-single-select-option-container {
6
6
  height: 40px;
7
7
  padding: 10px 5px;
8
8
  border-radius: 3px;
9
9
  cursor: pointer;
10
10
  }
11
11
 
12
- .dtable-ui-select-editor-container:hover {
12
+ .dtable-ui-single-select-option-container:hover {
13
13
  background-color: #f5f5f5;
14
14
  }
@@ -157,14 +157,16 @@ var SingleSelectEditor = /*#__PURE__*/function (_React$Component) {
157
157
  var selectedOptions = option ? [option] : [];
158
158
  return /*#__PURE__*/React.createElement("div", {
159
159
  ref: this.setEditorContainerRef,
160
- className: "cell-editor dtable-ui-single-select-editor"
160
+ className: "dtable-ui-single-select-editor"
161
161
  }, /*#__PURE__*/React.createElement("div", {
162
162
  ref: this.setEditorRef,
163
- className: "dtable-ui-select-editor-container",
163
+ className: "dtable-ui-single-select-editor-container d-inline-block",
164
164
  onClick: this.onAddOptionToggle
165
- }, option ? /*#__PURE__*/React.createElement(SelectEditorOption, {
165
+ }, option ? /*#__PURE__*/React.createElement("div", {
166
+ className: "dtable-ui-single-select-option-container"
167
+ }, /*#__PURE__*/React.createElement(SelectEditorOption, {
166
168
  option: option
167
- }) : /*#__PURE__*/React.createElement(EditEditorButton, {
169
+ })) : /*#__PURE__*/React.createElement(EditEditorButton, {
168
170
  text: getLocale('Add_an_option')
169
171
  })), isPopoverShow && /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(MediaQuery, {
170
172
  query: "(min-width: 768px)"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dtable-ui-component",
3
- "version": "0.1.95",
3
+ "version": "0.1.96-test3",
4
4
  "main": "./lib/index.js",
5
5
  "dependencies": {
6
6
  "@seafile/react-image-lightbox": "0.0.9",