dbm 1.1.10 → 1.1.11
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/dbm.js +2 -1
- package/ecommerce/Cart.js +79 -0
- package/ecommerce/CartLineItem.js +44 -0
- package/ecommerce/LocalStorageCartLoader.js +74 -0
- package/ecommerce/index.js +16 -0
- package/graphapi/webclient/decode/index.js +16 -0
- package/package.json +1 -1
- package/react/admin/editor/fields/SelectionField.js +55 -0
- package/react/admin/editor/fields/index.js +2 -1
- package/react/admin/editorsgroup/EditField.js +28 -0
- package/react/admin/editorsgroup/index.js +1 -0
- package/react/admin/index.js +3 -1
- package/react/admin/objects/EditObject.js +50 -0
- package/react/admin/objects/InjectObjectTypeEditor.js +30 -0
- package/react/admin/objects/ObjectList.js +92 -0
- package/react/admin/objects/ObjectListRow.js +35 -0
- package/react/admin/objects/index.js +6 -0
- package/react/admin/objects/itemeditors/Content.js +48 -0
- package/react/admin/objects/itemeditors/Link.js +46 -0
- package/react/admin/objects/itemeditors/Name.js +46 -0
- package/react/admin/objects/itemeditors/Title.js +46 -0
- package/react/admin/objects/itemeditors/Visibility.js +44 -0
- package/react/admin/objects/itemeditors/index.js +5 -0
- package/react/admin/website/EditWebsite.js +8 -7
- package/react/area/List.js +7 -2
- package/react/blocks/admin/index.js +1 -0
- package/react/blocks/admin/objects/Edit.js +42 -0
- package/react/blocks/admin/objects/List.js +17 -0
- package/react/blocks/admin/objects/index.js +2 -0
- package/react/blocks/content/ContentBlock.js +47 -0
- package/react/blocks/content/index.js +2 -1
- package/react/blocks/faq/AskAQuestion.js +155 -0
- package/react/blocks/faq/index.js +1 -0
- package/react/blocks/index.js +124 -0
- package/site/SiteNavigation.js +6 -5
- package/updater/PropertyUpdater.js +10 -0
package/site/SiteNavigation.js
CHANGED
|
@@ -16,7 +16,7 @@ export default class SiteNavigation extends Dbm.core.BaseObject {
|
|
|
16
16
|
|
|
17
17
|
this.item.setValue("ignoredPaths", [
|
|
18
18
|
new RegExp("/assets/.*$"),
|
|
19
|
-
new RegExp("/api/.*$")
|
|
19
|
+
new RegExp("/api/.*$"),
|
|
20
20
|
]);
|
|
21
21
|
|
|
22
22
|
this._callback_beforeUnloadBound = this._callback_beforeUnload.bind(this);
|
|
@@ -65,7 +65,7 @@ export default class SiteNavigation extends Dbm.core.BaseObject {
|
|
|
65
65
|
}
|
|
66
66
|
|
|
67
67
|
_shouldHandle(aLink) {
|
|
68
|
-
let shouldHandle = false
|
|
68
|
+
let shouldHandle = false;
|
|
69
69
|
{
|
|
70
70
|
let currentArray = this.item.allowedPaths;
|
|
71
71
|
let currentArrayLength = currentArray.length;
|
|
@@ -134,6 +134,9 @@ export default class SiteNavigation extends Dbm.core.BaseObject {
|
|
|
134
134
|
if(!link) {
|
|
135
135
|
return true;
|
|
136
136
|
}
|
|
137
|
+
if(link.indexOf("#") === 0) {
|
|
138
|
+
return true;
|
|
139
|
+
}
|
|
137
140
|
|
|
138
141
|
let originalUrl = new URL(document.location.href);
|
|
139
142
|
let finalUrl = new URL(link, document.location.href);
|
|
@@ -143,11 +146,9 @@ export default class SiteNavigation extends Dbm.core.BaseObject {
|
|
|
143
146
|
}
|
|
144
147
|
|
|
145
148
|
if(!this._shouldHandle(finalUrl.href)) {
|
|
146
|
-
return
|
|
149
|
+
return true;
|
|
147
150
|
}
|
|
148
151
|
|
|
149
|
-
//console.log(finalUrl);
|
|
150
|
-
|
|
151
152
|
aEvent.preventDefault();
|
|
152
153
|
|
|
153
154
|
this._internalNavigation(finalUrl.href);
|
|
@@ -5,6 +5,8 @@ export default class PropertyUpdater extends Dbm.core.BaseObject {
|
|
|
5
5
|
_construct() {
|
|
6
6
|
super._construct();
|
|
7
7
|
|
|
8
|
+
this._currentTweens = new WeakMap();
|
|
9
|
+
|
|
8
10
|
this.item.setValue("tweens", []);
|
|
9
11
|
this.item.setValue("updatedProperties", []);
|
|
10
12
|
this.item.setValue("singleUpdateProperties", []);
|
|
@@ -96,6 +98,12 @@ export default class PropertyUpdater extends Dbm.core.BaseObject {
|
|
|
96
98
|
}
|
|
97
99
|
|
|
98
100
|
animateProperty(aProperty, aToValue, aTime, aDelay = 0, aEasing = null) {
|
|
101
|
+
|
|
102
|
+
if(this._currentTweens.has(aProperty)) {
|
|
103
|
+
this._currentTweens.get(aProperty).stop();
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
|
|
99
107
|
let tweenObject = {"envelope": aProperty.value};
|
|
100
108
|
if(!aEasing) {
|
|
101
109
|
aEasing = Easing.Quadratic.Out;
|
|
@@ -106,6 +114,8 @@ export default class PropertyUpdater extends Dbm.core.BaseObject {
|
|
|
106
114
|
tweens.push(tween);
|
|
107
115
|
this.item.tweens = tweens;
|
|
108
116
|
|
|
117
|
+
this._currentTweens.set(aProperty, tween);
|
|
118
|
+
|
|
109
119
|
return this;
|
|
110
120
|
}
|
|
111
121
|
|