x4js 2.2.42 → 2.2.43

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "x4js",
3
- "version": "2.2.42",
3
+ "version": "2.2.43",
4
4
  "type": "module",
5
5
  "main": "src/x4.ts",
6
6
  "module": "src/x4.ts",
@@ -113,7 +113,8 @@
113
113
  .empty {
114
114
  position: relative;
115
115
  left: 50%;
116
- top: 20%;
116
+ top: 30px;
117
+ transform: translateX(-50%);
117
118
  width: fit-content;
118
119
 
119
120
  #icon {
@@ -64,6 +64,20 @@
64
64
  &> .x4viewport {
65
65
  overflow: hidden;
66
66
  display: table;
67
+
68
+ .empty {
69
+ position: relative;
70
+ left: 50%;
71
+ top: 30px;
72
+ transform: translateX(-50%);
73
+ width: fit-content;
74
+
75
+ #icon {
76
+ height: 64px;
77
+ fill: var( --accent-background );
78
+ opacity: 50%;
79
+ }
80
+ }
67
81
  }
68
82
 
69
83
  .x4item {
@@ -125,9 +125,7 @@ export class Listbox extends Component<ListboxProps,ListboxEvents> {
125
125
  contextmenu: (e) => this._on_ctx_menu(e),
126
126
  } );
127
127
 
128
- if( props.items ) {
129
- this.setItems( props.items, false );
130
- }
128
+ this.setItems( props.items, false );
131
129
  }
132
130
 
133
131
  /**
@@ -58,6 +58,20 @@
58
58
  position: relative;
59
59
 
60
60
  &> .x4viewport {
61
+ .empty {
62
+ position: relative;
63
+ left: 50%;
64
+ top: 30px;
65
+ transform: translateX(-50%);
66
+ width: fit-content;
67
+
68
+ #icon {
69
+ height: 64px;
70
+ fill: var( --accent-background );
71
+ opacity: 50%;
72
+ }
73
+ }
74
+
61
75
  // child + subitems
62
76
  .x4ctreeviewitem {
63
77
  &>.label {
@@ -206,9 +206,7 @@ export class Treeview extends Component<TreeviewProps,TreeviewEvents> {
206
206
  keydown: ( ev ) => this._onkey( ev ),
207
207
  });
208
208
 
209
- if( props.items ) {
210
- this.setItems( props.items );
211
- }
209
+ this.setItems( props.items );
212
210
  }
213
211
 
214
212
  /**