neo.mjs 7.5.0 → 7.6.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.
@@ -20,9 +20,9 @@ class ServiceWorker extends ServiceBase {
20
20
  */
21
21
  singleton: true,
22
22
  /**
23
- * @member {String} version='7.5.0'
23
+ * @member {String} version='7.6.0'
24
24
  */
25
- version: '7.5.0'
25
+ version: '7.6.0'
26
26
  }
27
27
 
28
28
  /**
@@ -1,4 +1,5 @@
1
1
  import Component from '../../../../src/controller/Component.mjs';
2
+ import NeoArray from '../../../../src/util/Array.mjs';
2
3
 
3
4
  /**
4
5
  * @class Portal.view.examples.TabContainerController
@@ -20,6 +21,21 @@ class TabContainerController extends Component {
20
21
  }
21
22
  }
22
23
 
24
+ /**
25
+ * We need to store the current positions, since drag&drop resorting of tabs is enabled
26
+ * @member {String[]} tabItems
27
+ */
28
+ tabItems = ['devmode', 'dist_dev', 'dist_prod']
29
+
30
+ /**
31
+ *
32
+ */
33
+ onComponentConstructed() {
34
+ let me = this;
35
+
36
+ me.component.on('moveTo', me.onMoveTab, me)
37
+ }
38
+
23
39
  /**
24
40
  * @param {Object} params
25
41
  * @param {Object} value
@@ -28,13 +44,23 @@ class TabContainerController extends Component {
28
44
  onExamplesRoute(params, value, oldValue) {
29
45
  let me = this,
30
46
  itemId = params?.itemId || 'dist_prod',
47
+ index = me.tabItems.indexOf(itemId),
31
48
  store = me.getReference(`examples-${itemId.replace('_', '-')}-list`).store;
32
49
 
33
50
  if (store?.getCount() < 1) {
34
51
  store.load()
35
52
  }
36
53
 
37
- me.component.activeIndex = itemId === 'dist_prod' ? 2 : itemId === 'dist_dev' ? 1 : 0
54
+ me.component.activeIndex = index
55
+ }
56
+
57
+ /**
58
+ * @param {Object} data
59
+ * @param {Number} data.fromIndex
60
+ * @param {Number} data.toIndex
61
+ */
62
+ onMoveTab({fromIndex, toIndex}) {
63
+ NeoArray.move(this.tabItems, fromIndex, toIndex)
38
64
  }
39
65
  }
40
66
 
@@ -111,7 +111,7 @@ class FooterContainer extends Container {
111
111
  }, {
112
112
  module: Component,
113
113
  cls : ['neo-version'],
114
- html : 'v7.5.0'
114
+ html : 'v7.6.0'
115
115
  }]
116
116
  }],
117
117
  /**
@@ -20,9 +20,9 @@ class ServiceWorker extends ServiceBase {
20
20
  */
21
21
  singleton: true,
22
22
  /**
23
- * @member {String} version='7.5.0'
23
+ * @member {String} version='7.6.0'
24
24
  */
25
- version: '7.5.0'
25
+ version: '7.6.0'
26
26
  }
27
27
 
28
28
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "neo.mjs",
3
- "version": "7.5.0",
3
+ "version": "7.6.0",
4
4
  "description": "The webworkers driven UI framework",
5
5
  "type": "module",
6
6
  "repository": {
@@ -1,3 +1,9 @@
1
+ @property --portal-blog-list-gradient-end {
2
+ syntax : "<color>";
3
+ initial-value: #333;
4
+ inherits : false;
5
+ }
6
+
1
7
  @property --portal-blog-list-gradient-start {
2
8
  syntax : "<color>";
3
9
  initial-value: #777;
@@ -5,8 +11,6 @@
5
11
  }
6
12
 
7
13
  .portal-blog-list.neo-list {
8
- --portal-blog-list-gradient-end: #333;
9
-
10
14
  transition: padding var(--portal-transition-duration) ease-out;
11
15
 
12
16
  .neo-list-item {
@@ -33,6 +37,12 @@
33
37
  .preview-image {
34
38
  --portal-blog-list-gradient-start: #3E63DD;
35
39
  }
40
+
41
+ &:focus {
42
+ .preview-image {
43
+ --portal-blog-list-gradient-end: darkgreen;
44
+ }
45
+ }
36
46
  }
37
47
 
38
48
  .content {
@@ -118,7 +128,10 @@
118
128
  background-position : 50% 50%;
119
129
  background-size : cover;
120
130
  height : 100%;
121
- transition : --portal-blog-list-gradient-start var(--portal-transition-duration) ease-out;
131
+
132
+ transition:
133
+ --portal-blog-list-gradient-end var(--portal-transition-duration) ease-out,
134
+ --portal-blog-list-gradient-start var(--portal-transition-duration) ease-out;
122
135
  }
123
136
  }
124
137
 
@@ -1,3 +1,9 @@
1
+ @property --portal-examples-list-gradient-end {
2
+ syntax : "<color>";
3
+ initial-value: #333;
4
+ inherits : false;
5
+ }
6
+
1
7
  @property --portal-examples-list-gradient-start {
2
8
  syntax : "<color>";
3
9
  initial-value: #777;
@@ -5,8 +11,6 @@
5
11
  }
6
12
 
7
13
  .portal-examples-list.neo-list {
8
- --portal-examples-list-gradient-end: #333;
9
-
10
14
  transition: padding var(--portal-transition-duration) ease-out;
11
15
 
12
16
  .neo-list-item {
@@ -32,6 +36,12 @@
32
36
  .preview-image {
33
37
  --portal-examples-list-gradient-start: #3E63DD;
34
38
  }
39
+
40
+ &:focus {
41
+ .preview-image {
42
+ --portal-examples-list-gradient-end: darkgreen;
43
+ }
44
+ }
35
45
  }
36
46
 
37
47
  .content {
@@ -121,7 +131,10 @@
121
131
  background-blend-mode: overlay;
122
132
  background-size : cover;
123
133
  height : 100%;
124
- transition : --portal-examples-list-gradient-start var(--portal-transition-duration) ease-out;
134
+
135
+ transition:
136
+ --portal-examples-list-gradient-end var(--portal-transition-duration) ease-out,
137
+ --portal-examples-list-gradient-start var(--portal-transition-duration) ease-out;
125
138
  }
126
139
  }
127
140
 
@@ -262,12 +262,12 @@ const DefaultConfig = {
262
262
  useVdomWorker: true,
263
263
  /**
264
264
  * buildScripts/injectPackageVersion.mjs will update this value
265
- * @default '7.5.0'
265
+ * @default '7.6.0'
266
266
  * @memberOf! module:Neo
267
267
  * @name config.version
268
268
  * @type String
269
269
  */
270
- version: '7.5.0'
270
+ version: '7.6.0'
271
271
  };
272
272
 
273
273
  Object.assign(DefaultConfig, {