dtable-ui-component 0.1.75-beta → 0.1.75-beta1
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/lib/app.css +20 -0
- package/lib/app.js +96 -0
- package/lib/assets/images/avatar/default_avatar.png +0 -0
- package/lib/assets/images/file/192/excel.png +0 -0
- package/lib/assets/images/file/192/file.png +0 -0
- package/lib/assets/images/file/192/music.png +0 -0
- package/lib/assets/images/file/192/pdf.png +0 -0
- package/lib/assets/images/file/192/pic.png +0 -0
- package/lib/assets/images/file/192/ppt.png +0 -0
- package/lib/assets/images/file/192/txt.png +0 -0
- package/lib/assets/images/file/192/video.png +0 -0
- package/lib/assets/images/file/192/word.png +0 -0
- package/lib/assets/images/file/24/excel.png +0 -0
- package/lib/assets/images/file/24/file.png +0 -0
- package/lib/assets/images/file/24/music.png +0 -0
- package/lib/assets/images/file/24/pdf.png +0 -0
- package/lib/assets/images/file/24/pic.png +0 -0
- package/lib/assets/images/file/24/ppt.png +0 -0
- package/lib/assets/images/file/24/txt.png +0 -0
- package/lib/assets/images/file/24/video.png +0 -0
- package/lib/assets/images/file/24/word.png +0 -0
- package/lib/assets/images/folder/folder-192.png +0 -0
- package/lib/assets/images/folder/folder-24.png +0 -0
- package/lib/components/cell-editor/checkbox-editor.js +111 -0
- package/lib/components/cell-editor/collaborator-editor.js +249 -0
- package/lib/components/cell-editor/date-editor.js +171 -0
- package/lib/components/cell-editor/index.js +40 -0
- package/lib/components/cell-editor/link-editor.js +321 -0
- package/lib/components/cell-editor/multiple-select-editor.js +250 -0
- package/lib/components/cell-editor/number-editor.js +162 -0
- package/lib/components/cell-editor/single-select-editor.js +216 -0
- package/lib/components/cell-editor/text-editor.js +129 -0
- package/lib/components/cell-editor-dialog/pc-file-editor-dialog.js +66 -0
- package/lib/components/cell-editor-dialog/pc-files-addition/index.js +1 -0
- package/lib/components/cell-editor-dialog/pc-files-addition/pc-file-uploaded-item.js +1 -0
- package/lib/components/cell-editor-dialog/pc-files-preview/index.js +1 -0
- package/lib/components/cell-editor-dialog/pc-files-preview/pc-file-item-preview.js +1 -0
- package/lib/components/cell-editor-popover/mb-collaborator-editor-popover.js +183 -0
- package/lib/components/cell-editor-popover/mb-date-editor-popover.js +262 -0
- package/lib/components/cell-editor-popover/mb-link-editor-popover.js +176 -0
- package/lib/components/cell-editor-popover/mb-select-editor-popover.js +243 -0
- package/lib/components/cell-editor-popover/pc-collaborator-editor-popover.js +124 -0
- package/lib/components/cell-editor-popover/pc-date-editor-popover.js +156 -0
- package/lib/components/cell-editor-popover/pc-link-editor-popover.js +128 -0
- package/lib/components/cell-editor-popover/pc-select-editor-popover.js +157 -0
- package/lib/components/cell-factory/cell-formatter-factory.js +28 -0
- package/lib/components/cell-formatter/auto-number-formatter.js +45 -0
- package/lib/components/cell-formatter/button-formatter.js +66 -0
- package/lib/components/cell-formatter/checkbox-formatter.js +56 -0
- package/lib/components/cell-formatter/collaborator-formatter.js +111 -0
- package/lib/components/cell-formatter/creator-formatter.js +105 -0
- package/lib/components/cell-formatter/ctime-formatter.js +70 -0
- package/lib/components/cell-formatter/date-formatter.js +73 -0
- package/lib/components/cell-formatter/duration-formatter.js +49 -0
- package/lib/components/cell-formatter/email-formatter.js +45 -0
- package/lib/components/cell-formatter/file-formatter.js +77 -0
- package/lib/components/cell-formatter/formatter-config.js +66 -0
- package/lib/components/cell-formatter/formula-formatter.js +189 -0
- package/lib/components/cell-formatter/geolocation-formatter.js +66 -0
- package/lib/components/cell-formatter/image-formatter.js +171 -0
- package/lib/components/cell-formatter/index.js +112 -0
- package/lib/components/cell-formatter/last-modifier-formatter.js +105 -0
- package/lib/components/cell-formatter/link-formatter.js +165 -0
- package/lib/components/cell-formatter/long-text-formatter.js +46 -0
- package/lib/components/cell-formatter/mtime-formatter.js +70 -0
- package/lib/components/cell-formatter/multiple-select-formatter.js +84 -0
- package/lib/components/cell-formatter/number-formatter.js +60 -0
- package/lib/components/cell-formatter/rate-formatter.js +93 -0
- package/lib/components/cell-formatter/single-select-formatter.js +84 -0
- package/lib/components/cell-formatter/text-formatter.js +67 -0
- package/lib/components/cell-formatter/url-formatter.js +45 -0
- package/lib/components/cell-formatter/widgets/file-item-formatter.js +63 -0
- package/lib/components/cell-formatter/widgets/image-previewer-lightbox.js +152 -0
- package/lib/components/cell-formatter/widgets/long-text-formatter/html-long-text-formatter.js +107 -0
- package/lib/components/cell-formatter/widgets/long-text-formatter/simple-long-text-formatter.js +110 -0
- package/lib/components/common/collaborator-item.js +79 -0
- package/lib/components/common/edit-editor-button.js +67 -0
- package/lib/components/common/images-lazy-load.js +158 -0
- package/lib/components/common/link-editor-option.js +121 -0
- package/lib/components/common/mobile/mb-editor-header.js +61 -0
- package/lib/components/common/modal-portal.js +51 -0
- package/lib/components/common/select-editor-option.js +122 -0
- package/lib/components/common/select-item.js +73 -0
- package/lib/components/file-uploader/index.js +63 -0
- package/lib/components/loading.js +16 -0
- package/lib/components/toast/alert.js +164 -0
- package/lib/components/toast/index.js +12 -0
- package/lib/components/toast/toast.js +223 -0
- package/lib/components/toast/toastManager.js +189 -0
- package/lib/components/toast/toaster.js +92 -0
- package/lib/constants/cell-types.js +54 -0
- package/lib/constants/index.js +70 -0
- package/lib/css/cell-editor.css +614 -0
- package/lib/css/cell-formatter.css +247 -0
- package/lib/css/custom-rc-calendar.css +118 -0
- package/lib/css/image-previewer-ligntbox.css +87 -0
- package/lib/css/loading.css +54 -0
- package/lib/index.js +64 -0
- package/lib/lang/index.js +66 -0
- package/lib/locals/de.js +7 -0
- package/lib/locals/en.js +22 -0
- package/lib/locals/fr.js +7 -0
- package/lib/locals/zh-CN.js +22 -0
- package/lib/utils/cell-value-validator.js +41 -0
- package/lib/utils/column-utils.js +15 -0
- package/lib/utils/editor-utils.js +81 -0
- package/lib/utils/markdown2html.js +68 -0
- package/lib/utils/normalize-long-text-value.js +74 -0
- package/lib/utils/number-precision.js +181 -0
- package/lib/utils/unified/index.js +470 -0
- package/lib/utils/utils.js +141 -0
- package/lib/utils/value-format-utils.js +545 -0
- package/lib/utils/vfile/core.js +172 -0
- package/lib/utils/vfile/index.js +48 -0
- package/package.json +3 -3
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var VMessage = require('vfile-message');
|
|
4
|
+
|
|
5
|
+
var VFile = require('./core.js');
|
|
6
|
+
|
|
7
|
+
module.exports = VFile;
|
|
8
|
+
var proto = VFile.prototype;
|
|
9
|
+
proto.message = message;
|
|
10
|
+
proto.info = info;
|
|
11
|
+
proto.fail = fail;
|
|
12
|
+
/* Slight backwards compatibility. Remove in the future. */
|
|
13
|
+
|
|
14
|
+
proto.warn = message;
|
|
15
|
+
/* Create a message with `reason` at `position`.
|
|
16
|
+
* When an error is passed in as `reason`, copies the stack. */
|
|
17
|
+
|
|
18
|
+
function message(reason, position, origin) {
|
|
19
|
+
var filePath = this.path;
|
|
20
|
+
var message = new VMessage(reason, position, origin);
|
|
21
|
+
|
|
22
|
+
if (filePath) {
|
|
23
|
+
message.name = filePath + ':' + message.name;
|
|
24
|
+
message.file = filePath;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
message.fatal = false;
|
|
28
|
+
this.messages.push(message);
|
|
29
|
+
return message;
|
|
30
|
+
}
|
|
31
|
+
/* Fail. Creates a vmessage, associates it with the file,
|
|
32
|
+
* and throws it. */
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
function fail() {
|
|
36
|
+
var message = this.message.apply(this, arguments);
|
|
37
|
+
message.fatal = true;
|
|
38
|
+
throw message;
|
|
39
|
+
}
|
|
40
|
+
/* Info. Creates a vmessage, associates it with the file,
|
|
41
|
+
* and marks the fatality as null. */
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
function info() {
|
|
45
|
+
var message = this.message.apply(this, arguments);
|
|
46
|
+
message.fatal = null;
|
|
47
|
+
return message;
|
|
48
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dtable-ui-component",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.75beta1",
|
|
4
4
|
"main": "./es/index.js",
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"@seafile/react-image-lightbox": "0.0.9",
|
|
@@ -48,8 +48,8 @@
|
|
|
48
48
|
"pub:esm": "npm run clean:esm && export BABEL_ENV=production && ./node_modules/.bin/babel src --out-dir es --copy-files",
|
|
49
49
|
"pub:lib": "npm run clean:lib && export BABEL_ENV=node && ./node_modules/.bin/babel src --out-dir lib --copy-files",
|
|
50
50
|
"pub:umd": "npm run build",
|
|
51
|
-
"pub:optimized": "rm es/index.local.js",
|
|
52
|
-
"prepublishOnly": "npm run pub:esm && npm run pub:umd && npm run pub:optimized"
|
|
51
|
+
"pub:optimized": "rm es/index.local.js && rm lib/index.local.js",
|
|
52
|
+
"prepublishOnly": "npm run pub:esm && npm run pub:lib && npm run pub:umd && npm run pub:optimized"
|
|
53
53
|
},
|
|
54
54
|
"files": [
|
|
55
55
|
"assets",
|