@seafile/seafile-calendar 0.1.2-beta.0 → 1.0.0-alpha.0
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/assets/index.css +177 -144
- package/es/Calendar.js +124 -69
- package/es/calendar/CalendarRightPanel.js +193 -63
- package/es/date/DateInput.js +0 -1
- package/es/time/TimeInput.js +206 -0
- package/lib/Calendar.js +127 -69
- package/lib/calendar/CalendarRightPanel.js +193 -63
- package/lib/date/DateInput.js +0 -1
- package/lib/time/TimeInput.js +234 -0
- package/package.json +1 -1
package/assets/index.css
CHANGED
|
@@ -8,17 +8,13 @@
|
|
|
8
8
|
display: none;
|
|
9
9
|
}
|
|
10
10
|
.rc-calendar-input-wrap {
|
|
11
|
+
width: 100%;
|
|
11
12
|
position: relative;
|
|
12
|
-
padding: 6px;
|
|
13
|
-
border-bottom: 1px solid #e9e9e9;
|
|
14
13
|
}
|
|
15
14
|
.rc-calendar-input-wrap:after {
|
|
16
15
|
content: '';
|
|
17
16
|
clear: both;
|
|
18
17
|
}
|
|
19
|
-
.rc-calendar-date-input-wrap {
|
|
20
|
-
overflow: hidden;
|
|
21
|
-
}
|
|
22
18
|
.rc-calendar-time-picker {
|
|
23
19
|
position: absolute;
|
|
24
20
|
width: 100%;
|
|
@@ -87,7 +83,7 @@
|
|
|
87
83
|
margin: 0;
|
|
88
84
|
}
|
|
89
85
|
.rc-calendar-clear-btn:after {
|
|
90
|
-
content:
|
|
86
|
+
content: 'x';
|
|
91
87
|
font-size: 12px;
|
|
92
88
|
color: #aaa;
|
|
93
89
|
display: inline-block;
|
|
@@ -209,11 +205,11 @@
|
|
|
209
205
|
.rc-calendar {
|
|
210
206
|
position: relative;
|
|
211
207
|
outline: none;
|
|
212
|
-
font-family: Arial,
|
|
208
|
+
font-family: Arial, 'Hiragino Sans GB', 'Microsoft Yahei', 'Microsoft Sans Serif', 'WenQuanYi Micro Hei', sans-serif;
|
|
213
209
|
width: -moz-fit-content;
|
|
214
210
|
width: fit-content;
|
|
215
211
|
list-style: none;
|
|
216
|
-
font-size:
|
|
212
|
+
font-size: 14px;
|
|
217
213
|
text-align: left;
|
|
218
214
|
background-color: #fff;
|
|
219
215
|
border-radius: 3px;
|
|
@@ -221,28 +217,98 @@
|
|
|
221
217
|
background-clip: padding-box;
|
|
222
218
|
border: 1px solid #ccc;
|
|
223
219
|
line-height: 1.5;
|
|
220
|
+
/* Layout wrappers */
|
|
221
|
+
/* Top inputs row */
|
|
222
|
+
/* Shared header text input */
|
|
223
|
+
/* Date grid area */
|
|
224
|
+
/* Right time panel */
|
|
225
|
+
/* Footer */
|
|
226
|
+
}
|
|
227
|
+
.rc-calendar-panel {
|
|
228
|
+
display: -ms-flexbox;
|
|
229
|
+
display: flex;
|
|
230
|
+
-ms-flex-direction: column;
|
|
231
|
+
flex-direction: column;
|
|
224
232
|
}
|
|
225
|
-
.rc-calendar-date-panel,
|
|
226
233
|
.rc-calendar-date-panel-container {
|
|
227
234
|
display: -ms-flexbox;
|
|
228
235
|
display: flex;
|
|
229
236
|
}
|
|
230
|
-
.rc-calendar-date-panel
|
|
231
|
-
.rc-calendar-panel {
|
|
232
|
-
position: relative;
|
|
233
|
-
outline: none;
|
|
237
|
+
.rc-calendar-date-panel {
|
|
234
238
|
display: block;
|
|
239
|
+
min-width: 288px;
|
|
235
240
|
}
|
|
236
|
-
.rc-calendar-
|
|
237
|
-
|
|
241
|
+
.rc-calendar-inputs {
|
|
242
|
+
display: -ms-flexbox;
|
|
243
|
+
display: flex;
|
|
244
|
+
-ms-flex-align: stretch;
|
|
245
|
+
align-items: stretch;
|
|
246
|
+
border-bottom: 1px solid #eee;
|
|
238
247
|
}
|
|
239
|
-
.rc-calendar-
|
|
240
|
-
|
|
248
|
+
.rc-calendar-date-input-col {
|
|
249
|
+
-ms-flex: 1 1 auto;
|
|
250
|
+
flex: 1 1 auto;
|
|
251
|
+
}
|
|
252
|
+
.rc-calendar-time-input-col {
|
|
253
|
+
width: 122px;
|
|
254
|
+
border-left: 1px solid #ccc;
|
|
255
|
+
}
|
|
256
|
+
.rc-calendar-date-input,
|
|
257
|
+
.rc-calendar-time-input-outer {
|
|
258
|
+
display: -ms-flexbox;
|
|
259
|
+
display: flex;
|
|
260
|
+
-ms-flex-align: center;
|
|
261
|
+
align-items: center;
|
|
262
|
+
height: 100%;
|
|
263
|
+
}
|
|
264
|
+
.rc-calendar-date-input {
|
|
265
|
+
padding: 10px;
|
|
266
|
+
}
|
|
267
|
+
.rc-calendar-time-input-outer {
|
|
268
|
+
padding: 10px;
|
|
269
|
+
width: 100%;
|
|
270
|
+
}
|
|
271
|
+
.rc-calendar-date-input input {
|
|
272
|
+
height: 30px;
|
|
273
|
+
width: 100%;
|
|
274
|
+
padding: 4px 10px;
|
|
275
|
+
border: 1px solid #d9d9d9;
|
|
276
|
+
border-radius: 3px;
|
|
277
|
+
line-height: 1.5;
|
|
278
|
+
}
|
|
279
|
+
.rc-calendar-date-input input:hover {
|
|
280
|
+
border-color: #ed7109;
|
|
281
|
+
}
|
|
282
|
+
.rc-calendar-date-input input:focus {
|
|
283
|
+
border-color: #ed7109;
|
|
284
|
+
box-shadow: 0 0 3px #ed7109;
|
|
285
|
+
outline: none;
|
|
286
|
+
}
|
|
287
|
+
.rc-calendar-text-input {
|
|
288
|
+
height: 30px;
|
|
289
|
+
display: inline-block;
|
|
290
|
+
width: 100%;
|
|
291
|
+
margin: 0;
|
|
292
|
+
padding: 4px 10px;
|
|
293
|
+
border-radius: 6px;
|
|
294
|
+
border: 1px solid #d9d9d9;
|
|
295
|
+
background: #fff;
|
|
296
|
+
color: #666;
|
|
297
|
+
line-height: 1.5;
|
|
298
|
+
transition: border 0.3s, background 0.3s, box-shadow 0.3s;
|
|
299
|
+
}
|
|
300
|
+
.rc-calendar-text-input:hover {
|
|
301
|
+
border-color: #ed7109;
|
|
302
|
+
}
|
|
303
|
+
.rc-calendar-text-input:focus {
|
|
304
|
+
border-color: #ed7109;
|
|
305
|
+
box-shadow: 0 0 3px #ed7109;
|
|
306
|
+
outline: none;
|
|
241
307
|
}
|
|
242
308
|
.rc-calendar-header {
|
|
243
309
|
padding: 0 10px;
|
|
244
|
-
height:
|
|
245
|
-
line-height:
|
|
310
|
+
height: 40px;
|
|
311
|
+
line-height: 40px;
|
|
246
312
|
text-align: center;
|
|
247
313
|
-moz-user-select: none;
|
|
248
314
|
-ms-user-select: none;
|
|
@@ -251,46 +317,46 @@
|
|
|
251
317
|
border-bottom: 1px solid #ccc;
|
|
252
318
|
}
|
|
253
319
|
.rc-calendar-header > a {
|
|
254
|
-
font-weight:
|
|
320
|
+
font-weight: 600;
|
|
255
321
|
display: inline-block;
|
|
256
|
-
padding:
|
|
257
|
-
line-height:
|
|
322
|
+
padding: 0 5px;
|
|
323
|
+
line-height: 40px;
|
|
258
324
|
text-align: center;
|
|
259
325
|
width: 30px;
|
|
260
326
|
}
|
|
261
327
|
.rc-calendar-header > a:hover {
|
|
262
328
|
cursor: pointer;
|
|
263
|
-
color: #
|
|
329
|
+
color: #ed7109;
|
|
264
330
|
}
|
|
265
|
-
.rc-calendar-
|
|
331
|
+
.rc-calendar-prev-month-btn {
|
|
266
332
|
position: absolute;
|
|
267
333
|
left: 25px;
|
|
268
334
|
}
|
|
269
|
-
.rc-calendar-
|
|
335
|
+
.rc-calendar-prev-month-btn:after {
|
|
270
336
|
content: '‹';
|
|
271
337
|
}
|
|
272
|
-
.rc-calendar-
|
|
338
|
+
.rc-calendar-next-month-btn {
|
|
273
339
|
position: absolute;
|
|
274
340
|
right: 25px;
|
|
275
341
|
}
|
|
276
|
-
.rc-calendar-
|
|
342
|
+
.rc-calendar-next-month-btn:after {
|
|
277
343
|
content: '›';
|
|
278
344
|
}
|
|
279
345
|
.rc-calendar-year-select,
|
|
280
346
|
.rc-calendar-month-select,
|
|
281
347
|
.rc-calendar-day-select {
|
|
282
348
|
display: inline-block;
|
|
283
|
-
font-size:
|
|
284
|
-
font-weight:
|
|
285
|
-
color: #
|
|
349
|
+
font-size: 14px;
|
|
350
|
+
font-weight: 600;
|
|
351
|
+
color: #212529;
|
|
286
352
|
padding: 0 8px;
|
|
287
|
-
line-height:
|
|
353
|
+
line-height: 40px;
|
|
288
354
|
}
|
|
289
355
|
.rc-calendar-year-select:hover,
|
|
290
356
|
.rc-calendar-month-select:hover,
|
|
291
357
|
.rc-calendar-day-select:hover {
|
|
292
358
|
cursor: pointer;
|
|
293
|
-
color: #
|
|
359
|
+
color: #ed7109;
|
|
294
360
|
}
|
|
295
361
|
.rc-calendar-year-select.rc-calendar-time-status:hover,
|
|
296
362
|
.rc-calendar-month-select.rc-calendar-time-status:hover,
|
|
@@ -306,17 +372,17 @@
|
|
|
306
372
|
top: 0;
|
|
307
373
|
cursor: pointer;
|
|
308
374
|
color: #999;
|
|
309
|
-
font-family: Arial,
|
|
375
|
+
font-family: Arial, 'Hiragino Sans GB', 'Microsoft Yahei', 'Microsoft Sans Serif', sans-serif;
|
|
310
376
|
padding: 0 5px;
|
|
311
377
|
font-size: 16px;
|
|
312
378
|
display: inline-block;
|
|
313
|
-
line-height:
|
|
379
|
+
line-height: 40px;
|
|
314
380
|
}
|
|
315
381
|
.rc-calendar-prev-month-btn:hover,
|
|
316
382
|
.rc-calendar-next-month-btn:hover,
|
|
317
383
|
.rc-calendar-prev-year-btn:hover,
|
|
318
384
|
.rc-calendar-next-year-btn:hover {
|
|
319
|
-
color: #
|
|
385
|
+
color: #ed7109;
|
|
320
386
|
}
|
|
321
387
|
.rc-calendar-next-year-btn {
|
|
322
388
|
right: 0;
|
|
@@ -331,67 +397,8 @@
|
|
|
331
397
|
content: '«';
|
|
332
398
|
}
|
|
333
399
|
.rc-calendar-body {
|
|
334
|
-
padding:
|
|
335
|
-
height:
|
|
336
|
-
}
|
|
337
|
-
.rc-calendar-right-panel {
|
|
338
|
-
width: 68px;
|
|
339
|
-
height: inherit;
|
|
340
|
-
}
|
|
341
|
-
.rc-calendar-right-panel-header {
|
|
342
|
-
height: 34px;
|
|
343
|
-
line-height: 34px;
|
|
344
|
-
}
|
|
345
|
-
.rc-calendar-right-panel-header span {
|
|
346
|
-
transform: rotate(-90deg);
|
|
347
|
-
}
|
|
348
|
-
.rc-calendar-right-panel-body {
|
|
349
|
-
height: 217px;
|
|
350
|
-
border-left: 1px solid #ccc;
|
|
351
|
-
overflow-y: scroll;
|
|
352
|
-
}
|
|
353
|
-
.rc-calendar-right-panel-body ul {
|
|
354
|
-
list-style: none;
|
|
355
|
-
box-sizing: border-box;
|
|
356
|
-
margin: 0;
|
|
357
|
-
padding: 0;
|
|
358
|
-
width: 100%;
|
|
359
|
-
}
|
|
360
|
-
.rc-calendar-right-panel-body ul li {
|
|
361
|
-
text-align: center;
|
|
362
|
-
padding: 8px 0;
|
|
363
|
-
cursor: pointer;
|
|
364
|
-
}
|
|
365
|
-
.rc-calendar-right-panel-body ul li:hover {
|
|
366
|
-
color: #e8bf6a;
|
|
367
|
-
}
|
|
368
|
-
.rc-calendar-right-panel-body .rc-calendar-selected-time {
|
|
369
|
-
color: #f09f3f;
|
|
370
|
-
}
|
|
371
|
-
.rc-calendar-right-panel-body::-webkit-scrollbar {
|
|
372
|
-
width: 0;
|
|
373
|
-
}
|
|
374
|
-
.rc-calendar-right-panel-footer {
|
|
375
|
-
height: 39px;
|
|
376
|
-
line-height: 34px;
|
|
377
|
-
border-left: 1px solid #ccc;
|
|
378
|
-
}
|
|
379
|
-
.rc-calendar-right-panel-footer span {
|
|
380
|
-
transform: rotate(90deg);
|
|
381
|
-
}
|
|
382
|
-
.rc-calendar-right-panel-header,
|
|
383
|
-
.rc-calendar-right-panel-footer {
|
|
384
|
-
display: -ms-flexbox;
|
|
385
|
-
display: flex;
|
|
386
|
-
-ms-flex-pack: center;
|
|
387
|
-
justify-content: center;
|
|
388
|
-
cursor: pointer;
|
|
389
|
-
color: #999;
|
|
390
|
-
font-size: 16px;
|
|
391
|
-
}
|
|
392
|
-
.rc-calendar-right-panel-header span:after,
|
|
393
|
-
.rc-calendar-right-panel-footer span:after {
|
|
394
|
-
content: '›';
|
|
400
|
+
padding: 8px 18px;
|
|
401
|
+
height: 268px;
|
|
395
402
|
}
|
|
396
403
|
.rc-calendar table {
|
|
397
404
|
border-collapse: collapse;
|
|
@@ -411,30 +418,31 @@
|
|
|
411
418
|
}
|
|
412
419
|
.rc-calendar-column-header {
|
|
413
420
|
line-height: 18px;
|
|
414
|
-
|
|
415
|
-
width:
|
|
421
|
+
height: 36px;
|
|
422
|
+
width: 36px;
|
|
416
423
|
text-align: center;
|
|
417
424
|
}
|
|
418
|
-
.rc-calendar-column-header
|
|
425
|
+
.rc-calendar-column-header-inner {
|
|
419
426
|
display: block;
|
|
420
427
|
font-weight: normal;
|
|
428
|
+
color: #999;
|
|
421
429
|
}
|
|
422
430
|
.rc-calendar-week-number-header .rc-calendar-column-header-inner {
|
|
423
431
|
display: none;
|
|
424
432
|
}
|
|
425
433
|
.rc-calendar-cell {
|
|
426
|
-
|
|
434
|
+
height: 36px;
|
|
427
435
|
}
|
|
428
436
|
.rc-calendar-date {
|
|
429
437
|
display: block;
|
|
430
438
|
margin: 0 auto;
|
|
431
|
-
color: #
|
|
432
|
-
border-radius: 4px
|
|
433
|
-
width:
|
|
434
|
-
height:
|
|
439
|
+
color: #212529;
|
|
440
|
+
border-radius: 4px;
|
|
441
|
+
width: 24px;
|
|
442
|
+
height: 24px;
|
|
435
443
|
padding: 0;
|
|
436
444
|
background: transparent;
|
|
437
|
-
line-height:
|
|
445
|
+
line-height: 24px;
|
|
438
446
|
text-align: center;
|
|
439
447
|
}
|
|
440
448
|
.rc-calendar-date:hover {
|
|
@@ -442,17 +450,15 @@
|
|
|
442
450
|
cursor: pointer;
|
|
443
451
|
}
|
|
444
452
|
.rc-calendar-selected-day .rc-calendar-date {
|
|
445
|
-
background: #
|
|
453
|
+
background: #ed7109;
|
|
454
|
+
color: #fff;
|
|
446
455
|
}
|
|
447
456
|
.rc-calendar-selected-date .rc-calendar-date {
|
|
448
|
-
background: #
|
|
457
|
+
background: #ed7109;
|
|
449
458
|
color: #fff;
|
|
450
459
|
}
|
|
451
460
|
.rc-calendar-selected-date .rc-calendar-date:hover {
|
|
452
|
-
background: #
|
|
453
|
-
}
|
|
454
|
-
.rc-calendar-today .rc-calendar-date {
|
|
455
|
-
border: 1px solid #f09f3f;
|
|
461
|
+
background: #ed7109;
|
|
456
462
|
}
|
|
457
463
|
.rc-calendar-disabled-cell .rc-calendar-date {
|
|
458
464
|
cursor: not-allowed;
|
|
@@ -476,34 +482,65 @@
|
|
|
476
482
|
.rc-calendar-next-month-btn-day .rc-calendar-date {
|
|
477
483
|
color: #bbb;
|
|
478
484
|
}
|
|
479
|
-
.rc-calendar-
|
|
480
|
-
|
|
481
|
-
|
|
485
|
+
.rc-calendar-right-panel {
|
|
486
|
+
height: inherit;
|
|
487
|
+
border-left: 1px solid #ccc;
|
|
488
|
+
}
|
|
489
|
+
.rc-calendar-right-panel-time-header {
|
|
490
|
+
height: 40px;
|
|
491
|
+
line-height: 40px;
|
|
482
492
|
text-align: center;
|
|
483
|
-
|
|
493
|
+
font-weight: 600;
|
|
494
|
+
color: #212529;
|
|
495
|
+
border-bottom: 1px solid #eee;
|
|
484
496
|
}
|
|
485
|
-
.rc-calendar-
|
|
486
|
-
|
|
497
|
+
.rc-calendar-right-panel-body {
|
|
498
|
+
height: 268px;
|
|
499
|
+
display: -ms-flexbox;
|
|
500
|
+
display: flex;
|
|
501
|
+
padding: 4px;
|
|
487
502
|
}
|
|
488
|
-
.rc-calendar-
|
|
489
|
-
|
|
503
|
+
.rc-calendar-right-panel-col {
|
|
504
|
+
overflow-y: auto;
|
|
490
505
|
}
|
|
491
|
-
.rc-calendar-
|
|
492
|
-
|
|
506
|
+
.rc-calendar-right-panel-col:last-child {
|
|
507
|
+
border-left: 1px solid #eee;
|
|
493
508
|
}
|
|
494
|
-
.rc-calendar-
|
|
495
|
-
|
|
509
|
+
.rc-calendar-right-panel-col ul {
|
|
510
|
+
list-style: none;
|
|
511
|
+
margin: 0;
|
|
512
|
+
padding: 4px;
|
|
496
513
|
}
|
|
497
|
-
.rc-calendar-
|
|
498
|
-
|
|
499
|
-
|
|
514
|
+
.rc-calendar-right-panel-item {
|
|
515
|
+
width: 48px;
|
|
516
|
+
height: 28px;
|
|
517
|
+
line-height: 28px;
|
|
518
|
+
text-align: center;
|
|
519
|
+
cursor: pointer;
|
|
520
|
+
color: #212529;
|
|
521
|
+
font-weight: 400;
|
|
522
|
+
border-radius: 3px;
|
|
500
523
|
}
|
|
501
|
-
.rc-calendar-
|
|
502
|
-
|
|
503
|
-
padding-left: 12px;
|
|
524
|
+
.rc-calendar-right-panel-item:hover {
|
|
525
|
+
background: rgba(237, 113, 9, 0.1);
|
|
504
526
|
}
|
|
505
|
-
.rc-calendar-
|
|
506
|
-
|
|
527
|
+
.rc-calendar-right-panel-item-selected {
|
|
528
|
+
background: rgba(237, 113, 9, 0.1);
|
|
529
|
+
border-radius: 3px;
|
|
530
|
+
color: #212529;
|
|
531
|
+
}
|
|
532
|
+
.rc-calendar-right-panel-col::-webkit-scrollbar {
|
|
533
|
+
width: 0;
|
|
534
|
+
height: 0;
|
|
535
|
+
}
|
|
536
|
+
.rc-calendar-footer {
|
|
537
|
+
border-top: 1px solid #ccc;
|
|
538
|
+
padding: 8px 0;
|
|
539
|
+
text-align: center;
|
|
540
|
+
position: relative;
|
|
541
|
+
}
|
|
542
|
+
.rc-calendar-footer-show-ok {
|
|
543
|
+
text-align: right;
|
|
507
544
|
}
|
|
508
545
|
.rc-calendar-footer-btn:after {
|
|
509
546
|
content: 'x';
|
|
@@ -520,7 +557,7 @@
|
|
|
520
557
|
.rc-calendar-time-picker-btn {
|
|
521
558
|
display: inline-block;
|
|
522
559
|
text-align: center;
|
|
523
|
-
color: #
|
|
560
|
+
color: #ed7109;
|
|
524
561
|
}
|
|
525
562
|
.rc-calendar-today-btn:hover,
|
|
526
563
|
.rc-calendar-ok-btn:hover,
|
|
@@ -533,34 +570,30 @@
|
|
|
533
570
|
.rc-calendar-time-picker-btn-disabled {
|
|
534
571
|
color: #bbb;
|
|
535
572
|
}
|
|
536
|
-
.rc-calendar-today-btn-disabled:hover,
|
|
537
|
-
.rc-calendar-ok-btn-disabled:hover,
|
|
538
|
-
.rc-calendar-time-picker-btn-disabled:hover {
|
|
539
|
-
color: #bbb;
|
|
540
|
-
}
|
|
541
573
|
.rc-calendar-today-btn {
|
|
542
|
-
padding-left:
|
|
574
|
+
padding-left: 0;
|
|
575
|
+
font-weight: 600;
|
|
543
576
|
}
|
|
544
577
|
.rc-calendar-time-input {
|
|
545
|
-
height:
|
|
578
|
+
height: 30px;
|
|
546
579
|
position: relative;
|
|
547
580
|
display: inline-block;
|
|
548
581
|
margin: 0 0;
|
|
549
582
|
padding: 4px 10px;
|
|
550
|
-
border-radius:
|
|
583
|
+
border-radius: 3px;
|
|
551
584
|
border: 1px solid #d9d9d9;
|
|
552
585
|
background-color: #ffffff;
|
|
553
586
|
color: #666;
|
|
554
587
|
line-height: 1.5;
|
|
555
588
|
transform: border 0.3s cubic-bezier(0.35, 0, 0.25, 1), background 0.3s cubic-bezier(0.35, 0, 0.25, 1), box-shadow 0.3s cubic-bezier(0.35, 0, 0.25, 1);
|
|
556
|
-
width:
|
|
589
|
+
width: 100%;
|
|
557
590
|
}
|
|
558
591
|
.rc-calendar-time-input:hover {
|
|
559
|
-
border-color: #
|
|
592
|
+
border-color: #ed7109;
|
|
560
593
|
}
|
|
561
594
|
.rc-calendar-time-input:focus {
|
|
562
|
-
border-color: #
|
|
563
|
-
box-shadow: 0 0 3px #
|
|
595
|
+
border-color: #ed7109;
|
|
596
|
+
box-shadow: 0 0 3px #ed7109;
|
|
564
597
|
}
|
|
565
598
|
.rc-calendar-time-panel {
|
|
566
599
|
left: 0;
|