dtable-ui-component 0.2.1 → 0.2.3
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/es/app.css +20 -0
- package/es/app.js +91 -0
- package/es/assets/images/avatar/default_avatar.png +0 -0
- package/es/assets/images/file/192/excel.png +0 -0
- package/es/assets/images/file/192/file.png +0 -0
- package/es/assets/images/file/192/music.png +0 -0
- package/es/assets/images/file/192/pdf.png +0 -0
- package/es/assets/images/file/192/pic.png +0 -0
- package/es/assets/images/file/192/ppt.png +0 -0
- package/es/assets/images/file/192/txt.png +0 -0
- package/es/assets/images/file/192/video.png +0 -0
- package/es/assets/images/file/192/word.png +0 -0
- package/es/assets/images/file/24/excel.png +0 -0
- package/es/assets/images/file/24/file.png +0 -0
- package/es/assets/images/file/24/music.png +0 -0
- package/es/assets/images/file/24/pdf.png +0 -0
- package/es/assets/images/file/24/pic.png +0 -0
- package/es/assets/images/file/24/ppt.png +0 -0
- package/es/assets/images/file/24/txt.png +0 -0
- package/es/assets/images/file/24/video.png +0 -0
- package/es/assets/images/file/24/word.png +0 -0
- package/es/assets/images/folder/folder-192.png +0 -0
- package/es/assets/images/folder/folder-24.png +0 -0
- package/es/components/cell-editor/checkbox-editor.js +104 -0
- package/es/components/cell-editor/collaborator-editor.js +236 -0
- package/es/components/cell-editor/date-editor.js +151 -0
- package/es/components/cell-editor/index.js +9 -0
- package/es/components/cell-editor/link-editor.js +303 -0
- package/es/components/cell-editor/multiple-select-editor.js +237 -0
- package/es/components/cell-editor/number-editor.js +154 -0
- package/es/components/cell-editor/single-select-editor.js +202 -0
- package/es/components/cell-editor/text-editor.js +122 -0
- package/es/components/cell-editor-dialog/pc-file-editor-dialog.js +46 -0
- package/es/components/cell-editor-dialog/pc-files-addition/index.js +0 -0
- package/es/components/cell-editor-dialog/pc-files-addition/pc-file-uploaded-item.js +0 -0
- package/es/components/cell-editor-dialog/pc-files-preview/index.js +0 -0
- package/es/components/cell-editor-dialog/pc-files-preview/pc-file-item-preview.js +0 -0
- package/es/components/cell-editor-popover/mb-collaborator-editor-popover.js +177 -0
- package/es/components/cell-editor-popover/mb-date-editor-popover.js +245 -0
- package/es/components/cell-editor-popover/mb-link-editor-popover.js +170 -0
- package/es/components/cell-editor-popover/mb-select-editor-popover.js +230 -0
- package/es/components/cell-editor-popover/pc-collaborator-editor-popover.js +109 -0
- package/es/components/cell-editor-popover/pc-date-editor-popover.js +142 -0
- package/es/components/cell-editor-popover/pc-link-editor-popover.js +114 -0
- package/es/components/cell-editor-popover/pc-select-editor-popover.js +143 -0
- package/es/components/cell-factory/cell-formatter-factory.js +25 -0
- package/es/components/cell-formatter/auto-number-formatter.js +35 -0
- package/es/components/cell-formatter/button-formatter.js +55 -0
- package/es/components/cell-formatter/checkbox-formatter.js +44 -0
- package/es/components/cell-formatter/collaborator-formatter.js +91 -0
- package/es/components/cell-formatter/creator-formatter.js +87 -0
- package/es/components/cell-formatter/ctime-formatter.js +57 -0
- package/es/components/cell-formatter/date-formatter.js +59 -0
- package/es/components/cell-formatter/duration-formatter.js +37 -0
- package/es/components/cell-formatter/email-formatter.js +35 -0
- package/es/components/cell-formatter/file-formatter.js +63 -0
- package/es/components/cell-formatter/formatter-config.js +31 -0
- package/es/components/cell-formatter/formula-formatter.js +173 -0
- package/es/components/cell-formatter/geolocation-formatter.js +49 -0
- package/es/components/cell-formatter/image-formatter.js +153 -0
- package/es/components/cell-formatter/index.js +26 -0
- package/es/components/cell-formatter/last-modifier-formatter.js +87 -0
- package/es/components/cell-formatter/link-formatter.js +144 -0
- package/es/components/cell-formatter/long-text-formatter.js +106 -0
- package/es/components/cell-formatter/mtime-formatter.js +57 -0
- package/es/components/cell-formatter/multiple-select-formatter.js +70 -0
- package/es/components/cell-formatter/number-formatter.js +46 -0
- package/es/components/cell-formatter/rate-formatter.js +74 -0
- package/es/components/cell-formatter/single-select-formatter.js +69 -0
- package/es/components/cell-formatter/text-formatter.js +35 -0
- package/es/components/cell-formatter/url-formatter.js +35 -0
- package/es/components/cell-formatter/widgets/file-item-formatter.js +50 -0
- package/es/components/cell-formatter/widgets/image-previewer-lightbox.js +119 -0
- package/es/components/common/collaborator-item.js +63 -0
- package/es/components/common/edit-editor-button.js +56 -0
- package/es/components/common/images-lazy-load.js +148 -0
- package/es/components/common/link-editor-option.js +113 -0
- package/es/components/common/mobile/mb-editor-header.js +48 -0
- package/es/components/common/modal-portal.js +44 -0
- package/es/components/common/select-editor-option.js +106 -0
- package/es/components/common/select-item.js +58 -0
- package/es/components/file-uploader/index.js +53 -0
- package/es/components/loading.js +7 -0
- package/es/components/toast/alert.js +150 -0
- package/es/components/toast/index.js +3 -0
- package/es/components/toast/toast.js +179 -0
- package/es/components/toast/toastManager.js +170 -0
- package/es/components/toast/toaster.js +76 -0
- package/es/css/cell-editor.css +614 -0
- package/es/css/cell-formatter.css +241 -0
- package/es/css/custom-rc-calendar.css +118 -0
- package/es/css/image-previewer-ligntbox.css +87 -0
- package/es/css/loading.css +54 -0
- package/es/index.js +5 -0
- package/es/lang/index.js +50 -0
- package/es/locals/de.js +2 -0
- package/es/locals/en.js +17 -0
- package/es/locals/fr.js +2 -0
- package/es/locals/zh-CN.js +17 -0
- package/es/utils/cell-types.js +25 -0
- package/es/utils/constants.js +41 -0
- package/es/utils/editor-utils.js +71 -0
- package/es/utils/normalize-long-text-value.js +68 -0
- package/es/utils/number-precision.js +163 -0
- package/es/utils/utils.js +116 -0
- package/es/utils/value-format-utils.js +281 -0
- package/lib/ImageFormatter/index.js +4 -1
- package/lib/ImagePreviewerLightbox/index.js +23 -2
- package/lib/ImagePreviewerLightbox/utils.js +3 -2
- package/package.json +1 -1
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
.dtable-ui.cell-formatter-container {
|
|
2
|
+
overflow: hidden;
|
|
3
|
+
line-height: 1;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
/* collaborator */
|
|
7
|
+
.dtable-ui.collaborator-item {
|
|
8
|
+
display: inline-flex;
|
|
9
|
+
align-items: center;
|
|
10
|
+
margin-right: 10px;
|
|
11
|
+
padding: 0 8px 0 2px;
|
|
12
|
+
height: 20px;
|
|
13
|
+
font-size: 13px;
|
|
14
|
+
border-radius: 10px;
|
|
15
|
+
background: #eaeaea;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.dtable-ui.collaborator-item .collaborator-avatar,
|
|
19
|
+
.dtable-ui.collaborator-item .collaborator-name,
|
|
20
|
+
.dtable-ui.collaborator-item .collaborator-remove {
|
|
21
|
+
height: 20px;
|
|
22
|
+
line-height: 20px;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.dtable-ui.collaborator-item .collaborator-avatar {
|
|
26
|
+
display: flex;
|
|
27
|
+
align-items: center;
|
|
28
|
+
justify-content: center;
|
|
29
|
+
margin: 0 4px 0 2px;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.dtable-ui.collaborator-item .collaborator-avatar img {
|
|
33
|
+
width: 16px;
|
|
34
|
+
height: 16px;
|
|
35
|
+
border-radius: 50%;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.dtable-ui.collaborator-item .collaborator-remove {
|
|
39
|
+
display: inline-block;
|
|
40
|
+
width: 14px;
|
|
41
|
+
margin: 0 -2px 0 2px;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.dtable-ui.collaborator-item .collaborator-remove .dtable-font {
|
|
45
|
+
display: inline-block;
|
|
46
|
+
font-size: 12px;
|
|
47
|
+
color: #909090;
|
|
48
|
+
transform: scale(.8);
|
|
49
|
+
cursor: pointer;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.dtable-ui.collaborator-item .collaborator-remove .dtable-font:hover {
|
|
53
|
+
color: #666666;
|
|
54
|
+
cursor: pointer;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
/* long-text */
|
|
58
|
+
.dtable-ui.long-text-formatter {
|
|
59
|
+
display: flex;
|
|
60
|
+
align-items: center;
|
|
61
|
+
height: 28px;
|
|
62
|
+
overflow: hidden;
|
|
63
|
+
text-overflow: ellipsis;
|
|
64
|
+
white-space: nowrap;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.dtable-ui.long-text-formatter .long-text-links,
|
|
68
|
+
.dtable-ui.long-text-formatter .long-text-check-list {
|
|
69
|
+
display: inline-block;
|
|
70
|
+
height: 20px;
|
|
71
|
+
padding: 2px;
|
|
72
|
+
margin: 4px;
|
|
73
|
+
color: #9c9c9c;
|
|
74
|
+
background-color: #f0f0f0;
|
|
75
|
+
border-radius: 3px;
|
|
76
|
+
line-height: 16px;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.dtable-ui.long-text-formatter .long-text-check-list .dtable-font,
|
|
80
|
+
.dtable-ui.long-text-formatter .long-text-links .dtable-font {
|
|
81
|
+
margin-right: 4px;
|
|
82
|
+
font-size: 12px;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.dtable-ui.long-text-formatter .long-text-check-list .long-text-check-list-completed {
|
|
86
|
+
color: #61BD4F;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.dtable-ui.long-text-formatter .long-text-images {
|
|
90
|
+
margin-right: -10px;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.dtable-ui.long-text-formatter .long-text-images img {
|
|
94
|
+
max-width: 28px;
|
|
95
|
+
max-height: 28px;
|
|
96
|
+
border: 1px solid #f0f0f0;
|
|
97
|
+
box-sizing: border-box;
|
|
98
|
+
border-radius: 3px;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.dtable-ui.long-text-formatter .long-text-images .image-number {
|
|
102
|
+
display: inline-block;
|
|
103
|
+
min-width: 14px;
|
|
104
|
+
padding: 0 3px;
|
|
105
|
+
line-height: 14px;
|
|
106
|
+
font-style: normal;
|
|
107
|
+
font-size: 12px;
|
|
108
|
+
border-radius: 6px;
|
|
109
|
+
background-color: #999;
|
|
110
|
+
color: #fff;
|
|
111
|
+
transform: translate(-50%, 9px) scale(0.8);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.dtable-ui.file-formatter {
|
|
115
|
+
display: flex;
|
|
116
|
+
align-items: center;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.dtable-ui.file-formatter .file-item-icon {
|
|
120
|
+
display: inline-block;
|
|
121
|
+
height: 28px;
|
|
122
|
+
width: 28px;
|
|
123
|
+
border: 1px solid #f0f0f0;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.dtable-ui.file-formatter .file-item-count {
|
|
127
|
+
display: inline-block;
|
|
128
|
+
padding: 0 3px;
|
|
129
|
+
min-width: 14px;
|
|
130
|
+
line-height: 14px;
|
|
131
|
+
font-size: 12px;
|
|
132
|
+
border-radius: 6px;
|
|
133
|
+
text-align: center;
|
|
134
|
+
text-overflow: ellipsis;
|
|
135
|
+
white-space: nowrap;
|
|
136
|
+
color: #fff;
|
|
137
|
+
background-color: #999;
|
|
138
|
+
-webkit-transform: translate(-50%, 8px) scale(.8);
|
|
139
|
+
transform: translate(-50%, 8px) scale(.8);
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
|
|
143
|
+
.dtable-ui.image-formatter {
|
|
144
|
+
display: flex;
|
|
145
|
+
align-items: center;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
.dtable-ui.image-formatter .image-item {
|
|
149
|
+
display: inline-block;
|
|
150
|
+
height: 28px;
|
|
151
|
+
width: 28px;
|
|
152
|
+
margin-right: 4px;
|
|
153
|
+
border: 1px solid #f0f0f0;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.dtable-ui.image-formatter .image-item:hover {
|
|
157
|
+
border: 1px solid #c9c9c9;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.dtable-ui.image-formatter .image-item-count {
|
|
161
|
+
display: inline-block;
|
|
162
|
+
padding: 0 3px;
|
|
163
|
+
min-width: 14px;
|
|
164
|
+
line-height: 14px;
|
|
165
|
+
font-size: 12px;
|
|
166
|
+
border-radius: 6px;
|
|
167
|
+
text-align: center;
|
|
168
|
+
text-overflow: ellipsis;
|
|
169
|
+
white-space: nowrap;
|
|
170
|
+
color: #fff;
|
|
171
|
+
background-color: #999;
|
|
172
|
+
-webkit-transform: translate(-50%, 8px) scale(.8);
|
|
173
|
+
transform: translate(-50%, 8px) scale(.8);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.dtable-ui.link-formmatter {
|
|
177
|
+
display: inline-flex;
|
|
178
|
+
align-items: center;
|
|
179
|
+
overflow: hidden;
|
|
180
|
+
flex-wrap: nowrap;
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
.dtable-ui.link-formatter .link-item {
|
|
184
|
+
display: inline-flex;
|
|
185
|
+
height: 20px;
|
|
186
|
+
max-width: 230px;
|
|
187
|
+
padding: 0 8px 0 2px;
|
|
188
|
+
align-items: center;
|
|
189
|
+
font-size: 13px;
|
|
190
|
+
margin-right: 10px;
|
|
191
|
+
border-radius: 3px;
|
|
192
|
+
background: #eceff4;
|
|
193
|
+
cursor: pointer;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
.dtable-ui.link-formatter .link-item .link-name {
|
|
197
|
+
overflow: hidden;
|
|
198
|
+
white-space: nowrap;
|
|
199
|
+
text-overflow: ellipsis;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
/*
|
|
203
|
+
* url formatter
|
|
204
|
+
* email formatter
|
|
205
|
+
*/
|
|
206
|
+
|
|
207
|
+
.dtable-ui.url-formatter,
|
|
208
|
+
.dtable-ui.email-formatter {
|
|
209
|
+
text-decoration: underline;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
.dtable-ui.formula-formatter.multiple .formula-formatter-content-item {
|
|
213
|
+
display: inline-flex;
|
|
214
|
+
margin-right: 10px;
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
|
|
218
|
+
.dtable-ui.formula-formatter.multiple .formula-formatter-content-item.simple-cell-formatter {
|
|
219
|
+
height: 20px;
|
|
220
|
+
padding: 0 8px;
|
|
221
|
+
align-items: center;
|
|
222
|
+
background: #eceff4;
|
|
223
|
+
border-radius: 3px;
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
.dtable-ui.formula-formatter.multiple .formula-formatter-content-item .collaborator {
|
|
227
|
+
margin-right: 0;
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
/* button */
|
|
231
|
+
.dtable-ui.button-formatter {
|
|
232
|
+
height: 26px;
|
|
233
|
+
width: 80px;
|
|
234
|
+
padding: 5px 8px;
|
|
235
|
+
border-width: 1px;
|
|
236
|
+
border-style: solid;
|
|
237
|
+
border-radius: 3px;
|
|
238
|
+
overflow: hidden;
|
|
239
|
+
white-space: nowrap;
|
|
240
|
+
text-overflow: ellipsis;
|
|
241
|
+
}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-date {
|
|
2
|
+
width: 28px;
|
|
3
|
+
height: 30px;
|
|
4
|
+
border-radius: 50%;
|
|
5
|
+
font-size: 14px;
|
|
6
|
+
line-height: 30px;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-date-panel {
|
|
10
|
+
width: 100%;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-selected-day .rc-calendar-date {
|
|
14
|
+
background-color: #FcEcD9;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-date:hover,
|
|
18
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-year-panel-year:hover,
|
|
19
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-month-panel-cell .rc-calendar-month-panel-month:hover {
|
|
20
|
+
background-color: #FcEcD9;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-selected-date .rc-calendar-date,
|
|
24
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-selected-date .rc-calendar-date:hover,
|
|
25
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-year-panel-selected-cell .rc-calendar-year-panel-year,
|
|
26
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-month-panel-selected-cell .rc-calendar-month-panel-month {
|
|
27
|
+
background-color: #f09f3f;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-next-year-btn:not([href]):not([tabindex]),
|
|
31
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-prev-year-btn:not([href]):not([tabindex]),
|
|
32
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-next-month-btn:not([href]):not([tabindex]),
|
|
33
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-prev-month-btn:not([href]):not([tabindex]) {
|
|
34
|
+
color: #999;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-next-year-btn:not([href]):not([tabindex]):hover,
|
|
38
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-prev-year-btn:not([href]):not([tabindex]):hover,
|
|
39
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-next-month-btn:not([href]):not([tabindex]):hover,
|
|
40
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-prev-month-btn:not([href]):not([tabindex]):hover {
|
|
41
|
+
color: #666;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-today .rc-calendar-date {
|
|
45
|
+
border: none;
|
|
46
|
+
position: relative;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rc-calendar-today .rc-calendar-date::after {
|
|
50
|
+
content: '';
|
|
51
|
+
background: #f09f3f;
|
|
52
|
+
position: absolute;
|
|
53
|
+
width: 4px;
|
|
54
|
+
height: 4px;
|
|
55
|
+
border-radius: 50%;
|
|
56
|
+
left: 45%;
|
|
57
|
+
bottom: 0%;
|
|
58
|
+
display: inline-block;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar .rdg-editor-container input.editor-main[readonly] {
|
|
62
|
+
background-color: #fff;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-time-picker {
|
|
66
|
+
z-index: 1;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-right-panel-body ul li.highlight {
|
|
70
|
+
margin: 0;
|
|
71
|
+
border: none;
|
|
72
|
+
background-color: #fff;
|
|
73
|
+
font-size: 12px;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar {
|
|
77
|
+
box-shadow: none;
|
|
78
|
+
border-radius: 0px;
|
|
79
|
+
border: 1px solid #e9e9e9;
|
|
80
|
+
border-left: none;
|
|
81
|
+
border-right: none;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-date {
|
|
85
|
+
font-size: 14px;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-date-panel {
|
|
89
|
+
width: 100%;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-body {
|
|
93
|
+
height: 22rem;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-table tr {
|
|
97
|
+
height: 3rem;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-prev-month-btn,
|
|
101
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-next-month-btn,
|
|
102
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-prev-year-btn,
|
|
103
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-next-year-btn {
|
|
104
|
+
font-size: 30px;
|
|
105
|
+
width: 50px;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-header {
|
|
109
|
+
border-bottom: none;
|
|
110
|
+
margin-top: 0.5rem;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-year-select,
|
|
114
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-month-select,
|
|
115
|
+
.dtable-ui.mb-date-editor-picker .rc-calendar-day-select {
|
|
116
|
+
font-size: 16px;
|
|
117
|
+
padding: 5px;
|
|
118
|
+
}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
.dtable-ui-component.mobile-image-previewer .ril-prev-button,
|
|
2
|
+
.dtable-ui-component.mobile-image-previewer .ril-next-button,
|
|
3
|
+
.dtable-ui-component.mobile-image-previewer .ril-caption .ril-zoom-in,
|
|
4
|
+
.dtable-ui-component.mobile-image-previewer .ril-caption .ril-zoom-out {
|
|
5
|
+
display: none;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.dtable-ui-component.mobile-image-previewer .ril-toolbar .ril__toolbarRightSide {
|
|
9
|
+
padding-right: 14px;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.dtable-ui-component.image-footer-choice.mobile-image-footer-choice {
|
|
13
|
+
height: 100px;
|
|
14
|
+
background-color: #000;
|
|
15
|
+
z-index: 1052;
|
|
16
|
+
padding: 0;
|
|
17
|
+
width: 100%;
|
|
18
|
+
border-radius: 2px;
|
|
19
|
+
border-top-right-radius: 0;
|
|
20
|
+
border-top-left-radius: 0;
|
|
21
|
+
bottom: 0;
|
|
22
|
+
position: absolute;
|
|
23
|
+
color: #fff;
|
|
24
|
+
background: rgba(0, 0, 0, 0.6);
|
|
25
|
+
display: flex;
|
|
26
|
+
justify-content: space-between;
|
|
27
|
+
align-items: center;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.dtable-ui-component.image-footer-choice.mobile-image-footer-choice .image-footer-icon {
|
|
31
|
+
width: 100%;
|
|
32
|
+
display: flex;
|
|
33
|
+
align-items: center;
|
|
34
|
+
justify-content: space-between;
|
|
35
|
+
flex-direction: row-reverse;
|
|
36
|
+
margin: 0 20px;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.dtable-ui-component.image-footer-choice.mobile-image-footer-choice .image-footer-icon .image-footer-choice-item {
|
|
40
|
+
height: 40px;
|
|
41
|
+
width: 40px;
|
|
42
|
+
border-radius: 5px;
|
|
43
|
+
background-color: #333;
|
|
44
|
+
cursor: pointer;
|
|
45
|
+
display: flex;
|
|
46
|
+
justify-content: center;
|
|
47
|
+
align-items: center;
|
|
48
|
+
color: #dbdbdb;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.dtable-ui-component.image-footer-choice.mobile-image-footer-choice .image-footer-icon .image-footer-choice-item i {
|
|
52
|
+
font-size: 20px;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.ril__outer .ril-caption button.dtable-font {
|
|
56
|
+
height: 50px;
|
|
57
|
+
font-size: 20px;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.ril__outer .ril-toolbar button.dtable-font {
|
|
61
|
+
border: none;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.ril__outer .ril-toolbar button.dtable-font:focus {
|
|
65
|
+
outline: none;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.ril__outer button.dtable-font {
|
|
69
|
+
font-size: 16px;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.ril__outer .ril-toolbar .ril-close {
|
|
73
|
+
width: 30px;
|
|
74
|
+
height: 53px;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.ril__outer .ril__toolbarItem {
|
|
78
|
+
height: 50px;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
.ril__outer .ril__toolbarItem button {
|
|
82
|
+
opacity: 0.7;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.ril__outer .ril__toolbarItem button:hover {
|
|
86
|
+
opacity: 1;
|
|
87
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/** loading **/
|
|
2
|
+
@-moz-keyframes loading {
|
|
3
|
+
0% {
|
|
4
|
+
-moz-transform: rotate(0deg);
|
|
5
|
+
transform: rotate(0deg);
|
|
6
|
+
}
|
|
7
|
+
100% {
|
|
8
|
+
-moz-transform: rotate(360deg);
|
|
9
|
+
transform: rotate(360deg);
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
@-webkit-keyframes loading {
|
|
14
|
+
0% {
|
|
15
|
+
-webkit-transform: rotate(0deg);
|
|
16
|
+
transform: rotate(0deg);
|
|
17
|
+
}
|
|
18
|
+
100% {
|
|
19
|
+
-webkit-transform: rotate(360deg);
|
|
20
|
+
transform: rotate(360deg);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
@keyframes loading {
|
|
25
|
+
0% {
|
|
26
|
+
-moz-transform: rotate(0deg);
|
|
27
|
+
-ms-transform: rotate(0deg);
|
|
28
|
+
-webkit-transform: rotate(0deg);
|
|
29
|
+
transform: rotate(0deg);
|
|
30
|
+
}
|
|
31
|
+
100% {
|
|
32
|
+
-moz-transform: rotate(360deg);
|
|
33
|
+
-ms-transform: rotate(360deg);
|
|
34
|
+
-webkit-transform: rotate(360deg);
|
|
35
|
+
transform: rotate(360deg);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.loading-icon {
|
|
40
|
+
display: inline-block;
|
|
41
|
+
width: 20px;
|
|
42
|
+
height: 20px;
|
|
43
|
+
border: 2px solid #eee;
|
|
44
|
+
border-left-color: #aaa;
|
|
45
|
+
border-radius: 50%;
|
|
46
|
+
-moz-animation: loading 0.9s infinite linear;
|
|
47
|
+
-webkit-animation: loading 0.9s infinite linear;
|
|
48
|
+
animation: loading 0.9s infinite linear;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.loading-tip {
|
|
52
|
+
display: block;
|
|
53
|
+
margin: 0 auto;
|
|
54
|
+
}
|
package/es/index.js
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { setLocale } from './lang';
|
|
2
|
+
export { formatDateToString, formatNumberToString, formatStringToNumber, formatNumberString } from './utils/value-format-utils';
|
|
3
|
+
export { default as Loading } from './components/loading';
|
|
4
|
+
export { TextFormatter, NumberFormatter, CheckboxFormatter, DateFormatter, SingleSelectFormatter, MultipleSelectFormatter, CollaboratorFormatter, ImageFormatter, FileFormatter, LongTextFormatter, GeolocationFormatter, LinkFormatter, FormulaFormatter, CTimeFormatter, CreatorFormatter, LastModifierFormatter, MTimeFormatter, AutoNumberFormatter, UrlFormatter, EmailFormatter, DurationFormatter, RateFormatter, ButtonFormatter, FileItemFormatter, ImagePreviewerLightbox } from './components/cell-formatter';
|
|
5
|
+
export { TextEditor, NumberEditor, CheckboxEditor, SingleSelectEdtior, CollaboratorEditor, DateEditor, LinkEditor } from './components/cell-editor';
|
package/es/lang/index.js
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import de from '../locals/de';
|
|
2
|
+
import en from '../locals/en';
|
|
3
|
+
import fr from '../locals/fr';
|
|
4
|
+
import zh_CN from '../locals/zh-CN';
|
|
5
|
+
var langData = {
|
|
6
|
+
'de': de,
|
|
7
|
+
'en': en,
|
|
8
|
+
'fr': fr,
|
|
9
|
+
'zh-cn': zh_CN
|
|
10
|
+
};
|
|
11
|
+
var LANGUAGE = 'en';
|
|
12
|
+
var LANGUAGE_MAP = {};
|
|
13
|
+
export function setLocale(args) {
|
|
14
|
+
var lang = typeof args === 'string' ? args : LANGUAGE;
|
|
15
|
+
LANGUAGE_MAP = langData[lang] || langData[LANGUAGE];
|
|
16
|
+
}
|
|
17
|
+
export function getLocale(key, def) {
|
|
18
|
+
if (!key) return def;
|
|
19
|
+
|
|
20
|
+
if (!LANGUAGE_MAP[key]) {
|
|
21
|
+
return def || key;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
return LANGUAGE_MAP[key];
|
|
25
|
+
}
|
|
26
|
+
export function substitute(str, obj) {
|
|
27
|
+
if (typeof str === 'string') {
|
|
28
|
+
if (str.indexOf('{') < 0) {
|
|
29
|
+
return str;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
return str.replace(/\\?\{([^{}]+)\}/g, function (match, name) {
|
|
33
|
+
if (match.charAt(0) === '\\') {
|
|
34
|
+
return match.slice(1);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
return obj[name] === null || obj[name] === undefined ? '' : obj[name];
|
|
38
|
+
});
|
|
39
|
+
} else if (typeof str === 'function') {
|
|
40
|
+
var val = str(obj);
|
|
41
|
+
|
|
42
|
+
if (val === obj && typeof val === 'object') {
|
|
43
|
+
val = Object.assign({}, obj);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
return val;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
return '';
|
|
50
|
+
}
|
package/es/locals/de.js
ADDED
package/es/locals/en.js
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
var en = {
|
|
2
|
+
Add_an_option: "Add an option",
|
|
3
|
+
Find_an_option: "Find a option",
|
|
4
|
+
No_options_available: "No options available",
|
|
5
|
+
Current_option: "Current option",
|
|
6
|
+
No_option: "No option",
|
|
7
|
+
Choose_an_option: "Choose an option",
|
|
8
|
+
Add_a_collaborator: "Add a collaborator",
|
|
9
|
+
Find_a_collaborator: "Find a collaborator",
|
|
10
|
+
No_collaborators_available: "No collaborators available",
|
|
11
|
+
Done: 'Done',
|
|
12
|
+
Choose_a_collaborator: "Choose a collaborator",
|
|
13
|
+
Please_input: "Please input",
|
|
14
|
+
Please_select: "Please select",
|
|
15
|
+
Clear: "Clear"
|
|
16
|
+
};
|
|
17
|
+
export default en;
|
package/es/locals/fr.js
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
var zh_CN = {
|
|
2
|
+
Add_an_option: '添加一个选项',
|
|
3
|
+
Find_an_option: "查找标签",
|
|
4
|
+
No_options_available: "没有找到标签。",
|
|
5
|
+
Current_option: "当前标签",
|
|
6
|
+
No_option: "没有标签",
|
|
7
|
+
Choose_an_option: "选择一个标签",
|
|
8
|
+
Add_a_collaborator: "添加协作者",
|
|
9
|
+
Find_a_collaborator: "查找协作者",
|
|
10
|
+
No_collaborators_available: "没有找到协作者",
|
|
11
|
+
Done: '完成',
|
|
12
|
+
Choose_a_collaborator: "选择一个协作者",
|
|
13
|
+
Please_input: "请输入",
|
|
14
|
+
Please_select: "请选择",
|
|
15
|
+
Clear: "清空"
|
|
16
|
+
};
|
|
17
|
+
export default zh_CN;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export var DEFAULT = 'default';
|
|
2
|
+
export var NUMBER = 'number';
|
|
3
|
+
export var TEXT = 'text';
|
|
4
|
+
export var CHECKBOX = 'checkbox';
|
|
5
|
+
export var DATE = 'date';
|
|
6
|
+
export var SINGLE_SELECT = 'single-select';
|
|
7
|
+
export var LONG_TEXT = 'long-text';
|
|
8
|
+
export var IMAGE = 'image';
|
|
9
|
+
export var FILE = 'file';
|
|
10
|
+
export var MULTIPLE_SELECT = 'multiple-select';
|
|
11
|
+
export var COLLABORATOR = 'collaborator';
|
|
12
|
+
export var LINK = 'link';
|
|
13
|
+
export var FORMULA = 'formula';
|
|
14
|
+
export var LINK_FORMULA = 'link-formula';
|
|
15
|
+
export var CREATOR = 'creator';
|
|
16
|
+
export var CTIME = 'ctime';
|
|
17
|
+
export var LAST_MODIFIER = 'last-modifier';
|
|
18
|
+
export var MTIME = 'mtime';
|
|
19
|
+
export var GEOLOCATION = 'geolocation';
|
|
20
|
+
export var AUTO_NUMBER = 'auto-number';
|
|
21
|
+
export var URL = 'url';
|
|
22
|
+
export var EMAIL = 'email';
|
|
23
|
+
export var DURATION = 'duration';
|
|
24
|
+
export var RATE = 'rate';
|
|
25
|
+
export var BUTTON = 'button';
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
2
|
+
|
|
3
|
+
var _DURATION_ZERO_DISPLA, _DURATION_DECIMAL_DIG;
|
|
4
|
+
|
|
5
|
+
export var NUMBER_TYPES = {
|
|
6
|
+
'NUMBER': 'number',
|
|
7
|
+
'NUMBER_WITH_COMMAS': 'number-with-commas',
|
|
8
|
+
'PERCENT': 'percent',
|
|
9
|
+
'YUAN': 'yuan',
|
|
10
|
+
'EURO': 'euro',
|
|
11
|
+
'DOLLAR': 'dollar'
|
|
12
|
+
};
|
|
13
|
+
export var DATE_TYPES = {
|
|
14
|
+
'D/M/YYYY': 'D/M/YYYY',
|
|
15
|
+
'D/M/YYYY HH:mm': 'D/M/YYYY HH:mm',
|
|
16
|
+
'M/D/YYYY': 'M/D/YY',
|
|
17
|
+
'M/D/YYYY HH:mm': 'M/D/YYYY HH:mm',
|
|
18
|
+
'YYYY-MM-DD': 'YYYY-MM-DD',
|
|
19
|
+
'YYYY-MM-DD HH:mm': 'YYYY-MM-DD HH:mm'
|
|
20
|
+
};
|
|
21
|
+
export var FORMULA_RESULT_TYPE = {
|
|
22
|
+
NUMBER: 'number',
|
|
23
|
+
STRING: 'string',
|
|
24
|
+
DATE: 'date',
|
|
25
|
+
BOOL: 'bool',
|
|
26
|
+
COLUMN: 'column'
|
|
27
|
+
};
|
|
28
|
+
export var DEFAULT_NUMBER_FORMAT = 'number';
|
|
29
|
+
export var DURATION_FORMATS_MAP = {
|
|
30
|
+
H_MM: 'h:mm',
|
|
31
|
+
H_MM_SS: 'h:mm:ss'
|
|
32
|
+
};
|
|
33
|
+
export var DURATION_FORMATS = [{
|
|
34
|
+
name: DURATION_FORMATS_MAP.H_MM,
|
|
35
|
+
type: DURATION_FORMATS_MAP.H_MM
|
|
36
|
+
}, {
|
|
37
|
+
name: DURATION_FORMATS_MAP.H_MM_SS,
|
|
38
|
+
type: DURATION_FORMATS_MAP.H_MM_SS
|
|
39
|
+
}];
|
|
40
|
+
export var DURATION_ZERO_DISPLAY = (_DURATION_ZERO_DISPLA = {}, _defineProperty(_DURATION_ZERO_DISPLA, DURATION_FORMATS_MAP.H_MM, '0:00'), _defineProperty(_DURATION_ZERO_DISPLA, DURATION_FORMATS_MAP.H_MM_SS, '0:00'), _DURATION_ZERO_DISPLA);
|
|
41
|
+
export var DURATION_DECIMAL_DIGITS = (_DURATION_DECIMAL_DIG = {}, _defineProperty(_DURATION_DECIMAL_DIG, DURATION_FORMATS_MAP.H_MM, 0), _defineProperty(_DURATION_DECIMAL_DIG, DURATION_FORMATS_MAP.H_MM_SS, 0), _DURATION_DECIMAL_DIG);
|