neo.mjs 6.10.17 → 6.12.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/apps/ServiceWorker.mjs +2 -2
- package/examples/ServiceWorker.mjs +2 -2
- package/package.json +2 -2
- package/resources/scss/src/tree/List.scss +10 -5
- package/src/DefaultConfig.mjs +2 -2
- package/src/Main.mjs +20 -2
- package/src/Neo.mjs +41 -10
- package/src/component/Base.mjs +18 -7
- package/src/core/Base.mjs +10 -1
- package/src/core/Util.mjs +0 -10
- package/src/form/field/Select.mjs +1 -1
- package/src/form/field/Text.mjs +2 -1
- package/src/list/Base.mjs +4 -5
- package/src/main/addon/AmCharts.mjs +10 -16
- package/src/main/addon/AnalyticsByGoogle.mjs +5 -11
- package/src/main/addon/Base.mjs +26 -0
- package/src/main/addon/CesiumJS.mjs +5 -11
- package/src/main/addon/CloneNode.mjs +8 -13
- package/src/main/addon/Cookie.mjs +5 -11
- package/src/main/addon/DragDrop.mjs +5 -11
- package/src/main/addon/GoogleMaps.mjs +7 -13
- package/src/main/addon/HighlightJS.mjs +4 -10
- package/src/main/addon/LocalStorage.mjs +5 -11
- package/src/main/addon/MapboxGL.mjs +16 -22
- package/src/main/addon/Markdown.mjs +5 -11
- package/src/main/addon/Mwc.mjs +4 -10
- package/src/main/addon/Navigator.mjs +13 -13
- package/src/main/addon/Popover.mjs +7 -12
- package/src/main/addon/PrefixField.mjs +18 -25
- package/src/main/addon/ResizeObserver.mjs +5 -10
- package/src/main/addon/ServiceWorker.mjs +5 -11
- package/src/main/addon/Siesta.mjs +5 -11
- package/src/main/addon/Stylesheet.mjs +5 -11
- package/src/main/addon/WebComponent.mjs +5 -11
- package/src/main/addon/WindowPosition.mjs +4 -10
- package/src/menu/List.mjs +3 -0
- package/src/selection/ListModel.mjs +6 -1
- package/src/selection/Model.mjs +7 -5
- package/src/tree/Accordion.mjs +3 -2
- package/src/tree/List.mjs +5 -4
package/apps/ServiceWorker.mjs
CHANGED
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "neo.mjs",
|
3
|
-
"version": "6.
|
3
|
+
"version": "6.12.0",
|
4
4
|
"description": "The webworkers driven UI framework",
|
5
5
|
"type": "module",
|
6
6
|
"repository": {
|
@@ -55,7 +55,7 @@
|
|
55
55
|
"inquirer": "^9.2.14",
|
56
56
|
"neo-jsdoc": "1.0.1",
|
57
57
|
"neo-jsdoc-x": "1.0.5",
|
58
|
-
"postcss": "^8.4.
|
58
|
+
"postcss": "^8.4.35",
|
59
59
|
"sass": "^1.70.0",
|
60
60
|
"siesta-lite": "5.5.2",
|
61
61
|
"showdown": "^2.1.0",
|
@@ -1,9 +1,14 @@
|
|
1
1
|
.neo-tree-list {
|
2
|
-
border
|
3
|
-
color
|
4
|
-
display
|
5
|
-
|
6
|
-
|
2
|
+
border : none;
|
3
|
+
color : var(--tree-list-color);
|
4
|
+
display : flex;
|
5
|
+
flex-direction : column;
|
6
|
+
overflow : hidden;
|
7
|
+
position : relative;
|
8
|
+
|
9
|
+
// Allow item's scrollIntoView upwards to avoid
|
10
|
+
// being hidden below a sticky item stuck at the top.
|
11
|
+
scroll-padding-block-start : 3em;
|
7
12
|
|
8
13
|
.neo-list {
|
9
14
|
overflow : visible;
|
package/src/DefaultConfig.mjs
CHANGED
@@ -236,12 +236,12 @@ const DefaultConfig = {
|
|
236
236
|
useVdomWorker: true,
|
237
237
|
/**
|
238
238
|
* buildScripts/injectPackageVersion.mjs will update this value
|
239
|
-
* @default '6.
|
239
|
+
* @default '6.12.0'
|
240
240
|
* @memberOf! module:Neo
|
241
241
|
* @name config.version
|
242
242
|
* @type String
|
243
243
|
*/
|
244
|
-
version: '6.
|
244
|
+
version: '6.12.0'
|
245
245
|
};
|
246
246
|
|
247
247
|
Object.assign(DefaultConfig, {
|
package/src/Main.mjs
CHANGED
@@ -209,7 +209,7 @@ class Main extends core.Base {
|
|
209
209
|
module = await import(`./main/addon/${name}.mjs`)
|
210
210
|
}
|
211
211
|
|
212
|
-
this.
|
212
|
+
this.registerAddon(module.default);
|
213
213
|
|
214
214
|
return true
|
215
215
|
}
|
@@ -254,7 +254,7 @@ class Main extends core.Base {
|
|
254
254
|
me.addon = {};
|
255
255
|
|
256
256
|
modules.forEach(module => {
|
257
|
-
me.
|
257
|
+
me.registerAddon(module.default)
|
258
258
|
});
|
259
259
|
|
260
260
|
WorkerManager.onWorkerConstructed({
|
@@ -370,6 +370,24 @@ class Main extends core.Base {
|
|
370
370
|
window.location.href = data.url;
|
371
371
|
}
|
372
372
|
|
373
|
+
/**
|
374
|
+
* Helper method to register main thread addons
|
375
|
+
* @param {Neo.core.Base} addon Can either be a neo class or instance
|
376
|
+
*/
|
377
|
+
registerAddon(addon) {
|
378
|
+
if (Neo.typeOf(addon) === 'NeoClass') {
|
379
|
+
// Addons could get imported multiple times. Ensure to only create an instance once.
|
380
|
+
if (Neo.typeOf(Neo.ns(addon.prototype.className)) !== 'NeoInstance') {
|
381
|
+
addon = Neo.create(addon)
|
382
|
+
}
|
383
|
+
|
384
|
+
// Main thread addons need to get registered as singletons inside the neo namespace
|
385
|
+
Neo.applyToGlobalNs(addon)
|
386
|
+
}
|
387
|
+
|
388
|
+
this.addon[addon.constructor.name] = addon;
|
389
|
+
}
|
390
|
+
|
373
391
|
/**
|
374
392
|
* Triggers the different DOM operation queues
|
375
393
|
* @protected
|
package/src/Neo.mjs
CHANGED
@@ -1,8 +1,10 @@
|
|
1
1
|
import DefaultConfig from './DefaultConfig.mjs';
|
2
2
|
|
3
|
-
const
|
4
|
-
|
5
|
-
|
3
|
+
const
|
4
|
+
camelRegex = /-./g,
|
5
|
+
configSymbol = Symbol.for('configSymbol'),
|
6
|
+
getSetCache = Symbol('getSetCache'),
|
7
|
+
typeDetector = {
|
6
8
|
function: (item) => {
|
7
9
|
if (item.prototype?.constructor.isClass) {
|
8
10
|
return 'NeoClass'
|
@@ -60,17 +62,19 @@ Neo = globalThis.Neo = Object.assign({
|
|
60
62
|
* @tutorial 02_ClassSystem
|
61
63
|
*/
|
62
64
|
applyClassConfig(cls) {
|
63
|
-
let baseCfg
|
64
|
-
|
65
|
-
|
66
|
-
|
65
|
+
let baseCfg = null,
|
66
|
+
ntypeChain = [],
|
67
|
+
ntypeMap = Neo.ntypeMap,
|
68
|
+
proto = cls.prototype || cls,
|
69
|
+
protos = [],
|
67
70
|
cfg, config, ctor, ntype;
|
68
71
|
|
69
72
|
while (proto.__proto__) {
|
70
73
|
ctor = proto.constructor;
|
71
74
|
|
72
75
|
if (Object.hasOwn(ctor, 'classConfigApplied')) {
|
73
|
-
baseCfg
|
76
|
+
baseCfg = Neo.clone(ctor.config, true);
|
77
|
+
ntypeChain = [...ctor.ntypeChain];
|
74
78
|
break
|
75
79
|
}
|
76
80
|
|
@@ -113,6 +117,8 @@ Neo = globalThis.Neo = Object.assign({
|
|
113
117
|
if (Object.hasOwn(cfg, 'ntype')) {
|
114
118
|
ntype = cfg.ntype;
|
115
119
|
|
120
|
+
ntypeChain.unshift(ntype);
|
121
|
+
|
116
122
|
// Running the docs app inside a workspace can pull in the same classes from different roots,
|
117
123
|
// so we want to check for different class names as well
|
118
124
|
if (Object.hasOwn(ntypeMap, ntype) && cfg.className !== ntypeMap[ntype]) {
|
@@ -136,7 +142,7 @@ Neo = globalThis.Neo = Object.assign({
|
|
136
142
|
applyMixins(ctor, mixins);
|
137
143
|
|
138
144
|
if (Neo.ns('Neo.core.Observable', false, ctor.prototype.mixins)) {
|
139
|
-
ctor.observable = true
|
145
|
+
ctor.observable = true
|
140
146
|
}
|
141
147
|
}
|
142
148
|
|
@@ -148,7 +154,8 @@ Neo = globalThis.Neo = Object.assign({
|
|
148
154
|
Object.assign(ctor, {
|
149
155
|
classConfigApplied: true,
|
150
156
|
config : Neo.clone(config, true),
|
151
|
-
isClass : true
|
157
|
+
isClass : true,
|
158
|
+
ntypeChain
|
152
159
|
});
|
153
160
|
|
154
161
|
!config.singleton && this.applyToGlobalNs(cls)
|
@@ -156,6 +163,10 @@ Neo = globalThis.Neo = Object.assign({
|
|
156
163
|
|
157
164
|
proto = cls.prototype || cls;
|
158
165
|
|
166
|
+
ntypeChain.forEach(ntype => {
|
167
|
+
proto[`is${Neo.capitalize(Neo.camel(ntype))}`] = true
|
168
|
+
});
|
169
|
+
|
159
170
|
if (proto.singleton) {
|
160
171
|
cls = Neo.create(cls);
|
161
172
|
Neo.applyToGlobalNs(cls)
|
@@ -234,6 +245,26 @@ Neo = globalThis.Neo = Object.assign({
|
|
234
245
|
return target
|
235
246
|
},
|
236
247
|
|
248
|
+
/**
|
249
|
+
* Converts kebab-case strings into camel-case
|
250
|
+
* @memberOf module:Neo
|
251
|
+
* @param {String} value The target object
|
252
|
+
* @returns {String}
|
253
|
+
*/
|
254
|
+
camel(value) {
|
255
|
+
return value.replace(camelRegex, match => match[1].toUpperCase())
|
256
|
+
},
|
257
|
+
|
258
|
+
/**
|
259
|
+
* Makes the first character of a string uppercase
|
260
|
+
* @memberOf module:Neo
|
261
|
+
* @param {String} value
|
262
|
+
* @returns {Boolean|String} Returns false for non string inputs
|
263
|
+
*/
|
264
|
+
capitalize(value) {
|
265
|
+
return value[0].toUpperCase() + value.slice(1)
|
266
|
+
},
|
267
|
+
|
237
268
|
/**
|
238
269
|
* @memberOf module:Neo
|
239
270
|
* @param {Object|Array|*} obj
|
package/src/component/Base.mjs
CHANGED
@@ -801,12 +801,6 @@ class Base extends CoreBase {
|
|
801
801
|
}
|
802
802
|
}
|
803
803
|
|
804
|
-
revertFocus() {
|
805
|
-
if (this.containsFocus && this.focusEnterData?.relatedTarget) {
|
806
|
-
Neo.getComponent(this.focusEnterData.relatedTarget.id)?.focus();
|
807
|
-
}
|
808
|
-
}
|
809
|
-
|
810
804
|
/**
|
811
805
|
* Triggered after the reference config got changed
|
812
806
|
* @param {String|null} value
|
@@ -1838,13 +1832,19 @@ class Base extends CoreBase {
|
|
1838
1832
|
this.keys?.register(this)
|
1839
1833
|
}
|
1840
1834
|
|
1835
|
+
/**
|
1836
|
+
* @param {Object} data
|
1837
|
+
*/
|
1841
1838
|
onFocusEnter(data) {
|
1842
1839
|
// If we are hidden, or unmounted while we still contain focus, we have to revert
|
1843
1840
|
// focus to where it came from if possible
|
1844
1841
|
this.focusEnterData = data;
|
1845
1842
|
}
|
1846
1843
|
|
1847
|
-
|
1844
|
+
/**
|
1845
|
+
* @param {Object} data
|
1846
|
+
*/
|
1847
|
+
onFocusLeave(data) {
|
1848
1848
|
this.focusEnterData = null;
|
1849
1849
|
}
|
1850
1850
|
|
@@ -2067,6 +2067,17 @@ class Base extends CoreBase {
|
|
2067
2067
|
}
|
2068
2068
|
}
|
2069
2069
|
|
2070
|
+
/**
|
2071
|
+
*
|
2072
|
+
*/
|
2073
|
+
revertFocus() {
|
2074
|
+
let relatedTarget = this.focusEnterData?.relatedTarget;
|
2075
|
+
|
2076
|
+
if (this.containsFocus && relatedTarget) {
|
2077
|
+
Neo.getComponent(relatedTarget.id)?.focus()
|
2078
|
+
}
|
2079
|
+
}
|
2080
|
+
|
2070
2081
|
/**
|
2071
2082
|
* Change multiple configs at once, ensuring that all afterSet methods get all new assigned values
|
2072
2083
|
* @param {Object} values={}
|
package/src/core/Base.mjs
CHANGED
@@ -327,6 +327,15 @@ class Base {
|
|
327
327
|
return this.constructor[key]
|
328
328
|
}
|
329
329
|
|
330
|
+
/**
|
331
|
+
* Check if a given ntype exists inside the proto chain, including the top level class
|
332
|
+
* @param {String} ntype
|
333
|
+
* @returns {Boolean}
|
334
|
+
*/
|
335
|
+
hasNtype(ntype) {
|
336
|
+
return this.constructor.ntypeChain.includes(ntype)
|
337
|
+
}
|
338
|
+
|
330
339
|
/**
|
331
340
|
* Gets triggered after onConstructed() is done
|
332
341
|
* @see {@link Neo.core.Base#onConstructed onConstructed}
|
@@ -361,7 +370,7 @@ class Base {
|
|
361
370
|
currentWorker = Neo.currentWorker,
|
362
371
|
listenerId;
|
363
372
|
|
364
|
-
if (!me.singleton) {
|
373
|
+
if (!me.singleton && !me.isMainThreadAddon) {
|
365
374
|
throw new Error('Remote method access is only functional for Singleton classes ' + className)
|
366
375
|
}
|
367
376
|
|
package/src/core/Util.mjs
CHANGED
@@ -36,15 +36,6 @@ class Util extends Base {
|
|
36
36
|
});
|
37
37
|
}
|
38
38
|
|
39
|
-
/**
|
40
|
-
* Makes the first character of a string uppercase
|
41
|
-
* @param {String} value
|
42
|
-
* @returns {Boolean|String} Returns false for non string inputs
|
43
|
-
*/
|
44
|
-
static capitalize(value) {
|
45
|
-
return value[0].toUpperCase() + value.slice(1)
|
46
|
-
}
|
47
|
-
|
48
39
|
/**
|
49
40
|
* Transforms a styles string into a styles object using camelcase syntax
|
50
41
|
* @param {String} string The styles string to parse
|
@@ -225,7 +216,6 @@ Neo.applyFromNs(Neo, Util, {
|
|
225
216
|
bindMethods : 'bindMethods',
|
226
217
|
createStyleObject: 'createStyleObject',
|
227
218
|
createStyles : 'createStyles',
|
228
|
-
capitalize : 'capitalize',
|
229
219
|
decamel : 'decamel',
|
230
220
|
isArray : 'isArray',
|
231
221
|
isBoolean : 'isBoolean',
|
@@ -661,7 +661,7 @@ class Select extends Picker {
|
|
661
661
|
cls: ['neo-input-field-wrapper'],
|
662
662
|
cn : [{
|
663
663
|
tag : 'input',
|
664
|
-
autocomplete: '
|
664
|
+
autocomplete: 'no', // while "off" is the correct value, browser vendors ignore it. Arbitrary strings do the trick.
|
665
665
|
autocorrect : 'off',
|
666
666
|
cls : ['neo-textfield-input', 'neo-typeahead-input'],
|
667
667
|
disabled : true,
|
package/src/form/field/Text.mjs
CHANGED
@@ -318,7 +318,8 @@ class Text extends Base {
|
|
318
318
|
* @protected
|
319
319
|
*/
|
320
320
|
afterSetAutoComplete(value, oldValue) {
|
321
|
-
|
321
|
+
// while "off" is the correct value, browser vendors ignore it. Arbitrary strings do the trick.
|
322
|
+
this.changeInputElKey('autocomplete', value ? null : 'no')
|
322
323
|
}
|
323
324
|
|
324
325
|
/**
|
package/src/list/Base.mjs
CHANGED
@@ -411,14 +411,13 @@ class Base extends Component {
|
|
411
411
|
itemContent = me.createItemContent(record, index),
|
412
412
|
itemId = me.getItemId(record[me.getKeyProperty()]),
|
413
413
|
selectionModel = me.selectionModel,
|
414
|
+
isSelected = !me.disableSelection && selectionModel?.isSelected(itemId),
|
414
415
|
item;
|
415
416
|
|
416
417
|
isHeader && cls.push('neo-list-header');
|
417
418
|
|
418
|
-
if (
|
419
|
-
|
420
|
-
cls.push(selectionModel.selectedCls)
|
421
|
-
}
|
419
|
+
if (isSelected){
|
420
|
+
cls.push(selectionModel.selectedCls)
|
422
421
|
}
|
423
422
|
|
424
423
|
if (record.cls) {
|
@@ -432,7 +431,7 @@ class Base extends Component {
|
|
432
431
|
item = {
|
433
432
|
id : itemId,
|
434
433
|
tag : isHeader ? 'dt' : me.itemTagName,
|
435
|
-
'aria-selected' :
|
434
|
+
'aria-selected' : isSelected,
|
436
435
|
cls
|
437
436
|
};
|
438
437
|
|
@@ -1,12 +1,11 @@
|
|
1
|
-
import Base from '
|
1
|
+
import Base from './Base.mjs';
|
2
2
|
import DomAccess from '../DomAccess.mjs';
|
3
3
|
|
4
4
|
/**
|
5
5
|
* Helper class to include amCharts into your neo.mjs app
|
6
6
|
* https://www.amcharts.com/docs/v4/
|
7
7
|
* @class Neo.main.addon.AmCharts
|
8
|
-
* @extends Neo.
|
9
|
-
* @singleton
|
8
|
+
* @extends Neo.main.addon.Base
|
10
9
|
*/
|
11
10
|
class AmCharts extends Base {
|
12
11
|
static config = {
|
@@ -44,16 +43,6 @@ class AmCharts extends Base {
|
|
44
43
|
* @protected
|
45
44
|
*/
|
46
45
|
fallbackPath: 'https://neomjs.github.io/pages/resources/amCharts/',
|
47
|
-
/**
|
48
|
-
* @member {Boolean} scriptsLoaded_=true
|
49
|
-
* @protected
|
50
|
-
*/
|
51
|
-
scriptsLoaded_: false,
|
52
|
-
/**
|
53
|
-
* @member {Boolean} singleton=true
|
54
|
-
* @protected
|
55
|
-
*/
|
56
|
-
singleton: true,
|
57
46
|
/**
|
58
47
|
* Remote method access for other workers
|
59
48
|
* @member {Object} remote={app: [//...]}
|
@@ -68,7 +57,12 @@ class AmCharts extends Base {
|
|
68
57
|
'setProperty',
|
69
58
|
'updateData'
|
70
59
|
]
|
71
|
-
}
|
60
|
+
},
|
61
|
+
/**
|
62
|
+
* @member {Boolean} scriptsLoaded_=true
|
63
|
+
* @protected
|
64
|
+
*/
|
65
|
+
scriptsLoaded_: false
|
72
66
|
}
|
73
67
|
|
74
68
|
/**
|
@@ -278,6 +272,6 @@ class AmCharts extends Base {
|
|
278
272
|
}
|
279
273
|
}
|
280
274
|
|
281
|
-
|
275
|
+
Neo.applyClassConfig(AmCharts);
|
282
276
|
|
283
|
-
export default
|
277
|
+
export default AmCharts;
|
@@ -1,12 +1,11 @@
|
|
1
|
-
import Base from '
|
1
|
+
import Base from './Base.mjs';
|
2
2
|
|
3
3
|
/**
|
4
4
|
* Required for the online version of the examples & docs app
|
5
5
|
* We can not name the file GoogleAnalytics, since it does break when using uBlock origin for dist versions.
|
6
6
|
* See: https://github.com/neomjs/neo/issues/651
|
7
7
|
* @class Neo.main.addon.AnalyticsByGoogle
|
8
|
-
* @extends Neo.
|
9
|
-
* @singleton
|
8
|
+
* @extends Neo.main.addon.Base
|
10
9
|
*/
|
11
10
|
class AnalyticsByGoogle extends Base {
|
12
11
|
static config = {
|
@@ -14,12 +13,7 @@ class AnalyticsByGoogle extends Base {
|
|
14
13
|
* @member {String} className='Neo.main.addon.AnalyticsByGoogle'
|
15
14
|
* @protected
|
16
15
|
*/
|
17
|
-
className: 'Neo.main.addon.AnalyticsByGoogle'
|
18
|
-
/**
|
19
|
-
* @member {Boolean} singleton=true
|
20
|
-
* @protected
|
21
|
-
*/
|
22
|
-
singleton: true
|
16
|
+
className: 'Neo.main.addon.AnalyticsByGoogle'
|
23
17
|
}
|
24
18
|
|
25
19
|
/**
|
@@ -54,6 +48,6 @@ class AnalyticsByGoogle extends Base {
|
|
54
48
|
}
|
55
49
|
}
|
56
50
|
|
57
|
-
|
51
|
+
Neo.applyClassConfig(AnalyticsByGoogle);
|
58
52
|
|
59
|
-
export default
|
53
|
+
export default AnalyticsByGoogle;
|
@@ -0,0 +1,26 @@
|
|
1
|
+
import CoreBase from '../../core/Base.mjs';
|
2
|
+
|
3
|
+
/**
|
4
|
+
* Base class for main thread addons
|
5
|
+
* @class Neo.main.addon.Base
|
6
|
+
* @extends Neo.core.Base
|
7
|
+
*/
|
8
|
+
class Base extends CoreBase {
|
9
|
+
static config = {
|
10
|
+
/**
|
11
|
+
* @member {String} className='Neo.main.addon.Base'
|
12
|
+
* @protected
|
13
|
+
*/
|
14
|
+
className: 'Neo.main.addon.Base',
|
15
|
+
/**
|
16
|
+
* An identifier for core.Base to get handled like singletons for remote method access
|
17
|
+
* @member {Boolean} isMainThreadAddon=true
|
18
|
+
* @protected
|
19
|
+
*/
|
20
|
+
isMainThreadAddon: true
|
21
|
+
}
|
22
|
+
}
|
23
|
+
|
24
|
+
Neo.applyClassConfig(Base);
|
25
|
+
|
26
|
+
export default Base;
|
@@ -1,11 +1,10 @@
|
|
1
|
-
import Base from '
|
1
|
+
import Base from './Base.mjs';
|
2
2
|
import DomAccess from '../DomAccess.mjs';
|
3
3
|
|
4
4
|
/**
|
5
5
|
* See: https://github.com/CesiumGS/cesium
|
6
6
|
* @class Neo.main.addon.CesiumJS
|
7
|
-
* @extends Neo.
|
8
|
-
* @singleton
|
7
|
+
* @extends Neo.main.addon.Base
|
9
8
|
*/
|
10
9
|
class CesiumJS extends Base {
|
11
10
|
static config = {
|
@@ -26,12 +25,7 @@ class CesiumJS extends Base {
|
|
26
25
|
'destroy',
|
27
26
|
'flyTo'
|
28
27
|
]
|
29
|
-
}
|
30
|
-
/**
|
31
|
-
* @member {Boolean} singleton=true
|
32
|
-
* @protected
|
33
|
-
*/
|
34
|
-
singleton: true
|
28
|
+
}
|
35
29
|
}
|
36
30
|
|
37
31
|
/**
|
@@ -117,6 +111,6 @@ class CesiumJS extends Base {
|
|
117
111
|
}
|
118
112
|
}
|
119
113
|
|
120
|
-
|
114
|
+
Neo.applyClassConfig(CesiumJS);
|
121
115
|
|
122
|
-
export default
|
116
|
+
export default CesiumJS;
|
@@ -1,11 +1,10 @@
|
|
1
|
-
import Base from '
|
1
|
+
import Base from './Base.mjs';
|
2
2
|
|
3
3
|
/**
|
4
4
|
* Basic helper class to create template DOM nodes and apply them to a target node via cloning.
|
5
5
|
* See: https://github.com/neomjs/neo/blob/dev/apps/krausest/view/TableComponent.mjs
|
6
6
|
* @class Neo.main.addon.CloneNode
|
7
|
-
* @extends Neo.
|
8
|
-
* @singleton
|
7
|
+
* @extends Neo.main.addon.Base
|
9
8
|
*/
|
10
9
|
class CloneNode extends Base {
|
11
10
|
static config = {
|
@@ -30,12 +29,7 @@ class CloneNode extends Base {
|
|
30
29
|
'applyClones',
|
31
30
|
'createNode'
|
32
31
|
]
|
33
|
-
}
|
34
|
-
/**
|
35
|
-
* @member {Boolean} singleton=true
|
36
|
-
* @protected
|
37
|
-
*/
|
38
|
-
singleton: true
|
32
|
+
}
|
39
33
|
}
|
40
34
|
|
41
35
|
/**
|
@@ -93,15 +87,16 @@ class CloneNode extends Base {
|
|
93
87
|
*/
|
94
88
|
createNode(data) {
|
95
89
|
let template = document.createElement(data.tag);
|
90
|
+
|
96
91
|
template.innerHTML = data.html;
|
97
92
|
|
98
93
|
this.map[data.id] = {
|
99
|
-
paths
|
100
|
-
template
|
94
|
+
paths: data.paths,
|
95
|
+
template
|
101
96
|
};
|
102
97
|
}
|
103
98
|
}
|
104
99
|
|
105
|
-
|
100
|
+
Neo.applyClassConfig(CloneNode);
|
106
101
|
|
107
|
-
export default
|
102
|
+
export default CloneNode;
|
@@ -1,10 +1,9 @@
|
|
1
|
-
import Base from '
|
1
|
+
import Base from './Base.mjs';
|
2
2
|
|
3
3
|
/**
|
4
4
|
* Basic Read and write access for document.cookie
|
5
5
|
* @class Neo.main.addon.Cookie
|
6
|
-
* @extends Neo.
|
7
|
-
* @singleton
|
6
|
+
* @extends Neo.main.addon.Base
|
8
7
|
*/
|
9
8
|
class Cookie extends Base {
|
10
9
|
static config = {
|
@@ -24,12 +23,7 @@ class Cookie extends Base {
|
|
24
23
|
'getCookies',
|
25
24
|
'setCookie'
|
26
25
|
]
|
27
|
-
}
|
28
|
-
/**
|
29
|
-
* @member {Boolean} singleton=true
|
30
|
-
* @protected
|
31
|
-
*/
|
32
|
-
singleton: true
|
26
|
+
}
|
33
27
|
}
|
34
28
|
|
35
29
|
/**
|
@@ -59,6 +53,6 @@ class Cookie extends Base {
|
|
59
53
|
}
|
60
54
|
}
|
61
55
|
|
62
|
-
|
56
|
+
Neo.applyClassConfig(Cookie);
|
63
57
|
|
64
|
-
export default
|
58
|
+
export default Cookie;
|
@@ -1,11 +1,10 @@
|
|
1
|
-
import Base from '
|
1
|
+
import Base from './Base.mjs';
|
2
2
|
import DomAccess from '../DomAccess.mjs';
|
3
3
|
import DomEvents from '../DomEvents.mjs';
|
4
4
|
|
5
5
|
/**
|
6
6
|
* @class Neo.main.addon.DragDrop
|
7
|
-
* @extends Neo.
|
8
|
-
* @singleton
|
7
|
+
* @extends Neo.main.addon.Base
|
9
8
|
*/
|
10
9
|
class DragDrop extends Base {
|
11
10
|
static config = {
|
@@ -124,12 +123,7 @@ class DragDrop extends Base {
|
|
124
123
|
/**
|
125
124
|
* @member {Number} scrollFactorTop=1
|
126
125
|
*/
|
127
|
-
scrollFactorTop: 1
|
128
|
-
/**
|
129
|
-
* @member {Boolean} singleton=true
|
130
|
-
* @protected
|
131
|
-
*/
|
132
|
-
singleton: true
|
126
|
+
scrollFactorTop: 1
|
133
127
|
}
|
134
128
|
|
135
129
|
/**
|
@@ -515,6 +509,6 @@ class DragDrop extends Base {
|
|
515
509
|
}
|
516
510
|
}
|
517
511
|
|
518
|
-
|
512
|
+
Neo.applyClassConfig(DragDrop);
|
519
513
|
|
520
|
-
export default
|
514
|
+
export default DragDrop;
|