jsl-ui 9.26.7 → 9.27.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.
@@ -19,8 +19,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
19
19
  });
20
20
  };
21
21
  var __generator = (this && this.__generator) || function (thisArg, body) {
22
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
23
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
22
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
23
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
24
24
  function verb(n) { return function (v) { return step([n, v]); }; }
25
25
  function step(op) {
26
26
  if (f) throw new TypeError("Generator is already executing.");
@@ -21,5 +21,6 @@ export declare class NumberComponent<T = any> implements IJSLComponent {
21
21
  render(): IJSLVNode;
22
22
  getValue(): string;
23
23
  getValueAsNumber(): number;
24
+ setValue(value: number): void;
24
25
  onCreate(node: IJSLVNode): void;
25
26
  }
@@ -68,6 +68,16 @@ var NumberComponent = /** @class */ (function () {
68
68
  NumberComponent.prototype.getValueAsNumber = function () {
69
69
  return numeric.parse(this.getValue());
70
70
  };
71
+ NumberComponent.prototype.setValue = function (value) {
72
+ var _a;
73
+ if (this.currentDom != null) {
74
+ this.currentDom.value = numeric.format(value, this.options.format);
75
+ }
76
+ if (this.options.bindMode !== "fromModel" && this.options.bindTo && this.options.property) {
77
+ this.options.bindTo[this.options.property] =
78
+ this.options.bindTo[this.options.property] = ((_a = this.options.converter) === null || _a === void 0 ? void 0 : _a.toData) ? this.options.converter.toData(value) : value;
79
+ }
80
+ };
71
81
  NumberComponent.prototype.onCreate = function (node) {
72
82
  var _this = this;
73
83
  this.currentDom = node.dom;
@@ -8,8 +8,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
8
8
  });
9
9
  };
10
10
  var __generator = (this && this.__generator) || function (thisArg, body) {
11
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
12
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
11
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
12
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
13
13
  function verb(n) { return function (v) { return step([n, v]); }; }
14
14
  function step(op) {
15
15
  if (f) throw new TypeError("Generator is already executing.");
@@ -19,8 +19,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
19
19
  });
20
20
  };
21
21
  var __generator = (this && this.__generator) || function (thisArg, body) {
22
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
23
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
22
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
23
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
24
24
  function verb(n) { return function (v) { return step([n, v]); }; }
25
25
  function step(op) {
26
26
  if (f) throw new TypeError("Generator is already executing.");
@@ -4296,9 +4296,7 @@ export function SlickGrid(container, data, columns, options) {
4296
4296
  // read column number from .l<columnNumber> CSS class
4297
4297
  var cls = /l\d+/.exec(cellNode.className);
4298
4298
  if (!cls) {
4299
- console.warn("getCellFromNode: cannot get cell - " + cellNode.className);
4300
- return null;
4301
- // throw new Error("getCellFromNode: cannot get cell - " + cellNode.className);
4299
+ throw new Error("getCellFromNode: cannot get cell - " + cellNode.className);
4302
4300
  }
4303
4301
  return parseInt(cls[0].substr(1, cls[0].length - 1), 10);
4304
4302
  }
package/lib/grid.css CHANGED
@@ -1,6 +1,6 @@
1
1
  .slick-header.ui-state-default, .slick-headerrow.ui-state-default, .slick-footerrow.ui-state-default, .slick-top-panel-scroller.ui-state-default, .slick-group-header.ui-state-default {
2
- width: 100%;
3
2
  background: #fff;
3
+ width: 100%;
4
4
  position: relative;
5
5
  overflow: auto;
6
6
  border-left: 0 !important;
@@ -10,7 +10,15 @@
10
10
  overflow: inherit;
11
11
  }
12
12
 
13
- .slick-header::-webkit-scrollbar, .slick-headerrow::-webkit-scrollbar, .slick-footerrow::-webkit-scrollbar {
13
+ .slick-header::-webkit-scrollbar {
14
+ display: none;
15
+ }
16
+
17
+ .slick-headerrow::-webkit-scrollbar {
18
+ display: none;
19
+ }
20
+
21
+ .slick-footerrow::-webkit-scrollbar {
14
22
  display: none;
15
23
  }
16
24
 
@@ -23,10 +31,10 @@
23
31
 
24
32
  .slick-header-column.ui-state-default, .slick-group-header-column.ui-state-default {
25
33
  text-overflow: ellipsis;
26
- height: 20px;
27
34
  float: left;
28
35
  border-top: 1px solid silver;
29
36
  border-right: 1px solid silver;
37
+ height: 20px;
30
38
  margin: 0;
31
39
  padding: 4px;
32
40
  line-height: 20px;
@@ -57,18 +65,18 @@
57
65
  }
58
66
 
59
67
  .slick-sort-indicator {
68
+ float: left;
60
69
  width: 8px;
61
70
  height: 5px;
62
- float: left;
63
71
  margin-top: 6px;
64
72
  margin-left: 4px;
65
73
  }
66
74
 
67
75
  .slick-sort-indicator-numbered {
68
- width: 8px;
69
- height: 5px;
70
76
  float: left;
71
77
  color: #6190cd;
78
+ width: 8px;
79
+ height: 5px;
72
80
  margin-top: 0;
73
81
  margin-left: 4px;
74
82
  font-style: normal;
@@ -76,18 +84,14 @@
76
84
  line-height: 20px;
77
85
  }
78
86
 
79
- .slick-sortable-placeholder {
80
- background: silver;
81
- }
82
-
83
87
  .grid-canvas {
84
88
  outline: 0;
85
89
  position: relative;
86
90
  }
87
91
 
88
92
  .slick-row.ui-widget-content, .slick-row.ui-state-active {
89
- width: 100%;
90
93
  border: 0;
94
+ width: 100%;
91
95
  position: absolute;
92
96
  }
93
97
 
@@ -145,8 +149,8 @@
145
149
  }
146
150
 
147
151
  .slick-reorder-guide {
148
- height: 2px;
149
152
  opacity: .7;
153
+ height: 2px;
150
154
  filter: alpha(opacity= 70);
151
155
  background: #00f;
152
156
  display: inline-block;
@@ -159,8 +163,8 @@
159
163
  }
160
164
 
161
165
  .slick-pane {
162
- width: 100%;
163
166
  outline: 0;
167
+ width: 100%;
164
168
  position: absolute;
165
169
  overflow: hidden;
166
170
  }
@@ -179,9 +183,9 @@
179
183
  }
180
184
 
181
185
  .slick-viewport {
182
- width: 100%;
183
186
  background: #fff;
184
187
  outline: 0;
188
+ width: 100%;
185
189
  position: relative;
186
190
  }
187
191
 
@@ -190,12 +194,12 @@
190
194
  }
191
195
 
192
196
  input.editor-text, textarea.editor-text {
193
- width: 100%;
194
- height: 100%;
195
197
  resize: none;
196
198
  background: none;
197
199
  border: 0;
198
200
  outline: 0;
201
+ width: 100%;
202
+ height: 100%;
199
203
  margin: 0;
200
204
  padding: 0;
201
205
  }
@@ -252,8 +256,8 @@ input.editor-text, textarea.editor-text {
252
256
  }
253
257
 
254
258
  .js-touch .slick-header-column.resizable > .rs-r {
255
- width: 1.2rem;
256
259
  background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAYCAYAAACbU/80AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsIAAA7CARUoSoA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;
260
+ width: 1.2rem;
257
261
  }
258
262
 
259
263
  .js-touch .slick-header-menubutton.resize-offset {
@@ -285,13 +289,9 @@ input.editor-text, textarea.editor-text {
285
289
  }
286
290
 
287
291
  .slick-headerrow-column {
288
- height: 100%;
289
292
  background: #fafafa;
290
293
  border-bottom: 0;
291
- }
292
-
293
- .slick-row.ui-state-active {
294
- background: #f5f7d7;
294
+ height: 100%;
295
295
  }
296
296
 
297
297
  .slick-row {
@@ -320,9 +320,9 @@ input.editor-text, textarea.editor-text {
320
320
  }
321
321
 
322
322
  .slick-group-toggle {
323
+ vertical-align: middle;
323
324
  width: 20px;
324
325
  height: 20px;
325
- vertical-align: middle;
326
326
  margin-right: 5px;
327
327
  }
328
328
 
@@ -398,10 +398,10 @@ input.editor-text, textarea.editor-text {
398
398
  }
399
399
 
400
400
  .resizable > .rs-r {
401
- width: .5rem;
402
401
  box-sizing: border-box;
403
402
  cursor: w-resize;
404
403
  background: #14141433;
404
+ width: .5rem;
405
405
  position: absolute;
406
406
  top: 0;
407
407
  bottom: 0;
@@ -409,10 +409,10 @@ input.editor-text, textarea.editor-text {
409
409
  }
410
410
 
411
411
  .resizable > .rs-b {
412
- height: .5rem;
413
412
  box-sizing: border-box;
414
413
  cursor: n-resize;
415
414
  background: #14141433;
415
+ height: .5rem;
416
416
  position: absolute;
417
417
  bottom: 0;
418
418
  left: 0;
@@ -428,12 +428,12 @@ input.editor-text, textarea.editor-text {
428
428
  }
429
429
 
430
430
  .slick-header-menubutton {
431
- width: 14px;
432
431
  cursor: pointer;
433
432
  background-image: url("data:image/gif;base64,R0lGODlhDgAOAIABADtKYwAAACH5BAEAAAEALAAAAAAOAA4AAAISjI+py+0PHZgUsGobhTn6DxoFADs=");
434
433
  background-position: 0;
435
434
  background-repeat: no-repeat;
436
435
  border-left: thin ridge silver;
436
+ width: 14px;
437
437
  display: none;
438
438
  position: absolute;
439
439
  top: 0;
@@ -465,11 +465,11 @@ input.editor-text, textarea.editor-text {
465
465
  }
466
466
 
467
467
  .slick-header-menuicon {
468
- width: 16px;
469
- height: 16px;
470
468
  vertical-align: middle;
471
469
  background-position: center;
472
470
  background-repeat: no-repeat;
471
+ width: 16px;
472
+ height: 16px;
473
473
  margin-right: 4px;
474
474
  display: inline-block;
475
475
  }
@@ -485,9 +485,9 @@ input.editor-text, textarea.editor-text {
485
485
 
486
486
  .slick-header-menuitem.slick-header-menuitem-divider {
487
487
  cursor: default;
488
- height: 1px;
489
488
  background-color: #cecece;
490
489
  border: none;
490
+ height: 1px;
491
491
  margin: 8px 2px;
492
492
  padding: 0;
493
493
  overflow: hidden;
@@ -529,11 +529,11 @@ input.editor-text, textarea.editor-text {
529
529
  .slick-header-button {
530
530
  float: right;
531
531
  vertical-align: top;
532
- height: 15px;
533
- width: 15px;
534
532
  cursor: pointer;
535
533
  background-position: center;
536
534
  background-repeat: no-repeat;
535
+ width: 15px;
536
+ height: 15px;
537
537
  margin: 1px 2rem 100px 1px;
538
538
  display: inline-block;
539
539
  }
@@ -562,12 +562,12 @@ input.editor-text, textarea.editor-text {
562
562
  .jsl-dialog .jsl-button {
563
563
  vertical-align: middle;
564
564
  cursor: pointer;
565
- height: 2rem;
566
565
  box-sizing: border-box;
567
566
  letter-spacing: .1rem;
568
567
  text-align: center;
569
568
  white-space: nowrap;
570
569
  border-radius: .3rem;
570
+ height: 2rem;
571
571
  padding: 0 1rem;
572
572
  line-height: 2rem;
573
573
  text-decoration: none;
@@ -576,11 +576,11 @@ input.editor-text, textarea.editor-text {
576
576
 
577
577
  .dlg-close-btn {
578
578
  color: #555;
579
- width: 2.5rem;
580
579
  box-sizing: border-box;
581
580
  cursor: pointer;
582
581
  background: #d8d8d8;
583
582
  border-top-right-radius: .8rem;
583
+ width: 2.5rem;
584
584
  font-size: 2rem;
585
585
  font-weight: bold;
586
586
  line-height: 2.8rem;
@@ -597,20 +597,20 @@ input.editor-text, textarea.editor-text {
597
597
 
598
598
  .jsl-dialog-overlay {
599
599
  z-index: 2001;
600
- height: 100vh;
601
600
  background: #000c;
601
+ height: 100vh;
602
602
  position: fixed;
603
603
  inset: 0;
604
604
  }
605
605
 
606
606
  .jsl-dialog > .dlg-header {
607
607
  box-sizing: content-box;
608
- height: 2rem;
609
608
  text-align: center;
610
609
  background: #f8f8f8;
611
610
  border-bottom: 1px solid #ededed;
612
611
  border-top-left-radius: .8rem;
613
612
  border-top-right-radius: .8rem;
613
+ height: 2rem;
614
614
  padding: .6rem;
615
615
  font-size: 1.5rem;
616
616
  position: relative;
@@ -624,13 +624,13 @@ input.editor-text, textarea.editor-text {
624
624
  }
625
625
 
626
626
  .jsl-dialog > .dlg-footer {
627
- height: 3rem;
628
627
  box-sizing: border-box;
629
628
  text-align: right;
630
629
  background: #f8f8f8;
631
630
  border-top: 1px solid #ededed;
632
- border-bottom-left-radius: .8rem;
633
631
  border-bottom-right-radius: .8rem;
632
+ border-bottom-left-radius: .8rem;
633
+ height: 3rem;
634
634
  padding: .5rem;
635
635
  position: absolute;
636
636
  bottom: 0;
@@ -669,12 +669,12 @@ input.editor-text, textarea.editor-text {
669
669
  }
670
670
 
671
671
  .handle-overlay {
672
- width: 2px;
673
- height: 2px;
674
672
  z-index: 20;
675
673
  cursor: crosshair;
676
674
  background-color: #217346;
677
675
  border: 1px solid #fff;
676
+ width: 2px;
677
+ height: 2px;
678
678
  padding: 3px;
679
679
  position: absolute;
680
680
  }
@@ -684,20 +684,18 @@ input.editor-text, textarea.editor-text {
684
684
  border: 2px solid #217346;
685
685
  }
686
686
 
687
-
688
-
689
687
  .slick-cell .jsl-toggle {
690
688
  color: #888;
691
- width: 1.2em;
692
689
  box-sizing: border-box;
693
690
  cursor: pointer;
691
+ width: 1.2em;
694
692
  height: 100%;
695
693
  display: inline-block;
696
694
  }
697
695
 
698
696
  .slick-cell .jsl-toggle-spacer {
699
- min-width: 1.2em;
700
697
  box-sizing: border-box;
698
+ min-width: 1.2em;
701
699
  display: inline-block;
702
700
  }
703
701
 
@@ -705,5 +703,4 @@ input.editor-text, textarea.editor-text {
705
703
  display: inline-block;
706
704
  position: relative;
707
705
  }
708
-
709
706
  /*# sourceMappingURL=index.css.map */