@colijnit/configurator 1.0.17 → 12.0.2
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/app/builder.d.ts +15 -4
- package/app/components/answers/answer/answer.component.d.ts +3 -3
- package/app/components/selections/selections.component.d.ts +5 -6
- package/app/services/configurator.service.d.ts +0 -3
- package/app/utils/object.utils.d.ts +7 -0
- package/bundles/colijnit-configurator.umd.js +1051 -568
- package/bundles/colijnit-configurator.umd.js.map +1 -1
- package/colijnit-configurator.d.ts +2 -3
- package/colijnit-configurator.metadata.json +1 -1
- package/esm2015/app/builder.js +126 -44
- package/esm2015/app/components/answers/answer/answer.component.js +29 -32
- package/esm2015/app/components/answers/answers.component.js +16 -21
- package/esm2015/app/components/answers/answers.module.js +20 -22
- package/esm2015/app/components/selections/selections.component.js +29 -34
- package/esm2015/app/components/selections/selections.module.js +17 -19
- package/esm2015/app/components/shared/loader/loader.component.js +10 -12
- package/esm2015/app/components/shared/shared.module.js +16 -18
- package/esm2015/app/directives/visibility-observer-master.directive.js +9 -10
- package/esm2015/app/directives/visibility-observer.directive.js +13 -15
- package/esm2015/app/services/configurator.service.js +4 -23
- package/esm2015/app/services/image-cache.service.js +10 -13
- package/esm2015/app/services/locator.service.js +6 -8
- package/esm2015/app/utils/object.utils.js +49 -0
- package/esm2015/colijnit-configurator.js +3 -4
- package/esm2015/helper/variation-helper.js +174 -41
- package/esm2015/model/material.js +1 -1
- package/esm2015/model/variation-settings.js +4 -1
- package/esm2015/model/variation.js +1 -1
- package/esm2015/public_api.js +1 -1
- package/esm2015/utils/asset.utils.js +64 -12
- package/esm2015/utils/file.utils.js +4 -1
- package/esm2015/utils/image.utils.js +1 -1
- package/esm2015/utils/object.utils.js +1 -1
- package/esm2015/utils/scene-utils.js +1 -1
- package/esm2015/utils/threed.utils.js +3 -3
- package/esm2015/utils/variation-utils.js +99 -29
- package/fesm2015/colijnit-configurator.js +705 -403
- package/fesm2015/colijnit-configurator.js.map +1 -1
- package/helper/variation-helper.d.ts +1 -1
- package/model/material.d.ts +16 -0
- package/model/variation-settings.d.ts +21 -0
- package/package.json +16 -19
- package/utils/asset.utils.d.ts +3 -0
- package/utils/threed.utils.d.ts +1 -1
- package/utils/variation-utils.d.ts +1 -0
- package/bundles/colijnit-configurator.umd.min.js +0 -17
- package/bundles/colijnit-configurator.umd.min.js.map +0 -1
- package/esm5/app/builder.js +0 -591
- package/esm5/app/components/answers/answer/answer.component.js +0 -64
- package/esm5/app/components/answers/answers.component.js +0 -27
- package/esm5/app/components/answers/answers.module.js +0 -32
- package/esm5/app/components/selections/selections.component.js +0 -104
- package/esm5/app/components/selections/selections.module.js +0 -26
- package/esm5/app/components/shared/loader/loader.component.js +0 -16
- package/esm5/app/components/shared/shared.module.js +0 -24
- package/esm5/app/directives/visibility-observer-master.directive.js +0 -64
- package/esm5/app/directives/visibility-observer.directive.js +0 -59
- package/esm5/app/services/configurator.service.js +0 -160
- package/esm5/app/services/image-cache.service.js +0 -69
- package/esm5/app/services/locator.service.js +0 -13
- package/esm5/colijnit-configurator.js +0 -11
- package/esm5/helper/variation-helper.js +0 -268
- package/esm5/model/material.js +0 -13
- package/esm5/model/variation-settings.js +0 -8
- package/esm5/model/variation.js +0 -7
- package/esm5/public_api.js +0 -7
- package/esm5/utils/asset.utils.js +0 -106
- package/esm5/utils/file.utils.js +0 -151
- package/esm5/utils/image.utils.js +0 -56
- package/esm5/utils/object.utils.js +0 -56
- package/esm5/utils/scene-utils.js +0 -98
- package/esm5/utils/threed.utils.js +0 -279
- package/esm5/utils/variation-utils.js +0 -327
- package/fesm5/colijnit-configurator.js +0 -2527
- package/fesm5/colijnit-configurator.js.map +0 -1
|
@@ -1,12 +1,35 @@
|
|
|
1
1
|
(function (global, factory) {
|
|
2
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('three'), require('@colijnit/configuratorapi/build/model/
|
|
3
|
-
typeof define === 'function' && define.amd ? define('@colijnit/configurator', ['exports', 'three', '@colijnit/configuratorapi/build/model/
|
|
4
|
-
(global = global || self, factory((global.colijnit = global.colijnit || {}, global.colijnit.configurator = {}), global.
|
|
5
|
-
}(this, (function (exports,
|
|
2
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('three'), require('@colijnit/configuratorapi/build/model/deco-node'), require('@colijnit/configuratorapi/build/service/business-object-factory'), require('@colijnit/configuratorapi/build/model/selection'), require('@colijnit/configuratorapi/build/enum/deco-node-type.enum'), require('axios'), require('@colijnit/configuratorapi/build/enum/deco-node-kind.enum'), require('rxjs'), require('jszip'), require('@colijnit/configuratorapi/build/model/article'), require('@colijnit/configuratorapi/build/configurator'), require('@colijnit/configuratorapi/build/utils/function/not-nill.function'), require('@colijnit/configuratorapi/build/enum/node-type.enum'), require('@colijnit/configuratorapi/build/utils/function/is-nill.function'), require('@angular/core'), require('@angular/common'), require('@angular/animations')) :
|
|
3
|
+
typeof define === 'function' && define.amd ? define('@colijnit/configurator', ['exports', 'three', '@colijnit/configuratorapi/build/model/deco-node', '@colijnit/configuratorapi/build/service/business-object-factory', '@colijnit/configuratorapi/build/model/selection', '@colijnit/configuratorapi/build/enum/deco-node-type.enum', 'axios', '@colijnit/configuratorapi/build/enum/deco-node-kind.enum', 'rxjs', 'jszip', '@colijnit/configuratorapi/build/model/article', '@colijnit/configuratorapi/build/configurator', '@colijnit/configuratorapi/build/utils/function/not-nill.function', '@colijnit/configuratorapi/build/enum/node-type.enum', '@colijnit/configuratorapi/build/utils/function/is-nill.function', '@angular/core', '@angular/common', '@angular/animations'], factory) :
|
|
4
|
+
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.colijnit = global.colijnit || {}, global.colijnit.configurator = {}), global.THREE, global.decoNode, global.businessObjectFactory, global.selection, global.decoNodeType_enum, global.axios, global.decoNodeKind_enum, global.rxjs, global.JSZip, global.article, global.configurator, global.notNill_function, global.nodeType_enum, global.isNill_function, global.ng.core, global.ng.common, global.ng.animations));
|
|
5
|
+
})(this, (function (exports, THREE, decoNode, businessObjectFactory, selection, decoNodeType_enum, axios, decoNodeKind_enum, rxjs, JSZip, article, configurator, notNill_function, nodeType_enum, isNill_function, i0, common, animations) { 'use strict';
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
function _interopNamespace(e) {
|
|
10
|
+
if (e && e.__esModule) return e;
|
|
11
|
+
var n = Object.create(null);
|
|
12
|
+
if (e) {
|
|
13
|
+
Object.keys(e).forEach(function (k) {
|
|
14
|
+
if (k !== 'default') {
|
|
15
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
16
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
17
|
+
enumerable: true,
|
|
18
|
+
get: function () { return e[k]; }
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
n["default"] = e;
|
|
24
|
+
return Object.freeze(n);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
var THREE__namespace = /*#__PURE__*/_interopNamespace(THREE);
|
|
28
|
+
var axios__default = /*#__PURE__*/_interopDefaultLegacy(axios);
|
|
29
|
+
var JSZip__default = /*#__PURE__*/_interopDefaultLegacy(JSZip);
|
|
30
|
+
var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
|
|
31
|
+
|
|
32
|
+
/******************************************************************************
|
|
10
33
|
Copyright (c) Microsoft Corporation.
|
|
11
34
|
|
|
12
35
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
@@ -21,35 +44,38 @@
|
|
|
21
44
|
PERFORMANCE OF THIS SOFTWARE.
|
|
22
45
|
***************************************************************************** */
|
|
23
46
|
/* global Reflect, Promise */
|
|
24
|
-
|
|
25
|
-
var extendStatics = function(d, b) {
|
|
47
|
+
var extendStatics = function (d, b) {
|
|
26
48
|
extendStatics = Object.setPrototypeOf ||
|
|
27
49
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
28
|
-
function (d, b) { for (var p in b)
|
|
50
|
+
function (d, b) { for (var p in b)
|
|
51
|
+
if (Object.prototype.hasOwnProperty.call(b, p))
|
|
52
|
+
d[p] = b[p]; };
|
|
29
53
|
return extendStatics(d, b);
|
|
30
54
|
};
|
|
31
|
-
|
|
32
55
|
function __extends(d, b) {
|
|
56
|
+
if (typeof b !== "function" && b !== null)
|
|
57
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
33
58
|
extendStatics(d, b);
|
|
34
59
|
function __() { this.constructor = d; }
|
|
35
60
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
36
61
|
}
|
|
37
|
-
|
|
38
|
-
var __assign = function() {
|
|
62
|
+
var __assign = function () {
|
|
39
63
|
__assign = Object.assign || function __assign(t) {
|
|
40
64
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
41
65
|
s = arguments[i];
|
|
42
|
-
for (var p in s)
|
|
66
|
+
for (var p in s)
|
|
67
|
+
if (Object.prototype.hasOwnProperty.call(s, p))
|
|
68
|
+
t[p] = s[p];
|
|
43
69
|
}
|
|
44
70
|
return t;
|
|
45
71
|
};
|
|
46
72
|
return __assign.apply(this, arguments);
|
|
47
73
|
};
|
|
48
|
-
|
|
49
74
|
function __rest(s, e) {
|
|
50
75
|
var t = {};
|
|
51
|
-
for (var p in s)
|
|
52
|
-
|
|
76
|
+
for (var p in s)
|
|
77
|
+
if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
78
|
+
t[p] = s[p];
|
|
53
79
|
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
54
80
|
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
55
81
|
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
@@ -57,175 +83,280 @@
|
|
|
57
83
|
}
|
|
58
84
|
return t;
|
|
59
85
|
}
|
|
60
|
-
|
|
61
86
|
function __decorate(decorators, target, key, desc) {
|
|
62
87
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
63
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
|
|
64
|
-
|
|
88
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
|
|
89
|
+
r = Reflect.decorate(decorators, target, key, desc);
|
|
90
|
+
else
|
|
91
|
+
for (var i = decorators.length - 1; i >= 0; i--)
|
|
92
|
+
if (d = decorators[i])
|
|
93
|
+
r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
65
94
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
66
95
|
}
|
|
67
|
-
|
|
68
96
|
function __param(paramIndex, decorator) {
|
|
69
|
-
return function (target, key) { decorator(target, key, paramIndex); }
|
|
97
|
+
return function (target, key) { decorator(target, key, paramIndex); };
|
|
70
98
|
}
|
|
71
|
-
|
|
72
99
|
function __metadata(metadataKey, metadataValue) {
|
|
73
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
|
|
100
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
|
|
101
|
+
return Reflect.metadata(metadataKey, metadataValue);
|
|
74
102
|
}
|
|
75
|
-
|
|
76
103
|
function __awaiter(thisArg, _arguments, P, generator) {
|
|
77
104
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
78
105
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
79
|
-
function fulfilled(value) { try {
|
|
80
|
-
|
|
106
|
+
function fulfilled(value) { try {
|
|
107
|
+
step(generator.next(value));
|
|
108
|
+
}
|
|
109
|
+
catch (e) {
|
|
110
|
+
reject(e);
|
|
111
|
+
} }
|
|
112
|
+
function rejected(value) { try {
|
|
113
|
+
step(generator["throw"](value));
|
|
114
|
+
}
|
|
115
|
+
catch (e) {
|
|
116
|
+
reject(e);
|
|
117
|
+
} }
|
|
81
118
|
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
82
119
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
83
120
|
});
|
|
84
121
|
}
|
|
85
|
-
|
|
86
122
|
function __generator(thisArg, body) {
|
|
87
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1)
|
|
88
|
-
|
|
123
|
+
var _ = { label: 0, sent: function () { if (t[0] & 1)
|
|
124
|
+
throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
125
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function () { return this; }), g;
|
|
89
126
|
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
90
127
|
function step(op) {
|
|
91
|
-
if (f)
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
128
|
+
if (f)
|
|
129
|
+
throw new TypeError("Generator is already executing.");
|
|
130
|
+
while (_)
|
|
131
|
+
try {
|
|
132
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done)
|
|
133
|
+
return t;
|
|
134
|
+
if (y = 0, t)
|
|
135
|
+
op = [op[0] & 2, t.value];
|
|
136
|
+
switch (op[0]) {
|
|
137
|
+
case 0:
|
|
138
|
+
case 1:
|
|
139
|
+
t = op;
|
|
140
|
+
break;
|
|
141
|
+
case 4:
|
|
142
|
+
_.label++;
|
|
143
|
+
return { value: op[1], done: false };
|
|
144
|
+
case 5:
|
|
145
|
+
_.label++;
|
|
146
|
+
y = op[1];
|
|
147
|
+
op = [0];
|
|
148
|
+
continue;
|
|
149
|
+
case 7:
|
|
150
|
+
op = _.ops.pop();
|
|
151
|
+
_.trys.pop();
|
|
152
|
+
continue;
|
|
153
|
+
default:
|
|
154
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
|
|
155
|
+
_ = 0;
|
|
156
|
+
continue;
|
|
157
|
+
}
|
|
158
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) {
|
|
159
|
+
_.label = op[1];
|
|
160
|
+
break;
|
|
161
|
+
}
|
|
162
|
+
if (op[0] === 6 && _.label < t[1]) {
|
|
163
|
+
_.label = t[1];
|
|
164
|
+
t = op;
|
|
165
|
+
break;
|
|
166
|
+
}
|
|
167
|
+
if (t && _.label < t[2]) {
|
|
168
|
+
_.label = t[2];
|
|
169
|
+
_.ops.push(op);
|
|
170
|
+
break;
|
|
171
|
+
}
|
|
172
|
+
if (t[2])
|
|
173
|
+
_.ops.pop();
|
|
174
|
+
_.trys.pop();
|
|
175
|
+
continue;
|
|
176
|
+
}
|
|
177
|
+
op = body.call(thisArg, _);
|
|
178
|
+
}
|
|
179
|
+
catch (e) {
|
|
180
|
+
op = [6, e];
|
|
181
|
+
y = 0;
|
|
182
|
+
}
|
|
183
|
+
finally {
|
|
184
|
+
f = t = 0;
|
|
185
|
+
}
|
|
186
|
+
if (op[0] & 5)
|
|
187
|
+
throw op[1];
|
|
188
|
+
return { value: op[0] ? op[1] : void 0, done: true };
|
|
111
189
|
}
|
|
112
190
|
}
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
191
|
+
var __createBinding = Object.create ? (function (o, m, k, k2) {
|
|
192
|
+
if (k2 === undefined)
|
|
193
|
+
k2 = k;
|
|
194
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
195
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
196
|
+
desc = { enumerable: true, get: function () { return m[k]; } };
|
|
197
|
+
}
|
|
198
|
+
Object.defineProperty(o, k2, desc);
|
|
199
|
+
}) : (function (o, m, k, k2) {
|
|
200
|
+
if (k2 === undefined)
|
|
201
|
+
k2 = k;
|
|
116
202
|
o[k2] = m[k];
|
|
203
|
+
});
|
|
204
|
+
function __exportStar(m, o) {
|
|
205
|
+
for (var p in m)
|
|
206
|
+
if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p))
|
|
207
|
+
__createBinding(o, m, p);
|
|
117
208
|
}
|
|
118
|
-
|
|
119
|
-
function __exportStar(m, exports) {
|
|
120
|
-
for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) exports[p] = m[p];
|
|
121
|
-
}
|
|
122
|
-
|
|
123
209
|
function __values(o) {
|
|
124
210
|
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
|
|
125
|
-
if (m)
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
211
|
+
if (m)
|
|
212
|
+
return m.call(o);
|
|
213
|
+
if (o && typeof o.length === "number")
|
|
214
|
+
return {
|
|
215
|
+
next: function () {
|
|
216
|
+
if (o && i >= o.length)
|
|
217
|
+
o = void 0;
|
|
218
|
+
return { value: o && o[i++], done: !o };
|
|
219
|
+
}
|
|
220
|
+
};
|
|
132
221
|
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
133
222
|
}
|
|
134
|
-
|
|
135
223
|
function __read(o, n) {
|
|
136
224
|
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
137
|
-
if (!m)
|
|
225
|
+
if (!m)
|
|
226
|
+
return o;
|
|
138
227
|
var i = m.call(o), r, ar = [], e;
|
|
139
228
|
try {
|
|
140
|
-
while ((n === void 0 || n-- > 0) && !(r = i.next()).done)
|
|
229
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done)
|
|
230
|
+
ar.push(r.value);
|
|
231
|
+
}
|
|
232
|
+
catch (error) {
|
|
233
|
+
e = { error: error };
|
|
141
234
|
}
|
|
142
|
-
catch (error) { e = { error: error }; }
|
|
143
235
|
finally {
|
|
144
236
|
try {
|
|
145
|
-
if (r && !r.done && (m = i["return"]))
|
|
237
|
+
if (r && !r.done && (m = i["return"]))
|
|
238
|
+
m.call(i);
|
|
239
|
+
}
|
|
240
|
+
finally {
|
|
241
|
+
if (e)
|
|
242
|
+
throw e.error;
|
|
146
243
|
}
|
|
147
|
-
finally { if (e) throw e.error; }
|
|
148
244
|
}
|
|
149
245
|
return ar;
|
|
150
246
|
}
|
|
151
|
-
|
|
247
|
+
/** @deprecated */
|
|
152
248
|
function __spread() {
|
|
153
249
|
for (var ar = [], i = 0; i < arguments.length; i++)
|
|
154
250
|
ar = ar.concat(__read(arguments[i]));
|
|
155
251
|
return ar;
|
|
156
252
|
}
|
|
157
|
-
|
|
253
|
+
/** @deprecated */
|
|
158
254
|
function __spreadArrays() {
|
|
159
|
-
for (var s = 0, i = 0, il = arguments.length; i < il; i++)
|
|
255
|
+
for (var s = 0, i = 0, il = arguments.length; i < il; i++)
|
|
256
|
+
s += arguments[i].length;
|
|
160
257
|
for (var r = Array(s), k = 0, i = 0; i < il; i++)
|
|
161
258
|
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
|
|
162
259
|
r[k] = a[j];
|
|
163
260
|
return r;
|
|
164
|
-
}
|
|
165
|
-
|
|
261
|
+
}
|
|
262
|
+
function __spreadArray(to, from, pack) {
|
|
263
|
+
if (pack || arguments.length === 2)
|
|
264
|
+
for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
265
|
+
if (ar || !(i in from)) {
|
|
266
|
+
if (!ar)
|
|
267
|
+
ar = Array.prototype.slice.call(from, 0, i);
|
|
268
|
+
ar[i] = from[i];
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
return to.concat(ar || Array.prototype.slice.call(from));
|
|
272
|
+
}
|
|
166
273
|
function __await(v) {
|
|
167
274
|
return this instanceof __await ? (this.v = v, this) : new __await(v);
|
|
168
275
|
}
|
|
169
|
-
|
|
170
276
|
function __asyncGenerator(thisArg, _arguments, generator) {
|
|
171
|
-
if (!Symbol.asyncIterator)
|
|
277
|
+
if (!Symbol.asyncIterator)
|
|
278
|
+
throw new TypeError("Symbol.asyncIterator is not defined.");
|
|
172
279
|
var g = generator.apply(thisArg, _arguments || []), i, q = [];
|
|
173
280
|
return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
|
|
174
|
-
function verb(n) { if (g[n])
|
|
175
|
-
|
|
281
|
+
function verb(n) { if (g[n])
|
|
282
|
+
i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
|
|
283
|
+
function resume(n, v) { try {
|
|
284
|
+
step(g[n](v));
|
|
285
|
+
}
|
|
286
|
+
catch (e) {
|
|
287
|
+
settle(q[0][3], e);
|
|
288
|
+
} }
|
|
176
289
|
function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
|
|
177
290
|
function fulfill(value) { resume("next", value); }
|
|
178
291
|
function reject(value) { resume("throw", value); }
|
|
179
|
-
function settle(f, v) { if (f(v), q.shift(), q.length)
|
|
292
|
+
function settle(f, v) { if (f(v), q.shift(), q.length)
|
|
293
|
+
resume(q[0][0], q[0][1]); }
|
|
180
294
|
}
|
|
181
|
-
|
|
182
295
|
function __asyncDelegator(o) {
|
|
183
296
|
var i, p;
|
|
184
297
|
return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
|
|
185
298
|
function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
|
|
186
299
|
}
|
|
187
|
-
|
|
188
300
|
function __asyncValues(o) {
|
|
189
|
-
if (!Symbol.asyncIterator)
|
|
301
|
+
if (!Symbol.asyncIterator)
|
|
302
|
+
throw new TypeError("Symbol.asyncIterator is not defined.");
|
|
190
303
|
var m = o[Symbol.asyncIterator], i;
|
|
191
304
|
return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
|
|
192
305
|
function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
|
|
193
|
-
function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }
|
|
306
|
+
function settle(resolve, reject, d, v) { Promise.resolve(v).then(function (v) { resolve({ value: v, done: d }); }, reject); }
|
|
194
307
|
}
|
|
195
|
-
|
|
196
308
|
function __makeTemplateObject(cooked, raw) {
|
|
197
|
-
if (Object.defineProperty) {
|
|
309
|
+
if (Object.defineProperty) {
|
|
310
|
+
Object.defineProperty(cooked, "raw", { value: raw });
|
|
311
|
+
}
|
|
312
|
+
else {
|
|
313
|
+
cooked.raw = raw;
|
|
314
|
+
}
|
|
198
315
|
return cooked;
|
|
316
|
+
}
|
|
317
|
+
;
|
|
318
|
+
var __setModuleDefault = Object.create ? (function (o, v) {
|
|
319
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
320
|
+
}) : function (o, v) {
|
|
321
|
+
o["default"] = v;
|
|
199
322
|
};
|
|
200
|
-
|
|
201
323
|
function __importStar(mod) {
|
|
202
|
-
if (mod && mod.__esModule)
|
|
324
|
+
if (mod && mod.__esModule)
|
|
325
|
+
return mod;
|
|
203
326
|
var result = {};
|
|
204
|
-
if (mod != null)
|
|
205
|
-
|
|
327
|
+
if (mod != null)
|
|
328
|
+
for (var k in mod)
|
|
329
|
+
if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k))
|
|
330
|
+
__createBinding(result, mod, k);
|
|
331
|
+
__setModuleDefault(result, mod);
|
|
206
332
|
return result;
|
|
207
333
|
}
|
|
208
|
-
|
|
209
334
|
function __importDefault(mod) {
|
|
210
335
|
return (mod && mod.__esModule) ? mod : { default: mod };
|
|
211
336
|
}
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
return
|
|
337
|
+
function __classPrivateFieldGet(receiver, state, kind, f) {
|
|
338
|
+
if (kind === "a" && !f)
|
|
339
|
+
throw new TypeError("Private accessor was defined without a getter");
|
|
340
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
|
|
341
|
+
throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
342
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
218
343
|
}
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
344
|
+
function __classPrivateFieldSet(receiver, state, value, kind, f) {
|
|
345
|
+
if (kind === "m")
|
|
346
|
+
throw new TypeError("Private method is not writable");
|
|
347
|
+
if (kind === "a" && !f)
|
|
348
|
+
throw new TypeError("Private accessor was defined without a setter");
|
|
349
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
|
|
350
|
+
throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
351
|
+
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
352
|
+
}
|
|
353
|
+
function __classPrivateFieldIn(state, receiver) {
|
|
354
|
+
if (receiver === null || (typeof receiver !== "object" && typeof receiver !== "function"))
|
|
355
|
+
throw new TypeError("Cannot use 'in' operator on non-object");
|
|
356
|
+
return typeof state === "function" ? receiver === state : state.has(receiver);
|
|
226
357
|
}
|
|
227
358
|
|
|
228
|
-
var ObjectUtils = /** @class */ (function () {
|
|
359
|
+
var ObjectUtils$1 = /** @class */ (function () {
|
|
229
360
|
function ObjectUtils() {
|
|
230
361
|
}
|
|
231
362
|
ObjectUtils.DisposeMaterial = function (material) {
|
|
@@ -263,7 +394,7 @@
|
|
|
263
394
|
ObjectUtils.DisposeNode = function (node) {
|
|
264
395
|
var _this = this;
|
|
265
396
|
node.traverse(function (obj) {
|
|
266
|
-
if (obj instanceof
|
|
397
|
+
if (obj instanceof THREE.Mesh) {
|
|
267
398
|
if (obj.geometry) {
|
|
268
399
|
obj.geometry.dispose();
|
|
269
400
|
}
|
|
@@ -275,9 +406,9 @@
|
|
|
275
406
|
}
|
|
276
407
|
});
|
|
277
408
|
};
|
|
278
|
-
ObjectUtils.materialProps = ['map', 'lightMap', 'bumpMap', 'normalMap', 'specularMap', 'envMap', 'aoMap', 'roughnessMap', 'metalnessMap'];
|
|
279
409
|
return ObjectUtils;
|
|
280
|
-
}());
|
|
410
|
+
}());
|
|
411
|
+
ObjectUtils$1.materialProps = ['map', 'lightMap', 'bumpMap', 'normalMap', 'specularMap', 'envMap', 'aoMap', 'roughnessMap', 'metalnessMap'];
|
|
281
412
|
|
|
282
413
|
// Static utility functions holder related to files.
|
|
283
414
|
// @dynamic
|
|
@@ -303,11 +434,15 @@
|
|
|
303
434
|
var result;
|
|
304
435
|
return __generator(this, function (_a) {
|
|
305
436
|
switch (_a.label) {
|
|
306
|
-
case 0:
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
437
|
+
case 0:
|
|
438
|
+
if (!assetPath.endsWith('/')) {
|
|
439
|
+
assetPath = assetPath + '/';
|
|
440
|
+
}
|
|
441
|
+
return [4 /*yield*/, axios__default["default"]({
|
|
442
|
+
method: 'get',
|
|
443
|
+
url: assetPath + "getFiles.php?assetUrl=" + url,
|
|
444
|
+
responseType: "json"
|
|
445
|
+
})];
|
|
311
446
|
case 1:
|
|
312
447
|
result = _a.sent();
|
|
313
448
|
return [2 /*return*/, !!result.data];
|
|
@@ -423,9 +558,9 @@
|
|
|
423
558
|
}
|
|
424
559
|
return url.replace('.unity3d', '');
|
|
425
560
|
};
|
|
426
|
-
FileUtils._cachedTextureUploads = new Map();
|
|
427
561
|
return FileUtils;
|
|
428
|
-
}());
|
|
562
|
+
}());
|
|
563
|
+
FileUtils._cachedTextureUploads = new Map();
|
|
429
564
|
|
|
430
565
|
var ThreedUtils = /** @class */ (function () {
|
|
431
566
|
function ThreedUtils() {
|
|
@@ -433,10 +568,10 @@
|
|
|
433
568
|
}
|
|
434
569
|
ThreedUtils.prototype.clearCache = function () {
|
|
435
570
|
var objs = Array.from(this._objectCache.values());
|
|
436
|
-
objs.forEach(function (o) { return ObjectUtils.DisposeObject(o); });
|
|
571
|
+
objs.forEach(function (o) { return ObjectUtils$1.DisposeObject(o); });
|
|
437
572
|
this._objectCache.clear();
|
|
438
573
|
};
|
|
439
|
-
ThreedUtils.prototype.download3DSource = function (fileName) {
|
|
574
|
+
ThreedUtils.prototype.download3DSource = function (fileName, assetPath) {
|
|
440
575
|
var _this = this;
|
|
441
576
|
return new Promise(function (resolve, reject) { return __awaiter(_this, void 0, void 0, function () {
|
|
442
577
|
var lookupFileName;
|
|
@@ -450,7 +585,7 @@
|
|
|
450
585
|
resolve(this._objectCache.get(lookupFileName));
|
|
451
586
|
return [2 /*return*/];
|
|
452
587
|
}
|
|
453
|
-
return [4 /*yield*/, FileUtils.FileExists(lookupFileName,
|
|
588
|
+
return [4 /*yield*/, FileUtils.FileExists(lookupFileName, assetPath)];
|
|
454
589
|
case 1:
|
|
455
590
|
if (_a.sent()) {
|
|
456
591
|
this.loadGlbSource(lookupFileName).then(function (obj) {
|
|
@@ -487,7 +622,7 @@
|
|
|
487
622
|
return [4 /*yield*/, this._readJsonFile(filePath)];
|
|
488
623
|
case 1:
|
|
489
624
|
json = _a.sent();
|
|
490
|
-
loader = new
|
|
625
|
+
loader = new THREE__namespace.ObjectLoader();
|
|
491
626
|
loader.crossOrigin = 'Anonymous';
|
|
492
627
|
return [2 /*return*/, new Promise(function (resolve, reject) {
|
|
493
628
|
try {
|
|
@@ -511,7 +646,7 @@
|
|
|
511
646
|
if (this._objectCache.has(filePath)) {
|
|
512
647
|
return [2 /*return*/, Promise.resolve(this._objectCache.get(filePath))];
|
|
513
648
|
}
|
|
514
|
-
loader = new
|
|
649
|
+
loader = new THREE__namespace.ObjectLoader();
|
|
515
650
|
loader.setCrossOrigin('Anonymous');
|
|
516
651
|
loader.setResourcePath('');
|
|
517
652
|
return [2 /*return*/, new Promise(function (resolve, reject) {
|
|
@@ -563,7 +698,7 @@
|
|
|
563
698
|
case 1:
|
|
564
699
|
obj = _a.sent();
|
|
565
700
|
if (obj) {
|
|
566
|
-
obj.children = obj.children.filter(function (c) { return !(c instanceof
|
|
701
|
+
obj.children = obj.children.filter(function (c) { return !(c instanceof THREE__namespace.Camera); });
|
|
567
702
|
obj.children.sort(function (a, b) { return a['name'] < b['name'] ? 1 : -1; });
|
|
568
703
|
obj.children.forEach(function (c) {
|
|
569
704
|
c.traverse(function (t) {
|
|
@@ -571,7 +706,7 @@
|
|
|
571
706
|
});
|
|
572
707
|
c.visible = false;
|
|
573
708
|
});
|
|
574
|
-
if (obj.children.length === 1 && obj.children[0] instanceof
|
|
709
|
+
if (obj.children.length === 1 && obj.children[0] instanceof THREE__namespace.Group) { // flatten children
|
|
575
710
|
children = obj.children[0].children.slice();
|
|
576
711
|
obj.children.length = 0;
|
|
577
712
|
obj.children = children;
|
|
@@ -587,11 +722,11 @@
|
|
|
587
722
|
return __generator(this, function (_a) {
|
|
588
723
|
// url = this._includeBaseUrl(url);
|
|
589
724
|
return [2 /*return*/, new Promise(function (resolve, reject) {
|
|
590
|
-
var textureLoader = new
|
|
725
|
+
var textureLoader = new THREE__namespace.TextureLoader();
|
|
591
726
|
// textureLoader.setBaseU(this._settingsService.settings.assetPath);
|
|
592
727
|
textureLoader.load(url, function (texture) {
|
|
593
|
-
texture.wrapT =
|
|
594
|
-
texture.wrapS =
|
|
728
|
+
texture.wrapT = THREE__namespace.RepeatWrapping;
|
|
729
|
+
texture.wrapS = THREE__namespace.RepeatWrapping;
|
|
595
730
|
texture.repeat.set(1, 1);
|
|
596
731
|
texture.needsUpdate = true;
|
|
597
732
|
return resolve(texture);
|
|
@@ -603,13 +738,13 @@
|
|
|
603
738
|
ThreedUtils.prototype._cleanedUpObjects = function (object, cleanUp) {
|
|
604
739
|
var _this = this;
|
|
605
740
|
if (cleanUp === void 0) { cleanUp = true; }
|
|
606
|
-
var obj = new
|
|
741
|
+
var obj = new THREE__namespace.Object3D();
|
|
607
742
|
object.children.forEach(function (c) {
|
|
608
|
-
if (!(c instanceof
|
|
609
|
-
if (cleanUp && c instanceof
|
|
743
|
+
if (!(c instanceof THREE__namespace.Camera)) {
|
|
744
|
+
if (cleanUp && c instanceof THREE__namespace.Group || (c.children.length === 1 && c.children[0] instanceof THREE__namespace.Group)) {
|
|
610
745
|
_this._addGroupChildrenToObject(c, obj);
|
|
611
746
|
}
|
|
612
|
-
else if ((cleanUp && !(c instanceof
|
|
747
|
+
else if ((cleanUp && !(c instanceof THREE__namespace.Mesh)) || (!(c instanceof THREE__namespace.Mesh) && !c.name && c.children.length > 0)) {
|
|
613
748
|
c.children.forEach(function (child) {
|
|
614
749
|
child.translateY(c.position.y);
|
|
615
750
|
});
|
|
@@ -632,10 +767,10 @@
|
|
|
632
767
|
}
|
|
633
768
|
}
|
|
634
769
|
});
|
|
635
|
-
var boundingBox = new
|
|
636
|
-
var bbCenterPivot = new
|
|
770
|
+
var boundingBox = new THREE__namespace.Box3().setFromObject(obj);
|
|
771
|
+
var bbCenterPivot = new THREE__namespace.Vector3();
|
|
637
772
|
boundingBox.getCenter(bbCenterPivot);
|
|
638
|
-
var delta = new
|
|
773
|
+
var delta = new THREE__namespace.Vector3().add(bbCenterPivot).negate();
|
|
639
774
|
obj.children.forEach(function (cc) {
|
|
640
775
|
cc.position.add(delta);
|
|
641
776
|
});
|
|
@@ -645,7 +780,7 @@
|
|
|
645
780
|
var _this = this;
|
|
646
781
|
if (cleanUp === void 0) { cleanUp = true; }
|
|
647
782
|
group.children.forEach(function (gc) {
|
|
648
|
-
if (cleanUp && gc instanceof
|
|
783
|
+
if (cleanUp && gc instanceof THREE__namespace.Group) {
|
|
649
784
|
_this._addGroupChildrenToObject(gc, obj);
|
|
650
785
|
}
|
|
651
786
|
else {
|
|
@@ -659,7 +794,7 @@
|
|
|
659
794
|
ThreedUtils.prototype._iterateChildren = function (children, callback) {
|
|
660
795
|
for (var i = 0; i < children.length; i++) {
|
|
661
796
|
var child = children[i];
|
|
662
|
-
if (child instanceof
|
|
797
|
+
if (child instanceof THREE__namespace.Mesh) {
|
|
663
798
|
callback(child);
|
|
664
799
|
}
|
|
665
800
|
else {
|
|
@@ -732,17 +867,17 @@
|
|
|
732
867
|
};
|
|
733
868
|
SceneUtils.Convert3DPointToScreenPoint = function (point, camera, width, height) {
|
|
734
869
|
if (!point) {
|
|
735
|
-
return new
|
|
870
|
+
return new THREE__namespace.Vector2();
|
|
736
871
|
}
|
|
737
872
|
var vector = point.clone().project(camera);
|
|
738
873
|
vector.x = (vector.x + 1) / 2 * width;
|
|
739
874
|
vector.y = -(vector.y - 1) / 2 * height;
|
|
740
|
-
return new
|
|
875
|
+
return new THREE__namespace.Vector2(vector.x, vector.y);
|
|
741
876
|
};
|
|
742
877
|
SceneUtils.CanSelectorConnect = function (con1, con2) {
|
|
743
|
-
var con1Name = con1 instanceof
|
|
744
|
-
var con2Name = con2 instanceof
|
|
745
|
-
var sameParent = con1 instanceof
|
|
878
|
+
var con1Name = con1 instanceof THREE__namespace.Object3D ? con1.name : con1.connector;
|
|
879
|
+
var con2Name = con2 instanceof THREE__namespace.Object3D ? con2.name : con2.connector;
|
|
880
|
+
var sameParent = con1 instanceof THREE__namespace.Object3D && con2 instanceof THREE__namespace.Object3D ? con1.parent === con2.parent : false;
|
|
746
881
|
var parts1 = con1Name.toUpperCase().split('_'), parts2 = con2Name.toUpperCase().split('_');
|
|
747
882
|
if (parts1.length >= 3 && parts2.length >= 3 && !sameParent) {
|
|
748
883
|
var connectable = parts1[0] === 'C' && parts2[0] === 'C' &&
|
|
@@ -757,29 +892,29 @@
|
|
|
757
892
|
}
|
|
758
893
|
con1['connectedTo'] = con2.parent.name;
|
|
759
894
|
con2['connectedTo'] = con1.parent.name;
|
|
760
|
-
var motherRotation = new
|
|
761
|
-
var motherPosition = new
|
|
895
|
+
var motherRotation = new THREE__namespace.Euler(0, 0, 0);
|
|
896
|
+
var motherPosition = new THREE__namespace.Vector3(0, 0, 0);
|
|
762
897
|
scene.updateMatrixWorld(true);
|
|
763
898
|
motherRotation.copy(parent.rotation);
|
|
764
899
|
parent.getWorldPosition(motherPosition);
|
|
765
900
|
parent.rotation.set(0, 0, 0);
|
|
766
901
|
parent.position.set(0, 0, 0);
|
|
767
|
-
var con1Quat = new
|
|
902
|
+
var con1Quat = new THREE__namespace.Quaternion();
|
|
768
903
|
con1.getWorldQuaternion(con1Quat);
|
|
769
|
-
var con2Quat = new
|
|
904
|
+
var con2Quat = new THREE__namespace.Quaternion();
|
|
770
905
|
con2.getWorldQuaternion(con2Quat);
|
|
771
|
-
var con1QuatParent = new
|
|
906
|
+
var con1QuatParent = new THREE__namespace.Quaternion();
|
|
772
907
|
con1.parent.getWorldQuaternion(con1QuatParent);
|
|
773
|
-
var con2QuatParent = new
|
|
908
|
+
var con2QuatParent = new THREE__namespace.Quaternion();
|
|
774
909
|
con2.parent.getWorldQuaternion(con2QuatParent);
|
|
775
|
-
var rotation = new
|
|
910
|
+
var rotation = new THREE__namespace.Quaternion().multiplyQuaternions(con1Quat.invert(), con2Quat).multiply(new THREE__namespace.Quaternion().multiplyQuaternions(con1QuatParent, con1QuatParent));
|
|
776
911
|
con2.parent.quaternion.copy(rotation);
|
|
777
912
|
// Update because the matrix has been tempered with
|
|
778
913
|
scene.updateMatrixWorld(true);
|
|
779
914
|
// Move the connectors towards eachother
|
|
780
|
-
var con1Pos = new
|
|
915
|
+
var con1Pos = new THREE__namespace.Vector3();
|
|
781
916
|
con1.getWorldPosition(con1Pos);
|
|
782
|
-
var con2Pos = new
|
|
917
|
+
var con2Pos = new THREE__namespace.Vector3();
|
|
783
918
|
con2.getWorldPosition(con2Pos);
|
|
784
919
|
var move = con1Pos.sub(con2Pos);
|
|
785
920
|
con2.parent.position.x += move.x;
|
|
@@ -799,7 +934,7 @@
|
|
|
799
934
|
|
|
800
935
|
var Material = /** @class */ (function () {
|
|
801
936
|
function Material() {
|
|
802
|
-
this.specular = new
|
|
937
|
+
this.specular = new THREE__namespace.Color(0.3, 0.3, 0.3);
|
|
803
938
|
this.shininess = 0;
|
|
804
939
|
this.repeatX = 4;
|
|
805
940
|
this.repeatY = 4;
|
|
@@ -819,15 +954,15 @@
|
|
|
819
954
|
}
|
|
820
955
|
else {
|
|
821
956
|
if (!base64) {
|
|
822
|
-
resolve(new
|
|
957
|
+
resolve(new THREE__namespace.Texture());
|
|
823
958
|
}
|
|
824
959
|
else {
|
|
825
|
-
var loader = new
|
|
960
|
+
var loader = new THREE__namespace.TextureLoader();
|
|
826
961
|
loader.load(base64, function (texture) {
|
|
827
962
|
texture.anisotropy = 16;
|
|
828
|
-
texture.wrapS =
|
|
829
|
-
texture.wrapT =
|
|
830
|
-
texture.repeat = new
|
|
963
|
+
texture.wrapS = THREE__namespace.RepeatWrapping;
|
|
964
|
+
texture.wrapT = THREE__namespace.RepeatWrapping;
|
|
965
|
+
texture.repeat = new THREE__namespace.Vector2(material ? material.repeatX : 1, material ? material.repeatY : 1);
|
|
831
966
|
texture.needsUpdate = true;
|
|
832
967
|
ImageUtils.textures.set(id, texture);
|
|
833
968
|
resolve(texture);
|
|
@@ -858,9 +993,9 @@
|
|
|
858
993
|
ImageUtils.getFixedImageFilepathUrl = function (imageFilepathUrl) {
|
|
859
994
|
return imageFilepathUrl.replace("/content/", "/content43/");
|
|
860
995
|
};
|
|
861
|
-
ImageUtils.textures = new Map();
|
|
862
996
|
return ImageUtils;
|
|
863
|
-
}());
|
|
997
|
+
}());
|
|
998
|
+
ImageUtils.textures = new Map();
|
|
864
999
|
|
|
865
1000
|
var FurnitureMaterial = /** @class */ (function (_super) {
|
|
866
1001
|
__extends(FurnitureMaterial, _super);
|
|
@@ -874,9 +1009,9 @@
|
|
|
874
1009
|
}
|
|
875
1010
|
AssetUtils.CreateMaterialFromAsset = function (asset) {
|
|
876
1011
|
return __awaiter(this, void 0, void 0, function () {
|
|
877
|
-
var material, _a, _b, _c, _d, _e;
|
|
878
|
-
return __generator(this, function (
|
|
879
|
-
switch (
|
|
1012
|
+
var material, _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1013
|
+
return __generator(this, function (_k) {
|
|
1014
|
+
switch (_k.label) {
|
|
880
1015
|
case 0:
|
|
881
1016
|
material = new Material();
|
|
882
1017
|
if (!asset) {
|
|
@@ -889,43 +1024,79 @@
|
|
|
889
1024
|
_a = material;
|
|
890
1025
|
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '_texture', asset.texture, material)];
|
|
891
1026
|
case 1:
|
|
892
|
-
_a.texture =
|
|
893
|
-
material.texture.encoding =
|
|
1027
|
+
_a.texture = _k.sent();
|
|
1028
|
+
material.texture.encoding = THREE.sRGBEncoding;
|
|
894
1029
|
material.textureFilename = asset.textureFilename;
|
|
895
|
-
|
|
1030
|
+
_k.label = 2;
|
|
896
1031
|
case 2:
|
|
897
1032
|
if (!asset.normal) return [3 /*break*/, 4];
|
|
898
1033
|
_b = material;
|
|
899
1034
|
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '_normal', asset.normal, material)];
|
|
900
1035
|
case 3:
|
|
901
|
-
_b.normal =
|
|
1036
|
+
_b.normal = _k.sent();
|
|
902
1037
|
material.normalFilename = asset.normalFilename;
|
|
903
|
-
|
|
1038
|
+
_k.label = 4;
|
|
904
1039
|
case 4:
|
|
905
|
-
if (!asset.
|
|
1040
|
+
if (!asset.orm) return [3 /*break*/, 6];
|
|
906
1041
|
_c = material;
|
|
907
|
-
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '
|
|
1042
|
+
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '_orm', asset.orm, material)];
|
|
908
1043
|
case 5:
|
|
909
|
-
_c.ao =
|
|
910
|
-
material.
|
|
911
|
-
|
|
1044
|
+
_c.ao = _k.sent();
|
|
1045
|
+
material.roughness = material.ao;
|
|
1046
|
+
material.metalness = material.ao;
|
|
1047
|
+
material.aoFilename = asset.ormFilename;
|
|
1048
|
+
material.roughnessFilename = asset.ormFilename;
|
|
1049
|
+
material.metalnessFilename = asset.ormFilename;
|
|
1050
|
+
return [3 /*break*/, 12];
|
|
912
1051
|
case 6:
|
|
913
|
-
if (!asset.
|
|
1052
|
+
if (!asset.ao) return [3 /*break*/, 8];
|
|
914
1053
|
_d = material;
|
|
915
|
-
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '
|
|
1054
|
+
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '_ao', asset.ao, material)];
|
|
916
1055
|
case 7:
|
|
917
|
-
_d.
|
|
918
|
-
material.
|
|
919
|
-
|
|
1056
|
+
_d.ao = _k.sent();
|
|
1057
|
+
material.aoFilename = asset.aoFilename;
|
|
1058
|
+
_k.label = 8;
|
|
920
1059
|
case 8:
|
|
921
|
-
if (!asset.
|
|
1060
|
+
if (!asset.metalness) return [3 /*break*/, 10];
|
|
922
1061
|
_e = material;
|
|
923
|
-
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '
|
|
1062
|
+
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '_metalness', asset.metalness, material)];
|
|
924
1063
|
case 9:
|
|
925
|
-
_e.
|
|
1064
|
+
_e.metalness = _k.sent();
|
|
1065
|
+
material.metalnessFilename = asset.metalnessFilename;
|
|
1066
|
+
_k.label = 10;
|
|
1067
|
+
case 10:
|
|
1068
|
+
if (!asset.roughness) return [3 /*break*/, 12];
|
|
1069
|
+
_f = material;
|
|
1070
|
+
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '_roughness', asset.roughness, material)];
|
|
1071
|
+
case 11:
|
|
1072
|
+
_f.roughness = _k.sent();
|
|
926
1073
|
material.roughnessFilename = asset.roughnessFilename;
|
|
927
|
-
|
|
928
|
-
case
|
|
1074
|
+
_k.label = 12;
|
|
1075
|
+
case 12:
|
|
1076
|
+
if (!asset.displacement) return [3 /*break*/, 14];
|
|
1077
|
+
_g = material;
|
|
1078
|
+
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '_displacement', asset.displacement, material)];
|
|
1079
|
+
case 13:
|
|
1080
|
+
_g.displacement = _k.sent();
|
|
1081
|
+
material.displacementFilename = asset.displacementFilename;
|
|
1082
|
+
_k.label = 14;
|
|
1083
|
+
case 14:
|
|
1084
|
+
if (!asset.envMap) return [3 /*break*/, 16];
|
|
1085
|
+
_h = material;
|
|
1086
|
+
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '_env', asset.envMap, material)];
|
|
1087
|
+
case 15:
|
|
1088
|
+
_h.envMap = _k.sent();
|
|
1089
|
+
material.envMapFilename = asset.envMapFilename;
|
|
1090
|
+
_k.label = 16;
|
|
1091
|
+
case 16:
|
|
1092
|
+
if (!asset.emissive) return [3 /*break*/, 18];
|
|
1093
|
+
_j = material;
|
|
1094
|
+
return [4 /*yield*/, ImageUtils.CreateTextureFromBase64(asset.id + '_emissive', asset.emissive, material)];
|
|
1095
|
+
case 17:
|
|
1096
|
+
_j.emissive = _k.sent();
|
|
1097
|
+
material.emissiveFileName = asset.emissiveFilename;
|
|
1098
|
+
_k.label = 18;
|
|
1099
|
+
case 18: return [2 /*return*/, material];
|
|
929
1100
|
}
|
|
930
1101
|
});
|
|
931
1102
|
});
|
|
@@ -938,16 +1109,16 @@
|
|
|
938
1109
|
}
|
|
939
1110
|
var level = parseFloat(settings['level']);
|
|
940
1111
|
if (!isNaN(level)) {
|
|
941
|
-
material.specular = new
|
|
1112
|
+
material.specular = new THREE__namespace.Color(level, level, level);
|
|
942
1113
|
}
|
|
943
1114
|
var repeatObjectUsed = settings.hasOwnProperty('repeat');
|
|
944
1115
|
var repeatx = repeatObjectUsed ? parseFloat(settings['repeat']['repeatx']) : parseFloat(settings['repeatx']);
|
|
945
1116
|
if (!isNaN(repeatx)) {
|
|
946
|
-
material.repeatX =
|
|
1117
|
+
material.repeatX = repeatx;
|
|
947
1118
|
}
|
|
948
1119
|
var repeaty = repeatObjectUsed ? parseFloat(settings['repeat']['repeaty']) : parseFloat(settings['repeaty']);
|
|
949
1120
|
if (!isNaN(repeaty)) {
|
|
950
|
-
material.repeatY =
|
|
1121
|
+
material.repeatY = repeaty;
|
|
951
1122
|
}
|
|
952
1123
|
var metalness = parseFloat(settings['metalness']);
|
|
953
1124
|
if (!isNaN(metalness)) {
|
|
@@ -957,6 +1128,36 @@
|
|
|
957
1128
|
if (!isNaN(roughness)) {
|
|
958
1129
|
material.roughnessValue = Math.min(1, roughness);
|
|
959
1130
|
}
|
|
1131
|
+
if (settings.hasOwnProperty('side')) {
|
|
1132
|
+
material.side = settings.side;
|
|
1133
|
+
}
|
|
1134
|
+
if (settings.hasOwnProperty('sheenColor')) {
|
|
1135
|
+
material.sheenColor = settings.sheenColor;
|
|
1136
|
+
}
|
|
1137
|
+
if (settings.hasOwnProperty('opacity')) {
|
|
1138
|
+
material.opacity = settings.opacity;
|
|
1139
|
+
}
|
|
1140
|
+
if (settings.hasOwnProperty('transparent')) {
|
|
1141
|
+
material.transparent = settings.transparent;
|
|
1142
|
+
}
|
|
1143
|
+
if (settings.hasOwnProperty('envMap')) {
|
|
1144
|
+
material.envMap = settings.envMap;
|
|
1145
|
+
}
|
|
1146
|
+
if (settings.hasOwnProperty('envMapIntensity')) {
|
|
1147
|
+
material.envMapIntensity = settings.envMapIntensity;
|
|
1148
|
+
}
|
|
1149
|
+
if (settings.hasOwnProperty('reflectivity')) {
|
|
1150
|
+
material.reflectivity = settings.reflectivity;
|
|
1151
|
+
}
|
|
1152
|
+
if (settings.hasOwnProperty('displacementValue')) {
|
|
1153
|
+
material.displacementValue = settings.displacementValue;
|
|
1154
|
+
}
|
|
1155
|
+
if (settings.hasOwnProperty('transparency')) {
|
|
1156
|
+
material.transparency = settings.transparency;
|
|
1157
|
+
}
|
|
1158
|
+
if (settings.hasOwnProperty('transmission')) {
|
|
1159
|
+
material.transmission = settings.transmission;
|
|
1160
|
+
}
|
|
960
1161
|
};
|
|
961
1162
|
return AssetUtils;
|
|
962
1163
|
}());
|
|
@@ -970,6 +1171,8 @@
|
|
|
970
1171
|
var VariationSettings = /** @class */ (function () {
|
|
971
1172
|
function VariationSettings() {
|
|
972
1173
|
this.settings = {};
|
|
1174
|
+
this.loading = false;
|
|
1175
|
+
this.loaded = new rxjs.Subject();
|
|
973
1176
|
}
|
|
974
1177
|
return VariationSettings;
|
|
975
1178
|
}());
|
|
@@ -978,6 +1181,9 @@
|
|
|
978
1181
|
var VariationUtils = /** @class */ (function () {
|
|
979
1182
|
function VariationUtils() {
|
|
980
1183
|
}
|
|
1184
|
+
VariationUtils.ClearCache = function () {
|
|
1185
|
+
this.MaterialCache.clear();
|
|
1186
|
+
};
|
|
981
1187
|
VariationUtils.LoadVariation = function (assetPath, fileName) {
|
|
982
1188
|
return __awaiter(this, void 0, void 0, function () {
|
|
983
1189
|
var id, file, err_1, mute;
|
|
@@ -993,7 +1199,7 @@
|
|
|
993
1199
|
id = fileName.substr(0, fileName.lastIndexOf('.ione3d'));
|
|
994
1200
|
_a.label = 1;
|
|
995
1201
|
case 1:
|
|
996
|
-
_a.trys.push([1,
|
|
1202
|
+
_a.trys.push([1, 6, , 7]);
|
|
997
1203
|
if (!assetPath.endsWith('/')) {
|
|
998
1204
|
assetPath += '/';
|
|
999
1205
|
}
|
|
@@ -1001,16 +1207,22 @@
|
|
|
1001
1207
|
console.error('downloadVariation not defined in window global');
|
|
1002
1208
|
return [2 /*return*/, null];
|
|
1003
1209
|
}
|
|
1004
|
-
|
|
1005
|
-
|
|
1210
|
+
file = void 0;
|
|
1211
|
+
if (!this.MaterialCache.has(id)) return [3 /*break*/, 2];
|
|
1212
|
+
file = this.MaterialCache.get(id);
|
|
1213
|
+
return [3 /*break*/, 4];
|
|
1214
|
+
case 2: return [4 /*yield*/, window.downloadVariation(assetPath.replace('https://cdn1.colijn-it.nl/', '') + "variation/" + fileName)];
|
|
1215
|
+
case 3:
|
|
1006
1216
|
file = _a.sent();
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
case 4:
|
|
1217
|
+
this.MaterialCache.set(id, file);
|
|
1218
|
+
_a.label = 4;
|
|
1219
|
+
case 4: return [4 /*yield*/, VariationUtils.GetVariationSettingsFromFile(id, file)];
|
|
1220
|
+
case 5: return [2 /*return*/, _a.sent()];
|
|
1221
|
+
case 6:
|
|
1010
1222
|
err_1 = _a.sent();
|
|
1011
1223
|
mute = err_1;
|
|
1012
1224
|
return [2 /*return*/, null];
|
|
1013
|
-
case
|
|
1225
|
+
case 7: return [2 /*return*/];
|
|
1014
1226
|
}
|
|
1015
1227
|
});
|
|
1016
1228
|
});
|
|
@@ -1060,6 +1272,7 @@
|
|
|
1060
1272
|
zipContent = _a.sent();
|
|
1061
1273
|
variationSettings = new VariationSettings();
|
|
1062
1274
|
variationSettings.id = id;
|
|
1275
|
+
if (!zipContent) return [3 /*break*/, 7];
|
|
1063
1276
|
if (!zipContent.files['index.json']) return [3 /*break*/, 3];
|
|
1064
1277
|
return [4 /*yield*/, zipContent.files['index.json'].async('string')];
|
|
1065
1278
|
case 2:
|
|
@@ -1083,58 +1296,106 @@
|
|
|
1083
1296
|
};
|
|
1084
1297
|
VariationUtils.CreateSettingsBasedOnIndex = function (index, variationSettings, zipContent) {
|
|
1085
1298
|
return __awaiter(this, void 0, void 0, function () {
|
|
1086
|
-
var _a, _b, _c, _d, _e, _f;
|
|
1087
|
-
return __generator(this, function (
|
|
1088
|
-
switch (
|
|
1299
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
1300
|
+
return __generator(this, function (_l) {
|
|
1301
|
+
switch (_l.label) {
|
|
1089
1302
|
case 0:
|
|
1090
1303
|
if (!index.normalFile) return [3 /*break*/, 2];
|
|
1091
1304
|
_a = variationSettings;
|
|
1092
1305
|
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.normalFile], index.normalFile)];
|
|
1093
1306
|
case 1:
|
|
1094
|
-
_a.normal =
|
|
1307
|
+
_a.normal = _l.sent();
|
|
1095
1308
|
variationSettings.normalFilename = index.normalFile;
|
|
1096
|
-
|
|
1309
|
+
_l.label = 2;
|
|
1097
1310
|
case 2:
|
|
1098
|
-
if (!index.
|
|
1311
|
+
if (!index.diffuseFile) return [3 /*break*/, 4];
|
|
1099
1312
|
_b = variationSettings;
|
|
1100
|
-
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.
|
|
1313
|
+
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.diffuseFile], index.diffuseFile)];
|
|
1101
1314
|
case 3:
|
|
1102
|
-
_b.
|
|
1103
|
-
variationSettings.
|
|
1104
|
-
|
|
1315
|
+
_b.texture = _l.sent();
|
|
1316
|
+
variationSettings.textureFilename = index.diffuseFile;
|
|
1317
|
+
_l.label = 4;
|
|
1105
1318
|
case 4:
|
|
1106
|
-
if (!index.
|
|
1319
|
+
if (!index.ormFile) return [3 /*break*/, 6];
|
|
1107
1320
|
_c = variationSettings;
|
|
1108
|
-
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.
|
|
1321
|
+
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.ormFile], index.ormFile)];
|
|
1109
1322
|
case 5:
|
|
1110
|
-
_c.
|
|
1111
|
-
variationSettings.
|
|
1112
|
-
|
|
1323
|
+
_c.orm = _l.sent();
|
|
1324
|
+
variationSettings.ormFilename = index.ormFile;
|
|
1325
|
+
return [3 /*break*/, 12];
|
|
1113
1326
|
case 6:
|
|
1114
|
-
if (!index.
|
|
1327
|
+
if (!index.aoFile) return [3 /*break*/, 8];
|
|
1115
1328
|
_d = variationSettings;
|
|
1116
|
-
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.
|
|
1329
|
+
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.aoFile], index.aoFile)];
|
|
1117
1330
|
case 7:
|
|
1118
|
-
_d.
|
|
1119
|
-
variationSettings.
|
|
1120
|
-
|
|
1331
|
+
_d.ao = _l.sent();
|
|
1332
|
+
variationSettings.aoFilename = index.aoFile;
|
|
1333
|
+
_l.label = 8;
|
|
1121
1334
|
case 8:
|
|
1122
|
-
if (!index.
|
|
1335
|
+
if (!index.metalnessFile) return [3 /*break*/, 10];
|
|
1123
1336
|
_e = variationSettings;
|
|
1124
|
-
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.
|
|
1337
|
+
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.metalnessFile], index.metalnessFile)];
|
|
1125
1338
|
case 9:
|
|
1126
|
-
_e.
|
|
1127
|
-
variationSettings.
|
|
1128
|
-
|
|
1339
|
+
_e.metalness = _l.sent();
|
|
1340
|
+
variationSettings.metalnessFilename = index.metalnessFile;
|
|
1341
|
+
_l.label = 10;
|
|
1129
1342
|
case 10:
|
|
1343
|
+
if (!index.roughnessFile) return [3 /*break*/, 12];
|
|
1130
1344
|
_f = variationSettings;
|
|
1131
|
-
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[
|
|
1345
|
+
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.roughnessFile], index.roughnessFile)];
|
|
1132
1346
|
case 11:
|
|
1133
|
-
_f.
|
|
1134
|
-
|
|
1347
|
+
_f.roughness = _l.sent();
|
|
1348
|
+
variationSettings.roughnessFilename = index.roughnessFile;
|
|
1349
|
+
_l.label = 12;
|
|
1350
|
+
case 12:
|
|
1351
|
+
if (!index.displacementFile) return [3 /*break*/, 14];
|
|
1352
|
+
_g = variationSettings;
|
|
1353
|
+
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.displacementFile], index.displacementFile)];
|
|
1354
|
+
case 13:
|
|
1355
|
+
_g.displacement = _l.sent();
|
|
1356
|
+
variationSettings.displacementFilename = index.displacementFile;
|
|
1357
|
+
_l.label = 14;
|
|
1358
|
+
case 14:
|
|
1359
|
+
if (!index.emissiveFile) return [3 /*break*/, 16];
|
|
1360
|
+
_h = variationSettings;
|
|
1361
|
+
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.emissiveFile], index.emissiveFile)];
|
|
1362
|
+
case 15:
|
|
1363
|
+
_h.emissive = _l.sent();
|
|
1364
|
+
variationSettings.emissiveFilename = index.emissiveFile;
|
|
1365
|
+
_l.label = 16;
|
|
1366
|
+
case 16:
|
|
1367
|
+
if (!index.envMapFile) return [3 /*break*/, 18];
|
|
1368
|
+
_j = variationSettings;
|
|
1369
|
+
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files[index.envMapFile], index.envMapFile)];
|
|
1370
|
+
case 17:
|
|
1371
|
+
_j.envMap = _l.sent();
|
|
1372
|
+
variationSettings.envMapFilename = index.envMapFile;
|
|
1373
|
+
_l.label = 18;
|
|
1374
|
+
case 18:
|
|
1375
|
+
_k = variationSettings;
|
|
1376
|
+
return [4 /*yield*/, VariationUtils.LoadFileContentFromZip(zipContent.files['repeat.json'], 'repeat.json', false)];
|
|
1377
|
+
case 19:
|
|
1378
|
+
_k.settings =
|
|
1379
|
+
(_l.sent()) || {};
|
|
1135
1380
|
Object.assign(variationSettings.settings, index.repeat);
|
|
1136
1381
|
variationSettings.settings.metalness = index.metalness;
|
|
1137
1382
|
variationSettings.settings.roughness = index.roughness;
|
|
1383
|
+
if (index.sheenColor) {
|
|
1384
|
+
variationSettings.settings.sheenColor = new THREE__namespace.Color(index.sheenColor.r, index.sheenColor.g, index.sheenColor.b);
|
|
1385
|
+
}
|
|
1386
|
+
variationSettings.settings.envMap = index.envMap;
|
|
1387
|
+
variationSettings.settings.envMapIntensity = index.envMapIntensity;
|
|
1388
|
+
variationSettings.settings.transparent = index.transparent;
|
|
1389
|
+
variationSettings.settings.opacity = index.opacity;
|
|
1390
|
+
if (index.emissiveValue) {
|
|
1391
|
+
variationSettings.settings.emissiveValue = new THREE__namespace.Color(index.emissiveValue.r, index.emissiveValue.g, index.emissiveValue.b);
|
|
1392
|
+
}
|
|
1393
|
+
variationSettings.settings.emissiveIntensity = index.emissiveIntensity;
|
|
1394
|
+
variationSettings.settings.reflectivity = index.reflectivity;
|
|
1395
|
+
variationSettings.settings.displacementValue = index.displacementValue;
|
|
1396
|
+
variationSettings.settings.side = index.side;
|
|
1397
|
+
variationSettings.settings.transparency = index.transparency;
|
|
1398
|
+
variationSettings.settings.transmission = index.transmission;
|
|
1138
1399
|
return [2 /*return*/];
|
|
1139
1400
|
}
|
|
1140
1401
|
});
|
|
@@ -1150,13 +1411,13 @@
|
|
|
1150
1411
|
allLoaded = [];
|
|
1151
1412
|
_loop_1 = function (fileName) {
|
|
1152
1413
|
var file_1;
|
|
1153
|
-
return __generator(this, function (
|
|
1154
|
-
switch (
|
|
1414
|
+
return __generator(this, function (_d) {
|
|
1415
|
+
switch (_d.label) {
|
|
1155
1416
|
case 0:
|
|
1156
|
-
if (!zipContent.files
|
|
1417
|
+
if (!zipContent.files.hasOwnProperty(fileName)) return [3 /*break*/, 2];
|
|
1157
1418
|
return [4 /*yield*/, zipContent.files[fileName]];
|
|
1158
1419
|
case 1:
|
|
1159
|
-
file_1 =
|
|
1420
|
+
file_1 = _d.sent();
|
|
1160
1421
|
if (file_1.name.toLowerCase().indexOf('normal') > -1 && this_1.FileIsImage(file_1.name)) {
|
|
1161
1422
|
allLoaded.push(zipContent.files[fileName].async('base64').then(function (normalFile) {
|
|
1162
1423
|
variationSettings.normal = "data:image/" + _this.GetBase64FileType(file_1.name) + ";base64," + normalFile;
|
|
@@ -1187,6 +1448,24 @@
|
|
|
1187
1448
|
variationSettings.textureFilename = fileName;
|
|
1188
1449
|
}));
|
|
1189
1450
|
}
|
|
1451
|
+
else if (file_1.name.toLowerCase().indexOf('displacement') > -1 && this_1.FileIsImage(file_1.name)) {
|
|
1452
|
+
allLoaded.push(zipContent.files[fileName].async('base64').then(function (displacementFile) {
|
|
1453
|
+
variationSettings.displacement = "data:image/" + _this.GetBase64FileType(file_1.name) + ";base64," + displacementFile;
|
|
1454
|
+
variationSettings.displacementFilename = fileName;
|
|
1455
|
+
}));
|
|
1456
|
+
}
|
|
1457
|
+
else if (file_1.name.toLowerCase().indexOf('emissive') > -1 && this_1.FileIsImage(file_1.name)) {
|
|
1458
|
+
allLoaded.push(zipContent.files[fileName].async('base64').then(function (emissiveFile) {
|
|
1459
|
+
variationSettings.emissive = "data:image/" + _this.GetBase64FileType(file_1.name) + ";base64," + emissiveFile;
|
|
1460
|
+
variationSettings.emissiveFilename = fileName;
|
|
1461
|
+
}));
|
|
1462
|
+
}
|
|
1463
|
+
else if (file_1.name.toLowerCase().indexOf('envMap') > -1 && this_1.FileIsImage(file_1.name)) {
|
|
1464
|
+
allLoaded.push(zipContent.files[fileName].async('base64').then(function (envMapFile) {
|
|
1465
|
+
variationSettings.envMap = "data:image/" + _this.GetBase64FileType(file_1.name) + ";base64," + envMapFile;
|
|
1466
|
+
variationSettings.envMapFilename = fileName;
|
|
1467
|
+
}));
|
|
1468
|
+
}
|
|
1190
1469
|
else if (file_1.name.indexOf('.jp') > -1) {
|
|
1191
1470
|
allLoaded.push(zipContent.files[fileName].async('base64').then(function (textureFile) {
|
|
1192
1471
|
variationSettings.texture = 'data:image/jpeg;base64,' + textureFile;
|
|
@@ -1197,13 +1476,13 @@
|
|
|
1197
1476
|
allLoaded.push(zipContent.files[fileName].async('string').then(function (settingsFile) {
|
|
1198
1477
|
var settingsFileObj = JSON.parse(settingsFile);
|
|
1199
1478
|
for (var key in settingsFileObj) {
|
|
1200
|
-
if (settingsFileObj
|
|
1479
|
+
if (settingsFileObj.hasOwnProperty(key)) {
|
|
1201
1480
|
variationSettings.settings[key] = settingsFileObj[key];
|
|
1202
1481
|
}
|
|
1203
1482
|
}
|
|
1204
1483
|
}));
|
|
1205
1484
|
}
|
|
1206
|
-
|
|
1485
|
+
_d.label = 2;
|
|
1207
1486
|
case 2: return [2 /*return*/];
|
|
1208
1487
|
}
|
|
1209
1488
|
});
|
|
@@ -1280,41 +1559,58 @@
|
|
|
1280
1559
|
// Get the content
|
|
1281
1560
|
VariationUtils.GetZipContent = function (file) {
|
|
1282
1561
|
return __awaiter(this, void 0, void 0, function () {
|
|
1283
|
-
var jszip,
|
|
1562
|
+
var jszip, e_1;
|
|
1284
1563
|
return __generator(this, function (_a) {
|
|
1285
1564
|
switch (_a.label) {
|
|
1286
1565
|
case 0:
|
|
1287
|
-
|
|
1566
|
+
_a.trys.push([0, 2, , 3]);
|
|
1567
|
+
jszip = new JSZip__default["default"]();
|
|
1288
1568
|
return [4 /*yield*/, jszip.loadAsync(file)];
|
|
1289
|
-
case 1:
|
|
1290
|
-
|
|
1291
|
-
|
|
1569
|
+
case 1: return [2 /*return*/, _a.sent()];
|
|
1570
|
+
case 2:
|
|
1571
|
+
e_1 = _a.sent();
|
|
1572
|
+
return [2 /*return*/, null];
|
|
1573
|
+
case 3: return [2 /*return*/];
|
|
1292
1574
|
}
|
|
1293
1575
|
});
|
|
1294
1576
|
});
|
|
1295
1577
|
};
|
|
1296
|
-
VariationUtils.MaterialCache = new Map();
|
|
1297
1578
|
return VariationUtils;
|
|
1298
|
-
}());
|
|
1579
|
+
}());
|
|
1580
|
+
VariationUtils.MaterialCache = new Map();
|
|
1299
1581
|
|
|
1300
1582
|
var VariationHelper = /** @class */ (function () {
|
|
1301
1583
|
function VariationHelper() {
|
|
1302
1584
|
this._lastKnownVariations = new Map();
|
|
1303
1585
|
}
|
|
1304
1586
|
VariationHelper.prototype.clearCache = function () {
|
|
1305
|
-
var
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1587
|
+
var variationMap = Array.from(this._lastKnownVariations.values());
|
|
1588
|
+
variationMap.forEach(function (variations) {
|
|
1589
|
+
variations.forEach(function (variation) {
|
|
1590
|
+
try {
|
|
1591
|
+
if (variation.material) {
|
|
1592
|
+
if (variation.material.texture) {
|
|
1593
|
+
variation.material.texture.dispose();
|
|
1594
|
+
}
|
|
1595
|
+
if (variation.material.normal) {
|
|
1596
|
+
variation.material.normal.dispose();
|
|
1597
|
+
}
|
|
1598
|
+
if (variation.material.metalness) {
|
|
1599
|
+
variation.material.metalness.dispose();
|
|
1600
|
+
}
|
|
1601
|
+
if (variation.material.roughness) {
|
|
1602
|
+
variation.material.roughness.dispose();
|
|
1603
|
+
}
|
|
1604
|
+
if (variation.material.ao) {
|
|
1605
|
+
variation.material.ao.dispose();
|
|
1606
|
+
}
|
|
1607
|
+
}
|
|
1608
|
+
}
|
|
1609
|
+
catch (e) {
|
|
1610
|
+
}
|
|
1316
1611
|
});
|
|
1317
|
-
}
|
|
1612
|
+
});
|
|
1613
|
+
VariationUtils.ClearCache();
|
|
1318
1614
|
};
|
|
1319
1615
|
VariationHelper.prototype.loadPart = function (obj, parts, usePbr) {
|
|
1320
1616
|
if (usePbr === void 0) { usePbr = false; }
|
|
@@ -1358,7 +1654,7 @@
|
|
|
1358
1654
|
});
|
|
1359
1655
|
});
|
|
1360
1656
|
};
|
|
1361
|
-
VariationHelper.prototype.loadVariation = function (
|
|
1657
|
+
VariationHelper.prototype.loadVariation = function (obj, parts, usePbr) {
|
|
1362
1658
|
if (usePbr === void 0) { usePbr = false; }
|
|
1363
1659
|
return __awaiter(this, void 0, void 0, function () {
|
|
1364
1660
|
var len, i, variations, lastKnownVariations, j, variationSettings, newVariation, _a, e_2;
|
|
@@ -1373,8 +1669,8 @@
|
|
|
1373
1669
|
if (!(i < len)) return [3 /*break*/, 8];
|
|
1374
1670
|
variations = parts[i].variations;
|
|
1375
1671
|
if (!variations || variations.length === 0) {
|
|
1376
|
-
if (this._getLastKnownVariations(
|
|
1377
|
-
parts[i].variations = this._getLastKnownVariations(
|
|
1672
|
+
if (this._getLastKnownVariations(parts[i].nodeId)) {
|
|
1673
|
+
parts[i].variations = this._getLastKnownVariations(parts[i].nodeId);
|
|
1378
1674
|
this._applyVariations(obj, parts[i], usePbr);
|
|
1379
1675
|
return [3 /*break*/, 7];
|
|
1380
1676
|
}
|
|
@@ -1406,7 +1702,7 @@
|
|
|
1406
1702
|
j++;
|
|
1407
1703
|
return [3 /*break*/, 2];
|
|
1408
1704
|
case 6:
|
|
1409
|
-
this._setLastKnownVariations(
|
|
1705
|
+
this._setLastKnownVariations(parts[i].nodeId, lastKnownVariations);
|
|
1410
1706
|
parts[i].variations = lastKnownVariations;
|
|
1411
1707
|
this._applyVariations(obj, parts[i], usePbr);
|
|
1412
1708
|
_b.label = 7;
|
|
@@ -1440,7 +1736,7 @@
|
|
|
1440
1736
|
var child = children[i];
|
|
1441
1737
|
if (child !== null && child !== undefined) {
|
|
1442
1738
|
child.traverse(function (mesh) {
|
|
1443
|
-
if (mesh instanceof
|
|
1739
|
+
if (mesh instanceof THREE__namespace.Mesh && partMaterial) {
|
|
1444
1740
|
if (Array.isArray(mesh.material)) { // multimaterial support
|
|
1445
1741
|
for (var j = 0, jlen = mesh.material.length; j < jlen; j++) {
|
|
1446
1742
|
if (mesh.material[j].name.toLowerCase().indexOf('fixed_frame') !== -1) {
|
|
@@ -1467,7 +1763,7 @@
|
|
|
1467
1763
|
var child = children[i];
|
|
1468
1764
|
if (child !== null && child !== undefined) {
|
|
1469
1765
|
child.traverse(function (mesh) {
|
|
1470
|
-
if (mesh instanceof
|
|
1766
|
+
if (mesh instanceof THREE__namespace.Mesh && part.variations && part.variations.length > 0 && mesh.name.toLowerCase().indexOf('c_')) {
|
|
1471
1767
|
for (var j = 0; j < part.variations.length; j++) {
|
|
1472
1768
|
var variation = part.variations[j];
|
|
1473
1769
|
if (variation.material) {
|
|
@@ -1495,85 +1791,190 @@
|
|
|
1495
1791
|
if (usePbr === void 0) { usePbr = false; }
|
|
1496
1792
|
if (variation.material.texture) {
|
|
1497
1793
|
variation.material.texture.needsUpdate = true;
|
|
1794
|
+
// variation.material.texture.mapping = THREE.EquirectangularReflectionMapping;
|
|
1498
1795
|
}
|
|
1499
1796
|
if (!usePbr) {
|
|
1500
|
-
var
|
|
1797
|
+
var newMaterial = new THREE__namespace.MeshPhongMaterial({
|
|
1501
1798
|
name: name,
|
|
1502
1799
|
shininess: variation.material.shininess,
|
|
1503
1800
|
specular: variation.material.specular,
|
|
1504
1801
|
map: variation.material.texture,
|
|
1505
1802
|
normalMap: variation.material.normal
|
|
1506
1803
|
});
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
return
|
|
1804
|
+
newMaterial.color.setRGB(0.8, 0.8, 0.8);
|
|
1805
|
+
newMaterial.needsUpdate = true;
|
|
1806
|
+
return newMaterial;
|
|
1510
1807
|
}
|
|
1511
|
-
|
|
1808
|
+
if (variation.material.sheenColor || variation.material.reflectivity) {
|
|
1512
1809
|
var params = {
|
|
1513
|
-
// side:
|
|
1810
|
+
// side: material.side ? material.side : FrontSide,
|
|
1514
1811
|
name: name,
|
|
1515
1812
|
roughness: variation.material.roughnessValue ? variation.material.roughnessValue : 1,
|
|
1516
1813
|
metalness: variation.material.metalnessValue ? variation.material.metalnessValue : 0,
|
|
1814
|
+
envMapIntensity: variation.material.envMapIntensity ? variation.material.envMapIntensity : 0.01,
|
|
1815
|
+
clearcoatMap: variation.material.clearcoatMap ? variation.material.clearcoatMap : null,
|
|
1816
|
+
clearcoatRoughnessMap: variation.material.clearcoatRoughnessMap ? variation.material.clearcoatRoughnessMap : null,
|
|
1817
|
+
// wireframe: true,
|
|
1818
|
+
// opacity: 0.3,
|
|
1819
|
+
// transparent: true,
|
|
1517
1820
|
};
|
|
1821
|
+
if (variation.material.displacementValue) {
|
|
1822
|
+
params.displacementScale = variation.material.displacementValue;
|
|
1823
|
+
}
|
|
1824
|
+
if (variation.material.sheenColor) {
|
|
1825
|
+
params.sheen = variation.material.sheenColor;
|
|
1826
|
+
}
|
|
1827
|
+
if (variation.material.opacity) {
|
|
1828
|
+
params.opacity = variation.material.opacity;
|
|
1829
|
+
}
|
|
1830
|
+
if (variation.material.transparent) {
|
|
1831
|
+
params.transparent = variation.material.transparent;
|
|
1832
|
+
}
|
|
1833
|
+
if (variation.material.emissiveValue) {
|
|
1834
|
+
params.emissive = variation.material.emissiveValue;
|
|
1835
|
+
}
|
|
1836
|
+
if (variation.material.emissiveIntensityValue) {
|
|
1837
|
+
params.emissiveIntensity = variation.material.emissiveIntensityValue;
|
|
1838
|
+
}
|
|
1518
1839
|
if (variation.material.texture) {
|
|
1519
1840
|
params.map = variation.material.texture;
|
|
1841
|
+
params.map.needsUpdate = true;
|
|
1520
1842
|
}
|
|
1521
1843
|
if (variation.material.ao) {
|
|
1522
1844
|
params.aoMap = variation.material.ao;
|
|
1845
|
+
params.aoMap.needsUpdate = true;
|
|
1523
1846
|
}
|
|
1524
1847
|
if (variation.material.roughness) {
|
|
1525
1848
|
params.roughnessMap = variation.material.roughness;
|
|
1849
|
+
params.roughnessMap.needsUpdate = true;
|
|
1850
|
+
// variation.material.roughness.magFilter = NearestFilter;
|
|
1526
1851
|
}
|
|
1527
1852
|
if (variation.material.metalness) {
|
|
1528
1853
|
params.metalnessMap = variation.material.metalness;
|
|
1854
|
+
params.metalnessMap.needsUpdate = true;
|
|
1529
1855
|
}
|
|
1530
1856
|
if (variation.material.normal) {
|
|
1531
1857
|
params.normalMap = variation.material.normal;
|
|
1858
|
+
params.normalMap.needsUpdate = true;
|
|
1532
1859
|
}
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1860
|
+
if (variation.material.displacement) {
|
|
1861
|
+
params.displacementMap = variation.material.displacement;
|
|
1862
|
+
params.displacementMap.needsUpdate = true;
|
|
1863
|
+
}
|
|
1864
|
+
if (variation.material.emissive) {
|
|
1865
|
+
params.emissiveMap = variation.material.emissive;
|
|
1866
|
+
params.emissiveMap.needsUpdate = true;
|
|
1867
|
+
}
|
|
1868
|
+
if (variation.material.envMap) {
|
|
1869
|
+
if (variation.material.envMapIntensity != null || 0) {
|
|
1870
|
+
params.envMap = variation.material.envMap;
|
|
1871
|
+
params.envMap.needsUpdate = true;
|
|
1872
|
+
variation.material.envMap.mapping = THREE__namespace.EquirectangularReflectionMapping;
|
|
1873
|
+
variation.material.envMap.minFilter = THREE__namespace.NearestFilter;
|
|
1874
|
+
variation.material.envMap.magFilter = THREE__namespace.NearestFilter;
|
|
1875
|
+
}
|
|
1876
|
+
}
|
|
1877
|
+
if (variation.material.reflectivity) {
|
|
1878
|
+
params.reflectivity = variation.material.reflectivity;
|
|
1879
|
+
}
|
|
1880
|
+
if (variation.material.side) {
|
|
1881
|
+
params.side = variation.material.side;
|
|
1882
|
+
}
|
|
1883
|
+
var newMaterial = new THREE__namespace.MeshPhysicalMaterial(params);
|
|
1884
|
+
newMaterial.color.setRGB(1, 1, 1);
|
|
1885
|
+
newMaterial.needsUpdate = true;
|
|
1886
|
+
if (variation.material.transmission) {
|
|
1887
|
+
newMaterial.transmission = variation.material.transmission;
|
|
1888
|
+
}
|
|
1889
|
+
return newMaterial;
|
|
1543
1890
|
}
|
|
1544
1891
|
else {
|
|
1545
|
-
var
|
|
1546
|
-
|
|
1892
|
+
var params = {
|
|
1893
|
+
// side: material.side ? material.side : FrontSide,
|
|
1894
|
+
name: name,
|
|
1895
|
+
roughness: variation.material.roughnessValue ? variation.material.roughnessValue : 1,
|
|
1896
|
+
metalness: variation.material.metalnessValue ? variation.material.metalnessValue : 0,
|
|
1897
|
+
envMapIntensity: variation.material.envMapIntensity ? variation.material.envMapIntensity : 0.01
|
|
1898
|
+
// wireframe: true,
|
|
1899
|
+
// opacity: 0.3,
|
|
1900
|
+
// transparent: true,
|
|
1901
|
+
};
|
|
1902
|
+
if (variation.material.displacementValue) {
|
|
1903
|
+
params.displacementScale = variation.material.displacementValue;
|
|
1904
|
+
}
|
|
1905
|
+
if (variation.material.opacity) {
|
|
1906
|
+
params.opacity = variation.material.opacity;
|
|
1907
|
+
}
|
|
1908
|
+
if (variation.material.transparent) {
|
|
1909
|
+
params.transparent = variation.material.transparent;
|
|
1910
|
+
}
|
|
1911
|
+
if (variation.material.emissiveValue) {
|
|
1912
|
+
params.emissive = variation.material.emissiveValue;
|
|
1913
|
+
}
|
|
1914
|
+
if (variation.material.emissiveIntensityValue) {
|
|
1915
|
+
params.emissiveIntensity = variation.material.emissiveIntensityValue;
|
|
1916
|
+
}
|
|
1917
|
+
if (variation.material.texture) {
|
|
1918
|
+
params.map = variation.material.texture;
|
|
1919
|
+
params.map.needsUpdate = true;
|
|
1920
|
+
}
|
|
1921
|
+
if (variation.material.ao) {
|
|
1922
|
+
params.aoMap = variation.material.ao;
|
|
1923
|
+
params.aoMap.needsUpdate = true;
|
|
1924
|
+
}
|
|
1925
|
+
if (variation.material.roughness) {
|
|
1926
|
+
params.roughnessMap = variation.material.roughness;
|
|
1927
|
+
params.roughnessMap.needsUpdate = true;
|
|
1928
|
+
// variation.material.roughness.magFilter = NearestFilter;
|
|
1929
|
+
}
|
|
1930
|
+
if (variation.material.metalness) {
|
|
1931
|
+
params.metalnessMap = variation.material.metalness;
|
|
1932
|
+
params.metalnessMap.needsUpdate = true;
|
|
1933
|
+
}
|
|
1934
|
+
if (variation.material.normal) {
|
|
1935
|
+
params.normalMap = variation.material.normal;
|
|
1936
|
+
params.normalMap.needsUpdate = true;
|
|
1937
|
+
}
|
|
1938
|
+
if (variation.material.displacement) {
|
|
1939
|
+
params.displacementMap = variation.material.displacement;
|
|
1940
|
+
params.displacementMap.needsUpdate = true;
|
|
1941
|
+
}
|
|
1942
|
+
if (variation.material.emissive) {
|
|
1943
|
+
params.emissiveMap = variation.material.emissive;
|
|
1944
|
+
params.emissiveMap.needsUpdate = true;
|
|
1945
|
+
}
|
|
1946
|
+
if (variation.material.envMap) {
|
|
1947
|
+
if (variation.material.envMapIntensity != null || 0) {
|
|
1948
|
+
params.envMap = variation.material.envMap;
|
|
1949
|
+
params.envMap.needsUpdate = true;
|
|
1950
|
+
variation.material.envMap.mapping = THREE__namespace.EquirectangularReflectionMapping;
|
|
1951
|
+
variation.material.envMap.minFilter = THREE__namespace.NearestFilter;
|
|
1952
|
+
variation.material.envMap.magFilter = THREE__namespace.NearestFilter;
|
|
1953
|
+
}
|
|
1954
|
+
}
|
|
1955
|
+
if (variation.material.side) {
|
|
1956
|
+
params.side = variation.material.side;
|
|
1957
|
+
}
|
|
1958
|
+
var newMaterial = new THREE__namespace.MeshStandardMaterial(params);
|
|
1959
|
+
newMaterial.color.setRGB(1, 1, 1);
|
|
1960
|
+
newMaterial.needsUpdate = true;
|
|
1961
|
+
return newMaterial;
|
|
1547
1962
|
}
|
|
1548
1963
|
};
|
|
1549
|
-
VariationHelper.prototype.
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1964
|
+
VariationHelper.prototype._setLastKnownVariations = function (id, variation) {
|
|
1965
|
+
this._lastKnownVariations.set(id, variation);
|
|
1966
|
+
};
|
|
1967
|
+
VariationHelper.prototype._getLastKnownVariations = function (id) {
|
|
1968
|
+
if (this._lastKnownVariations.has(id)) {
|
|
1969
|
+
return this._lastKnownVariations.get(id);
|
|
1555
1970
|
}
|
|
1556
1971
|
return null;
|
|
1557
1972
|
};
|
|
1558
1973
|
return VariationHelper;
|
|
1559
1974
|
}());
|
|
1560
1975
|
|
|
1561
|
-
var ServiceLocator = /** @class */ (function () {
|
|
1562
|
-
function ServiceLocator() {
|
|
1563
|
-
}
|
|
1564
|
-
ServiceLocator.injector = undefined;
|
|
1565
|
-
ServiceLocator = __decorate([
|
|
1566
|
-
core.Injectable()
|
|
1567
|
-
], ServiceLocator);
|
|
1568
|
-
return ServiceLocator;
|
|
1569
|
-
}());
|
|
1570
|
-
|
|
1571
1976
|
var ConfiguratorService = /** @class */ (function () {
|
|
1572
|
-
function ConfiguratorService(
|
|
1573
|
-
this._injector = _injector;
|
|
1574
|
-
if (!ServiceLocator.injector) {
|
|
1575
|
-
ServiceLocator.injector = _injector;
|
|
1576
|
-
}
|
|
1977
|
+
function ConfiguratorService() {
|
|
1577
1978
|
}
|
|
1578
1979
|
ConfiguratorService.prototype.initApi = function (options) {
|
|
1579
1980
|
this._configuratorApi = new configurator.Configurator(options);
|
|
@@ -1707,21 +2108,67 @@
|
|
|
1707
2108
|
});
|
|
1708
2109
|
});
|
|
1709
2110
|
};
|
|
1710
|
-
ConfiguratorService.ctorParameters = function () { return [
|
|
1711
|
-
{ type: core.Injector }
|
|
1712
|
-
]; };
|
|
1713
|
-
ConfiguratorService.ɵprov = core.ɵɵdefineInjectable({ factory: function ConfiguratorService_Factory() { return new ConfiguratorService(core.ɵɵinject(core.INJECTOR)); }, token: ConfiguratorService, providedIn: "root" });
|
|
1714
|
-
ConfiguratorService = __decorate([
|
|
1715
|
-
core.Injectable({
|
|
1716
|
-
providedIn: 'root'
|
|
1717
|
-
})
|
|
1718
|
-
], ConfiguratorService);
|
|
1719
2111
|
return ConfiguratorService;
|
|
1720
2112
|
}());
|
|
1721
2113
|
|
|
2114
|
+
var ObjectUtils = /** @class */ (function () {
|
|
2115
|
+
function ObjectUtils() {
|
|
2116
|
+
}
|
|
2117
|
+
ObjectUtils.DisposeNode = function (node) {
|
|
2118
|
+
node.traverse(function (obj) {
|
|
2119
|
+
if (obj instanceof THREE.Mesh) {
|
|
2120
|
+
if (obj.geometry) {
|
|
2121
|
+
obj.geometry.dispose();
|
|
2122
|
+
}
|
|
2123
|
+
ObjectUtils.DisposeMaterial(obj.material);
|
|
2124
|
+
}
|
|
2125
|
+
if (typeof obj.dispose === 'function') {
|
|
2126
|
+
// @ts-ignore
|
|
2127
|
+
obj.dispose();
|
|
2128
|
+
}
|
|
2129
|
+
});
|
|
2130
|
+
};
|
|
2131
|
+
ObjectUtils.DisposeMaterial = function (material) {
|
|
2132
|
+
var _this = this;
|
|
2133
|
+
if (!material) {
|
|
2134
|
+
return;
|
|
2135
|
+
}
|
|
2136
|
+
if (Array.isArray(material)) {
|
|
2137
|
+
material.forEach(function (mtrl) {
|
|
2138
|
+
_this.materialProps
|
|
2139
|
+
.filter(function (mapType) { return mtrl[mapType]; })
|
|
2140
|
+
.forEach(function (mapType) { return mtrl[mapType].dispose(); });
|
|
2141
|
+
mtrl.dispose(); // disposes any programs associated with the material
|
|
2142
|
+
});
|
|
2143
|
+
}
|
|
2144
|
+
else {
|
|
2145
|
+
this.materialProps
|
|
2146
|
+
.filter(function (mapType) { return material[mapType] && material[mapType].dispose; })
|
|
2147
|
+
.forEach(function (mapType) { return material[mapType].dispose(); });
|
|
2148
|
+
if (material.dispose) {
|
|
2149
|
+
material.dispose(); // disposes any programs associated with the material
|
|
2150
|
+
}
|
|
2151
|
+
}
|
|
2152
|
+
};
|
|
2153
|
+
ObjectUtils.DisposeObject = function (object) {
|
|
2154
|
+
var _this = this;
|
|
2155
|
+
if (!object) {
|
|
2156
|
+
return;
|
|
2157
|
+
}
|
|
2158
|
+
if (object.children.length) {
|
|
2159
|
+
object.children.forEach(function (child) { return _this.DisposeObject(child); });
|
|
2160
|
+
}
|
|
2161
|
+
this.DisposeNode(object);
|
|
2162
|
+
};
|
|
2163
|
+
return ObjectUtils;
|
|
2164
|
+
}());
|
|
2165
|
+
ObjectUtils.materialProps = ['map', 'lightMap', 'bumpMap', 'normalMap', 'specularMap', 'envMap', 'aoMap', 'roughnessMap', 'metalnessMap'];
|
|
2166
|
+
|
|
1722
2167
|
var Builder = /** @class */ (function () {
|
|
1723
|
-
function Builder(
|
|
2168
|
+
function Builder() {
|
|
1724
2169
|
this.selectionsReceived = new rxjs.BehaviorSubject([]);
|
|
2170
|
+
this.articleLoaded = new rxjs.BehaviorSubject(undefined);
|
|
2171
|
+
this.decosReceived = new rxjs.BehaviorSubject([]);
|
|
1725
2172
|
this.answersReceived = new rxjs.BehaviorSubject([]);
|
|
1726
2173
|
this.modelLoaded = new rxjs.BehaviorSubject(null);
|
|
1727
2174
|
this._selections = [];
|
|
@@ -1731,28 +2178,26 @@
|
|
|
1731
2178
|
this._placedAddables = [];
|
|
1732
2179
|
this._adjustables = [];
|
|
1733
2180
|
this._addables = [];
|
|
2181
|
+
this._imageCache = new Map();
|
|
1734
2182
|
this._articleCache = new Map();
|
|
2183
|
+
}
|
|
2184
|
+
Builder.prototype.init = function (scene, options) {
|
|
1735
2185
|
this._boFactory = new businessObjectFactory.BusinessObjectFactory();
|
|
1736
2186
|
this._threedUtils = new ThreedUtils();
|
|
1737
2187
|
this._variationHelper = new VariationHelper();
|
|
1738
2188
|
if (!scene) {
|
|
1739
2189
|
throw 'No scene object provided!';
|
|
1740
2190
|
}
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
this._configuratorService = ServiceLocator.injector.get(ConfiguratorService);
|
|
1746
|
-
}
|
|
1747
|
-
else {
|
|
1748
|
-
this._configuratorService = new ConfiguratorService(undefined);
|
|
2191
|
+
this._configuratorService = new ConfiguratorService();
|
|
2192
|
+
// this._imageCacheService = new ImageCacheService();
|
|
2193
|
+
if (options) {
|
|
2194
|
+
this._configuratorService.initApi(options);
|
|
1749
2195
|
}
|
|
1750
|
-
this._configuratorService.initApi(options);
|
|
1751
2196
|
this._scene = scene;
|
|
1752
|
-
}
|
|
2197
|
+
};
|
|
1753
2198
|
Builder.prototype.buildModel = function (sku, instanceId, goodId) {
|
|
1754
2199
|
return __awaiter(this, void 0, void 0, function () {
|
|
1755
|
-
var promises, e_1;
|
|
2200
|
+
var promises, build, e_1;
|
|
1756
2201
|
return __generator(this, function (_a) {
|
|
1757
2202
|
switch (_a.label) {
|
|
1758
2203
|
case 0:
|
|
@@ -1761,14 +2206,14 @@
|
|
|
1761
2206
|
}
|
|
1762
2207
|
_a.label = 1;
|
|
1763
2208
|
case 1:
|
|
1764
|
-
_a.trys.push([1,
|
|
2209
|
+
_a.trys.push([1, 9, , 10]);
|
|
1765
2210
|
return [4 /*yield*/, this._setInstanceId(sku, instanceId, goodId)];
|
|
1766
2211
|
case 2:
|
|
1767
2212
|
_a.sent();
|
|
1768
2213
|
return [4 /*yield*/, this._prepareConfiguration(this._sku, this._goodId)];
|
|
1769
2214
|
case 3:
|
|
1770
2215
|
_a.sent();
|
|
1771
|
-
if (!this._source) return [3 /*break*/,
|
|
2216
|
+
if (!this._source) return [3 /*break*/, 7];
|
|
1772
2217
|
return [4 /*yield*/, this._configuratorService.setInstanceToConfigure(this._instanceId)];
|
|
1773
2218
|
case 4:
|
|
1774
2219
|
_a.sent();
|
|
@@ -1783,13 +2228,51 @@
|
|
|
1783
2228
|
return [2 /*return*/];
|
|
1784
2229
|
}
|
|
1785
2230
|
this._linkSelectionsAndDecos();
|
|
1786
|
-
return [
|
|
1787
|
-
case 6:
|
|
1788
|
-
|
|
1789
|
-
|
|
2231
|
+
return [4 /*yield*/, this._build()];
|
|
2232
|
+
case 6:
|
|
2233
|
+
build = _a.sent();
|
|
2234
|
+
this._cleanUp();
|
|
2235
|
+
return [2 /*return*/, build];
|
|
2236
|
+
case 7: throw 'GLB source not found!';
|
|
2237
|
+
case 8: return [3 /*break*/, 10];
|
|
2238
|
+
case 9:
|
|
1790
2239
|
e_1 = _a.sent();
|
|
1791
2240
|
throw e_1;
|
|
1792
|
-
case
|
|
2241
|
+
case 10: return [2 /*return*/];
|
|
2242
|
+
}
|
|
2243
|
+
});
|
|
2244
|
+
});
|
|
2245
|
+
};
|
|
2246
|
+
Builder.prototype.buildModelFromData = function (selections, decos, assetUrl, cdnUrl, schema) {
|
|
2247
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
2248
|
+
var build, e_2;
|
|
2249
|
+
return __generator(this, function (_a) {
|
|
2250
|
+
switch (_a.label) {
|
|
2251
|
+
case 0:
|
|
2252
|
+
if (!this._scene) {
|
|
2253
|
+
return [2 /*return*/];
|
|
2254
|
+
}
|
|
2255
|
+
_a.label = 1;
|
|
2256
|
+
case 1:
|
|
2257
|
+
_a.trys.push([1, 6, , 7]);
|
|
2258
|
+
return [4 /*yield*/, this._downloadAsset(assetUrl, cdnUrl, schema)];
|
|
2259
|
+
case 2:
|
|
2260
|
+
_a.sent();
|
|
2261
|
+
if (!(selections && selections.length > 1 && decos && decos.length > 0 && this._source)) return [3 /*break*/, 4];
|
|
2262
|
+
this._selections = selections;
|
|
2263
|
+
this._decos = decos;
|
|
2264
|
+
this._linkSelectionsAndDecos();
|
|
2265
|
+
return [4 /*yield*/, this._build()];
|
|
2266
|
+
case 3:
|
|
2267
|
+
build = _a.sent();
|
|
2268
|
+
this._cleanUp();
|
|
2269
|
+
return [2 /*return*/, build];
|
|
2270
|
+
case 4: throw 'Unsufficient data provided!';
|
|
2271
|
+
case 5: return [3 /*break*/, 7];
|
|
2272
|
+
case 6:
|
|
2273
|
+
e_2 = _a.sent();
|
|
2274
|
+
throw e_2;
|
|
2275
|
+
case 7: return [2 /*return*/];
|
|
1793
2276
|
}
|
|
1794
2277
|
});
|
|
1795
2278
|
});
|
|
@@ -1846,6 +2329,54 @@
|
|
|
1846
2329
|
});
|
|
1847
2330
|
});
|
|
1848
2331
|
};
|
|
2332
|
+
Builder.prototype.getImageForSelectionOrAnswer = function (object) {
|
|
2333
|
+
var _this = this;
|
|
2334
|
+
var includeMimeType = true, thumb = true;
|
|
2335
|
+
return new Promise(function (resolve, reject) {
|
|
2336
|
+
if (object && object.nodeId) {
|
|
2337
|
+
if (!_this._imageCache.has(object.nodeId)) {
|
|
2338
|
+
return _this._configuratorService.getSingleImage(object.nodeId, 4, includeMimeType, thumb, true)
|
|
2339
|
+
.then(function (responseData) {
|
|
2340
|
+
var base64 = _this._handleResponseData(includeMimeType, thumb, responseData);
|
|
2341
|
+
_this._imageCache.set(object.nodeId, base64);
|
|
2342
|
+
resolve(base64);
|
|
2343
|
+
}).catch(function () {
|
|
2344
|
+
reject();
|
|
2345
|
+
});
|
|
2346
|
+
}
|
|
2347
|
+
else {
|
|
2348
|
+
resolve(_this._imageCache.get(object.nodeId));
|
|
2349
|
+
}
|
|
2350
|
+
}
|
|
2351
|
+
else {
|
|
2352
|
+
reject();
|
|
2353
|
+
}
|
|
2354
|
+
});
|
|
2355
|
+
};
|
|
2356
|
+
Builder.prototype._cleanUp = function () {
|
|
2357
|
+
this._sku = undefined;
|
|
2358
|
+
this._goodId = undefined;
|
|
2359
|
+
this._instanceId = undefined;
|
|
2360
|
+
this._variationHelper.clearCache();
|
|
2361
|
+
};
|
|
2362
|
+
Builder.prototype._handleResponseData = function (includeMimetype, thumb, responseData) {
|
|
2363
|
+
if (responseData && responseData.resultObject) {
|
|
2364
|
+
if (responseData.resultObject.filePath !== null && responseData.resultObject.filePath !== "") {
|
|
2365
|
+
return ImageUtils.getFixedImageFilepathUrl(responseData.resultObject.filePath);
|
|
2366
|
+
}
|
|
2367
|
+
else {
|
|
2368
|
+
if (includeMimetype) {
|
|
2369
|
+
return ImageUtils.getDocBodyWithMimeTypeDefinition(responseData.resultObject.fileName, thumb ? responseData.resultObject.thumbnailBody : responseData.resultObject.documentBody);
|
|
2370
|
+
}
|
|
2371
|
+
else {
|
|
2372
|
+
return thumb ? responseData.resultObject.thumbnailBody : responseData.resultObject.documentBody;
|
|
2373
|
+
}
|
|
2374
|
+
}
|
|
2375
|
+
}
|
|
2376
|
+
else {
|
|
2377
|
+
return '';
|
|
2378
|
+
}
|
|
2379
|
+
};
|
|
1849
2380
|
Builder.prototype._setInstanceId = function (sku, instanceId, goodId) {
|
|
1850
2381
|
return __awaiter(this, void 0, void 0, function () {
|
|
1851
2382
|
var result;
|
|
@@ -1886,33 +2417,47 @@
|
|
|
1886
2417
|
};
|
|
1887
2418
|
Builder.prototype._prepareConfiguration = function (sku, goodId) {
|
|
1888
2419
|
return __awaiter(this, void 0, void 0, function () {
|
|
1889
|
-
var article
|
|
1890
|
-
return __generator(this, function (
|
|
1891
|
-
switch (
|
|
2420
|
+
var article;
|
|
2421
|
+
return __generator(this, function (_a) {
|
|
2422
|
+
switch (_a.label) {
|
|
1892
2423
|
case 0: return [4 /*yield*/, this._getArticle(sku, goodId)];
|
|
1893
2424
|
case 1:
|
|
1894
|
-
article =
|
|
2425
|
+
article = _a.sent();
|
|
1895
2426
|
if (!(article && article.assetUrl)) return [3 /*break*/, 3];
|
|
2427
|
+
return [4 /*yield*/, this._downloadAsset(article.assetUrl, article.contentDeliveryUrl, article.distSchema)];
|
|
2428
|
+
case 2:
|
|
2429
|
+
_a.sent();
|
|
2430
|
+
_a.label = 3;
|
|
2431
|
+
case 3: return [2 /*return*/];
|
|
2432
|
+
}
|
|
2433
|
+
});
|
|
2434
|
+
});
|
|
2435
|
+
};
|
|
2436
|
+
Builder.prototype._downloadAsset = function (assetUrl, cdnUrl, schema) {
|
|
2437
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
2438
|
+
var _a;
|
|
2439
|
+
return __generator(this, function (_b) {
|
|
2440
|
+
switch (_b.label) {
|
|
2441
|
+
case 0:
|
|
1896
2442
|
_a = this;
|
|
1897
|
-
return [4 /*yield*/, this._threedUtils.download3DSource(
|
|
2443
|
+
return [4 /*yield*/, this._threedUtils.download3DSource(assetUrl, cdnUrl)
|
|
1898
2444
|
.catch(function (error) {
|
|
1899
2445
|
throw error;
|
|
1900
2446
|
})];
|
|
1901
|
-
case
|
|
2447
|
+
case 1:
|
|
1902
2448
|
_a._source = _b.sent();
|
|
1903
|
-
if (
|
|
2449
|
+
if (cdnUrl) {
|
|
1904
2450
|
this._variationHelper.assetPath =
|
|
1905
|
-
|
|
1906
|
-
(
|
|
1907
|
-
(
|
|
2451
|
+
cdnUrl +
|
|
2452
|
+
(cdnUrl.endsWith('/') ? '' : '/') +
|
|
2453
|
+
(schema ? schema : 'UP_DBA');
|
|
1908
2454
|
}
|
|
1909
|
-
|
|
1910
|
-
case 3: return [2 /*return*/];
|
|
2455
|
+
return [2 /*return*/];
|
|
1911
2456
|
}
|
|
1912
2457
|
});
|
|
1913
2458
|
});
|
|
1914
2459
|
};
|
|
1915
|
-
Builder.prototype._build = function (
|
|
2460
|
+
Builder.prototype._build = function () {
|
|
1916
2461
|
return __awaiter(this, void 0, void 0, function () {
|
|
1917
2462
|
var adjustables, obj, connected, i, len, adjustable, ii, lenii;
|
|
1918
2463
|
return __generator(this, function (_a) {
|
|
@@ -1921,7 +2466,7 @@
|
|
|
1921
2466
|
this._reset();
|
|
1922
2467
|
adjustables = this._getAdjustables();
|
|
1923
2468
|
if (!(adjustables && adjustables.length > 0)) return [3 /*break*/, 2];
|
|
1924
|
-
obj = new
|
|
2469
|
+
obj = new THREE__namespace.Object3D();
|
|
1925
2470
|
obj.visible = false; // no need to render visualy
|
|
1926
2471
|
this._scene.add(obj);
|
|
1927
2472
|
connected = false;
|
|
@@ -1944,10 +2489,12 @@
|
|
|
1944
2489
|
}
|
|
1945
2490
|
this._placeAddables(obj);
|
|
1946
2491
|
this._updatePivot(obj);
|
|
1947
|
-
return [4 /*yield*/, this._loadVariations(obj
|
|
2492
|
+
return [4 /*yield*/, this._loadVariations(obj)];
|
|
1948
2493
|
case 1:
|
|
1949
2494
|
_a.sent();
|
|
2495
|
+
// this._variationHelper.clearCache();
|
|
1950
2496
|
this._scene.remove(obj);
|
|
2497
|
+
ObjectUtils.DisposeObject(this._source);
|
|
1951
2498
|
return [2 /*return*/, obj];
|
|
1952
2499
|
case 2: throw 'No adjustables found!';
|
|
1953
2500
|
}
|
|
@@ -2048,8 +2595,8 @@
|
|
|
2048
2595
|
var obj = this._source ? this._source.getObjectByName(adj.decoNode.gameObjectName) : null;
|
|
2049
2596
|
if (!obj) {
|
|
2050
2597
|
// in case of glb files, the importer removes dots from names
|
|
2051
|
-
var
|
|
2052
|
-
obj = this._source ? this._source.getObjectByName(
|
|
2598
|
+
var name = adj.decoNode.gameObjectName.replace(/[.]/g, '');
|
|
2599
|
+
obj = this._source ? this._source.getObjectByName(name) : null;
|
|
2053
2600
|
if (!obj) {
|
|
2054
2601
|
// console.warn(`No object with name ${adj.decoNode.gameObjectName} found!`);
|
|
2055
2602
|
return null;
|
|
@@ -2139,6 +2686,7 @@
|
|
|
2139
2686
|
switch (_a.label) {
|
|
2140
2687
|
case 0:
|
|
2141
2688
|
if (this._articleCache.has(sku)) {
|
|
2689
|
+
this.articleLoaded.next(this._articleCache.get(sku));
|
|
2142
2690
|
return [2 /*return*/, this._articleCache.get(sku)];
|
|
2143
2691
|
}
|
|
2144
2692
|
if (!!goodId) return [3 /*break*/, 2];
|
|
@@ -2162,6 +2710,7 @@
|
|
|
2162
2710
|
}
|
|
2163
2711
|
}
|
|
2164
2712
|
this._articleCache.set(sku, article$1);
|
|
2713
|
+
this.articleLoaded.next(article$1);
|
|
2165
2714
|
return [2 /*return*/, article$1];
|
|
2166
2715
|
}
|
|
2167
2716
|
});
|
|
@@ -2203,6 +2752,7 @@
|
|
|
2203
2752
|
decosResponse = _a.sent();
|
|
2204
2753
|
if (decosResponse.resultObjects && decosResponse.resultObjects.length > 0) {
|
|
2205
2754
|
this._decos = this._boFactory.makeBOArrayFromRawBackendDataArray(decoNode.DecoNode, decosResponse.resultObjects);
|
|
2755
|
+
this.decosReceived.next(this._decos);
|
|
2206
2756
|
}
|
|
2207
2757
|
else {
|
|
2208
2758
|
throw 'No deconodes found!';
|
|
@@ -2240,19 +2790,20 @@
|
|
|
2240
2790
|
return deco.type === decoNodeType_enum.DecoNodeType.Variation;
|
|
2241
2791
|
});
|
|
2242
2792
|
};
|
|
2243
|
-
Builder.prototype._loadVariations = function (obj
|
|
2793
|
+
Builder.prototype._loadVariations = function (obj) {
|
|
2244
2794
|
return __awaiter(this, void 0, void 0, function () {
|
|
2245
2795
|
return __generator(this, function (_a) {
|
|
2246
2796
|
switch (_a.label) {
|
|
2247
2797
|
case 0: return [4 /*yield*/, this._variationHelper.loadPart(obj, this._adjustables, true)];
|
|
2248
2798
|
case 1:
|
|
2249
2799
|
_a.sent();
|
|
2250
|
-
return [4 /*yield*/, this._variationHelper.loadVariation(
|
|
2800
|
+
return [4 /*yield*/, this._variationHelper.loadVariation(obj, this._adjustables, true)];
|
|
2251
2801
|
case 2:
|
|
2252
2802
|
_a.sent();
|
|
2253
|
-
return [4 /*yield*/, this._variationHelper.loadVariation(
|
|
2803
|
+
return [4 /*yield*/, this._variationHelper.loadVariation(obj, this._addables, true)];
|
|
2254
2804
|
case 3:
|
|
2255
2805
|
_a.sent();
|
|
2806
|
+
this._variationHelper.clearCache();
|
|
2256
2807
|
return [2 /*return*/];
|
|
2257
2808
|
}
|
|
2258
2809
|
});
|
|
@@ -2265,10 +2816,10 @@
|
|
|
2265
2816
|
});
|
|
2266
2817
|
};
|
|
2267
2818
|
Builder.prototype._updatePivot = function (obj) {
|
|
2268
|
-
var boundingBox = new
|
|
2269
|
-
var bbCenterPivot = new
|
|
2819
|
+
var boundingBox = new THREE__namespace.Box3().setFromObject(obj);
|
|
2820
|
+
var bbCenterPivot = new THREE__namespace.Vector3();
|
|
2270
2821
|
boundingBox.getCenter(bbCenterPivot);
|
|
2271
|
-
var delta = new
|
|
2822
|
+
var delta = new THREE__namespace.Vector3().sub(bbCenterPivot).setY(Math.abs(Math.min(boundingBox.min.y, 0)));
|
|
2272
2823
|
obj.children.forEach(function (child) {
|
|
2273
2824
|
child.position.add(delta);
|
|
2274
2825
|
});
|
|
@@ -2281,106 +2832,40 @@
|
|
|
2281
2832
|
this._addables.length = 0;
|
|
2282
2833
|
this._prepareTheSelections();
|
|
2283
2834
|
};
|
|
2284
|
-
Builder.ctorParameters = function () { return [
|
|
2285
|
-
{ type: three.Scene },
|
|
2286
|
-
{ type: options.Options },
|
|
2287
|
-
{ type: Boolean }
|
|
2288
|
-
]; };
|
|
2289
|
-
Builder = __decorate([
|
|
2290
|
-
core.Injectable()
|
|
2291
|
-
], Builder);
|
|
2292
2835
|
return Builder;
|
|
2293
|
-
}());
|
|
2836
|
+
}());
|
|
2837
|
+
Builder.ɵprov = i0__namespace.ɵɵdefineInjectable({ factory: function Builder_Factory() { return new Builder(); }, token: Builder, providedIn: "root" });
|
|
2838
|
+
Builder.decorators = [
|
|
2839
|
+
{ type: i0.Injectable, args: [{
|
|
2840
|
+
providedIn: "root"
|
|
2841
|
+
},] }
|
|
2842
|
+
];
|
|
2843
|
+
Builder.ctorParameters = function () { return []; };
|
|
2294
2844
|
|
|
2295
2845
|
var AnswersComponent = /** @class */ (function () {
|
|
2296
2846
|
function AnswersComponent() {
|
|
2297
2847
|
this.answers = [];
|
|
2298
|
-
this.answerClick = new
|
|
2848
|
+
this.answerClick = new i0.EventEmitter();
|
|
2299
2849
|
}
|
|
2300
|
-
__decorate([
|
|
2301
|
-
core.Input()
|
|
2302
|
-
], AnswersComponent.prototype, "answers", void 0);
|
|
2303
|
-
__decorate([
|
|
2304
|
-
core.Input()
|
|
2305
|
-
], AnswersComponent.prototype, "selectionTitle", void 0);
|
|
2306
|
-
__decorate([
|
|
2307
|
-
core.Output()
|
|
2308
|
-
], AnswersComponent.prototype, "answerClick", void 0);
|
|
2309
|
-
AnswersComponent = __decorate([
|
|
2310
|
-
core.Component({
|
|
2311
|
-
selector: "answers",
|
|
2312
|
-
template: "\n <div class=\"ione-configurator\">\n <div class=\"rp-answers-slideout\">\n <h2 class=\"answers-title\" [textContent]=\"selectionTitle\"></h2>\n <div class=\"answers-container\" visibilityObserverMaster>\n <answer *ngFor=\"let answer of answers\"\n (click)=\"answerClick.emit(answer)\"\n [answer]=\"answer\"\n visibilityObserver\n #intersection=\"intersection\"\n [observerEnabled]=\"true\"\n [showing]=\"intersection.isIntersecting\"\n ></answer>\n </div>\n \n </div>\n </div>\n ",
|
|
2313
|
-
styles: [".ione-configurator .rp-answers-slideout{position:absolute;top:0;right:0;width:400px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}.ione-configurator .answers-title{margin-left:10px;color:#1a1a1a}.ione-configurator .answers-container{height:100vh;overflow-y:scroll}.ione-configurator .answer-content{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid #d3d3d3;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px rgba(211,211,211,.5);background:#fff}.ione-configurator .thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .img-size{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-wrapper{display:block}.ione-configurator .answer-title{font-size:12px;position:relative;overflow:hidden;cursor:pointer}.ione-configurator .question{font-weight:700;color:#1a1a1a}.ione-configurator .answer{font-size:12px;font-style:italic;margin-top:3px}.ione-configurator .collapse-content,.ione-configurator .collapse-wrapper{display:block}.ione-configurator .collapse-handle{position:absolute;top:10px;right:12px;border:solid #000;border-width:0 3px 3px 0;display:inline-block;padding:3px;transform:rotate(45deg);-webkit-transform:rotate(45deg)}.ione-configurator .collapse-handle.expanded{transform:rotate(-135deg);-webkit-transform:rotate(-135deg)}.ione-configurator .child-selection{margin-left:10px;display:flex;flex-direction:column;margin-top:5px}.ione-configurator .mat-title{margin-left:10px;color:#1a1a1a}.ione-configurator .drawer__header{height:48px}.ione-configurator .rp-selections-summary{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;background:0 0;overflow:auto;position:absolute;top:0;right:0;width:400px}.ione-configurator .selections-content{overflow-y:auto}.ione-configurator .co-summary-line{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid #d3d3d3;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px rgba(211,211,211,.5);background:#fff}.ione-configurator .selection-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .selection-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .answer-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .unloaded{background-color:#d3d3d3}.ione-configurator .titles{margin-left:14px;-ms-grid-row-align:center;align-self:center}.ione-configurator .title-wrapper{display:flex;flex-direction:column}.ione-configurator .answer-title-wrapper{text-align:center;-ms-grid-row-align:center;align-self:center;margin-left:14px}"]
|
|
2314
|
-
})
|
|
2315
|
-
], AnswersComponent);
|
|
2316
2850
|
return AnswersComponent;
|
|
2317
|
-
}());
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
|
|
2321
|
-
|
|
2322
|
-
|
|
2323
|
-
|
|
2324
|
-
|
|
2325
|
-
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2331
|
-
else {
|
|
2332
|
-
if (includeMimetype) {
|
|
2333
|
-
return ImageUtils.getDocBodyWithMimeTypeDefinition(responseData.resultObject.fileName, thumb ? responseData.resultObject.thumbnailBody : responseData.resultObject.documentBody);
|
|
2334
|
-
}
|
|
2335
|
-
else {
|
|
2336
|
-
return thumb ? responseData.resultObject.thumbnailBody : responseData.resultObject.documentBody;
|
|
2337
|
-
}
|
|
2338
|
-
}
|
|
2339
|
-
}
|
|
2340
|
-
else {
|
|
2341
|
-
return '';
|
|
2342
|
-
}
|
|
2343
|
-
};
|
|
2344
|
-
ImageCacheService.prototype.getImageForSelectionOrAnswer = function (object) {
|
|
2345
|
-
var _this = this;
|
|
2346
|
-
var includeMimeType = true, thumb = true;
|
|
2347
|
-
return new Promise(function (resolve, reject) {
|
|
2348
|
-
if (object && object.nodeId) {
|
|
2349
|
-
if (!_this._imageCache.has(object.nodeId)) {
|
|
2350
|
-
return _this._configuratorService.getSingleImage(object.nodeId, 4, includeMimeType, thumb, true)
|
|
2351
|
-
.then(function (responseData) {
|
|
2352
|
-
var base64 = ImageCacheService_1._handleResponseData(includeMimeType, thumb, responseData);
|
|
2353
|
-
_this._imageCache.set(object.nodeId, base64);
|
|
2354
|
-
resolve(base64);
|
|
2355
|
-
}).catch(function () {
|
|
2356
|
-
reject();
|
|
2357
|
-
});
|
|
2358
|
-
}
|
|
2359
|
-
else {
|
|
2360
|
-
resolve(_this._imageCache.get(object.nodeId));
|
|
2361
|
-
}
|
|
2362
|
-
}
|
|
2363
|
-
else {
|
|
2364
|
-
reject();
|
|
2365
|
-
}
|
|
2366
|
-
});
|
|
2367
|
-
};
|
|
2368
|
-
var ImageCacheService_1;
|
|
2369
|
-
ImageCacheService.ctorParameters = function () { return [
|
|
2370
|
-
{ type: ConfiguratorService }
|
|
2371
|
-
]; };
|
|
2372
|
-
ImageCacheService.ɵprov = core.ɵɵdefineInjectable({ factory: function ImageCacheService_Factory() { return new ImageCacheService(core.ɵɵinject(ConfiguratorService)); }, token: ImageCacheService, providedIn: "root" });
|
|
2373
|
-
ImageCacheService = ImageCacheService_1 = __decorate([
|
|
2374
|
-
core.Injectable({
|
|
2375
|
-
providedIn: 'root'
|
|
2376
|
-
})
|
|
2377
|
-
], ImageCacheService);
|
|
2378
|
-
return ImageCacheService;
|
|
2379
|
-
}());
|
|
2851
|
+
}());
|
|
2852
|
+
AnswersComponent.decorators = [
|
|
2853
|
+
{ type: i0.Component, args: [{
|
|
2854
|
+
selector: "answers",
|
|
2855
|
+
template: "\n <div class=\"ione-configurator\">\n <div class=\"rp-answers-slideout\">\n <h2 class=\"answers-title\" [textContent]=\"selectionTitle\"></h2>\n <div class=\"answers-container\" visibilityObserverMaster>\n <answer *ngFor=\"let answer of answers\"\n (click)=\"answerClick.emit(answer)\"\n [answer]=\"answer\"\n visibilityObserver\n #intersection=\"intersection\"\n [observerEnabled]=\"true\"\n [showing]=\"intersection.isIntersecting\"\n ></answer>\n </div>\n \n </div>\n </div>\n ",
|
|
2856
|
+
styles: [".ione-configurator .rp-answers-slideout{position:absolute;top:0;right:0;width:400px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}.ione-configurator .answers-title{margin-left:10px;color:#1a1a1a}.ione-configurator .answers-container{height:100vh;overflow-y:scroll}.ione-configurator .answer-content{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid lightgray;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px #d3d3d380;background:white}.ione-configurator .thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .img-size{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-wrapper{display:block}.ione-configurator .answer-title{font-size:12px;position:relative;overflow:hidden;cursor:pointer}.ione-configurator .question{font-weight:bold;color:#1a1a1a}.ione-configurator .answer{font-size:12px;font-style:italic;margin-top:3px}.ione-configurator .collapse-wrapper{display:block}.ione-configurator .collapse-content{display:block}.ione-configurator .collapse-handle{position:absolute;top:10px;right:12px;border:solid black;border-width:0 3px 3px 0;display:inline-block;padding:3px;transform:rotate(45deg);-webkit-transform:rotate(45deg)}.ione-configurator .collapse-handle.expanded{transform:rotate(-135deg);-webkit-transform:rotate(-135deg)}.ione-configurator .child-selection{margin-left:10px;display:flex;flex-direction:column;margin-top:5px}.ione-configurator .mat-title{margin-left:10px;color:#1a1a1a}.ione-configurator .drawer__header{height:48px}.ione-configurator .rp-selections-summary{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;background:transparent;overflow:auto;position:absolute;top:0;right:0;width:400px}.ione-configurator .selections-content{overflow-y:auto}.ione-configurator .co-summary-line{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid lightgray;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px #d3d3d380;background:white}.ione-configurator .selection-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .selection-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .answer-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .unloaded{background-color:#d3d3d3}.ione-configurator .titles{margin-left:14px;align-self:center}.ione-configurator .title-wrapper{display:flex;flex-direction:column}.ione-configurator .answer-title-wrapper{text-align:center;align-self:center;margin-left:14px}\n"]
|
|
2857
|
+
},] }
|
|
2858
|
+
];
|
|
2859
|
+
AnswersComponent.ctorParameters = function () { return []; };
|
|
2860
|
+
AnswersComponent.propDecorators = {
|
|
2861
|
+
answers: [{ type: i0.Input }],
|
|
2862
|
+
selectionTitle: [{ type: i0.Input }],
|
|
2863
|
+
answerClick: [{ type: i0.Output }]
|
|
2864
|
+
};
|
|
2380
2865
|
|
|
2381
2866
|
var AnswerComponent = /** @class */ (function () {
|
|
2382
|
-
function AnswerComponent(
|
|
2383
|
-
this.
|
|
2867
|
+
function AnswerComponent(_builder) {
|
|
2868
|
+
this._builder = _builder;
|
|
2384
2869
|
}
|
|
2385
2870
|
Object.defineProperty(AnswerComponent.prototype, "showing", {
|
|
2386
2871
|
set: function (value) {
|
|
@@ -2392,7 +2877,7 @@
|
|
|
2392
2877
|
this.answer.imageData = null;
|
|
2393
2878
|
}
|
|
2394
2879
|
},
|
|
2395
|
-
enumerable:
|
|
2880
|
+
enumerable: false,
|
|
2396
2881
|
configurable: true
|
|
2397
2882
|
});
|
|
2398
2883
|
AnswerComponent.prototype.ngOnInit = function () {
|
|
@@ -2401,7 +2886,7 @@
|
|
|
2401
2886
|
return __awaiter(this, void 0, void 0, function () {
|
|
2402
2887
|
return __generator(this, function (_a) {
|
|
2403
2888
|
switch (_a.label) {
|
|
2404
|
-
case 0: return [4 /*yield*/, this.
|
|
2889
|
+
case 0: return [4 /*yield*/, this._builder.getImageForSelectionOrAnswer(answer).then(function (imageSrc) {
|
|
2405
2890
|
answer.imageData = imageSrc === "" ? null : imageSrc;
|
|
2406
2891
|
})];
|
|
2407
2892
|
case 1:
|
|
@@ -2411,31 +2896,29 @@
|
|
|
2411
2896
|
});
|
|
2412
2897
|
});
|
|
2413
2898
|
};
|
|
2414
|
-
AnswerComponent.ctorParameters = function () { return [
|
|
2415
|
-
{ type: ImageCacheService }
|
|
2416
|
-
]; };
|
|
2417
|
-
__decorate([
|
|
2418
|
-
core.Input()
|
|
2419
|
-
], AnswerComponent.prototype, "answer", void 0);
|
|
2420
|
-
__decorate([
|
|
2421
|
-
core.Input()
|
|
2422
|
-
], AnswerComponent.prototype, "showing", null);
|
|
2423
|
-
AnswerComponent = __decorate([
|
|
2424
|
-
core.Component({
|
|
2425
|
-
selector: 'answer',
|
|
2426
|
-
template: "\n <div class=\"ione-configurator\">\n <div class=\"answer-wrapper\">\n <div class=\"answer-content\" @answerAppear>\n <div class=\"answer-thumbnail\">\n <rp-loader *ngIf=\"answer.imageData === ''\"></rp-loader>\n <img *ngIf=\"answer.imageData !== '' && answer.imageData !== null\" class=\"answer-img\" [src]=\"answer.imageData\">\n </div>\n <div class=\"answer-title-wrapper\">\n <span class=\"answer-title\" [textContent]=\"answer.commercialAnswer\"></span>\n </div>\n <div class=\"price\">\n <span class=\"price-value\"></span>\n </div>\n </div>\n </div>\n </div>\n ",
|
|
2427
|
-
animations: [
|
|
2428
|
-
animations.trigger('answerAppear', [
|
|
2429
|
-
animations.state('void', animations.style({ 'background': '#dbdbdb' })),
|
|
2430
|
-
animations.state('white', animations.style({ 'background': 'white' })),
|
|
2431
|
-
animations.transition('void <=> *', animations.animate(500))
|
|
2432
|
-
])
|
|
2433
|
-
],
|
|
2434
|
-
styles: [".ione-configurator .rp-answers-slideout{position:absolute;top:0;right:0;width:400px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}.ione-configurator .answers-title{margin-left:10px;color:#1a1a1a}.ione-configurator .answers-container{height:100vh;overflow-y:scroll}.ione-configurator .answer-content{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid #d3d3d3;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px rgba(211,211,211,.5);background:#fff}.ione-configurator .thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .img-size{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-wrapper{display:block}.ione-configurator .answer-title{font-size:12px;position:relative;overflow:hidden;cursor:pointer}.ione-configurator .question{font-weight:700;color:#1a1a1a}.ione-configurator .answer{font-size:12px;font-style:italic;margin-top:3px}.ione-configurator .collapse-content,.ione-configurator .collapse-wrapper{display:block}.ione-configurator .collapse-handle{position:absolute;top:10px;right:12px;border:solid #000;border-width:0 3px 3px 0;display:inline-block;padding:3px;transform:rotate(45deg);-webkit-transform:rotate(45deg)}.ione-configurator .collapse-handle.expanded{transform:rotate(-135deg);-webkit-transform:rotate(-135deg)}.ione-configurator .child-selection{margin-left:10px;display:flex;flex-direction:column;margin-top:5px}.ione-configurator .mat-title{margin-left:10px;color:#1a1a1a}.ione-configurator .drawer__header{height:48px}.ione-configurator .rp-selections-summary{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;background:0 0;overflow:auto;position:absolute;top:0;right:0;width:400px}.ione-configurator .selections-content{overflow-y:auto}.ione-configurator .co-summary-line{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid #d3d3d3;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px rgba(211,211,211,.5);background:#fff}.ione-configurator .selection-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .selection-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .answer-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .unloaded{background-color:#d3d3d3}.ione-configurator .titles{margin-left:14px;-ms-grid-row-align:center;align-self:center}.ione-configurator .title-wrapper{display:flex;flex-direction:column}.ione-configurator .answer-title-wrapper{text-align:center;-ms-grid-row-align:center;align-self:center;margin-left:14px}"]
|
|
2435
|
-
})
|
|
2436
|
-
], AnswerComponent);
|
|
2437
2899
|
return AnswerComponent;
|
|
2438
|
-
}());
|
|
2900
|
+
}());
|
|
2901
|
+
AnswerComponent.decorators = [
|
|
2902
|
+
{ type: i0.Component, args: [{
|
|
2903
|
+
selector: 'answer',
|
|
2904
|
+
template: "\n <div class=\"ione-configurator\">\n <div class=\"answer-wrapper\">\n <div class=\"answer-content\" @answerAppear>\n <div class=\"answer-thumbnail\">\n <rp-loader *ngIf=\"answer.imageData === ''\"></rp-loader>\n <img *ngIf=\"answer.imageData !== '' && answer.imageData !== null\" class=\"answer-img\" [src]=\"answer.imageData\">\n </div>\n <div class=\"answer-title-wrapper\">\n <span class=\"answer-title\" [textContent]=\"answer.commercialAnswer\"></span>\n </div>\n <div class=\"price\">\n <span class=\"price-value\"></span>\n </div>\n </div>\n </div>\n </div>\n ",
|
|
2905
|
+
animations: [
|
|
2906
|
+
animations.trigger('answerAppear', [
|
|
2907
|
+
animations.state('void', animations.style({ 'background': '#dbdbdb' })),
|
|
2908
|
+
animations.state('white', animations.style({ 'background': 'white' })),
|
|
2909
|
+
animations.transition('void <=> *', animations.animate(500))
|
|
2910
|
+
])
|
|
2911
|
+
],
|
|
2912
|
+
styles: [".ione-configurator .rp-answers-slideout{position:absolute;top:0;right:0;width:400px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}.ione-configurator .answers-title{margin-left:10px;color:#1a1a1a}.ione-configurator .answers-container{height:100vh;overflow-y:scroll}.ione-configurator .answer-content{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid lightgray;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px #d3d3d380;background:white}.ione-configurator .thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .img-size{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-wrapper{display:block}.ione-configurator .answer-title{font-size:12px;position:relative;overflow:hidden;cursor:pointer}.ione-configurator .question{font-weight:bold;color:#1a1a1a}.ione-configurator .answer{font-size:12px;font-style:italic;margin-top:3px}.ione-configurator .collapse-wrapper{display:block}.ione-configurator .collapse-content{display:block}.ione-configurator .collapse-handle{position:absolute;top:10px;right:12px;border:solid black;border-width:0 3px 3px 0;display:inline-block;padding:3px;transform:rotate(45deg);-webkit-transform:rotate(45deg)}.ione-configurator .collapse-handle.expanded{transform:rotate(-135deg);-webkit-transform:rotate(-135deg)}.ione-configurator .child-selection{margin-left:10px;display:flex;flex-direction:column;margin-top:5px}.ione-configurator .mat-title{margin-left:10px;color:#1a1a1a}.ione-configurator .drawer__header{height:48px}.ione-configurator .rp-selections-summary{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;background:transparent;overflow:auto;position:absolute;top:0;right:0;width:400px}.ione-configurator .selections-content{overflow-y:auto}.ione-configurator .co-summary-line{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid lightgray;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px #d3d3d380;background:white}.ione-configurator .selection-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .selection-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .answer-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .unloaded{background-color:#d3d3d3}.ione-configurator .titles{margin-left:14px;align-self:center}.ione-configurator .title-wrapper{display:flex;flex-direction:column}.ione-configurator .answer-title-wrapper{text-align:center;align-self:center;margin-left:14px}\n"]
|
|
2913
|
+
},] }
|
|
2914
|
+
];
|
|
2915
|
+
AnswerComponent.ctorParameters = function () { return [
|
|
2916
|
+
{ type: Builder }
|
|
2917
|
+
]; };
|
|
2918
|
+
AnswerComponent.propDecorators = {
|
|
2919
|
+
answer: [{ type: i0.Input }],
|
|
2920
|
+
showing: [{ type: i0.Input }]
|
|
2921
|
+
};
|
|
2439
2922
|
|
|
2440
2923
|
var VisibilityObserverMasterDirective = /** @class */ (function () {
|
|
2441
2924
|
// I initialize the intersection observer parent directive.
|
|
@@ -2489,13 +2972,14 @@
|
|
|
2489
2972
|
this._mapping.delete(element);
|
|
2490
2973
|
this._observer.unobserve(element);
|
|
2491
2974
|
};
|
|
2492
|
-
VisibilityObserverMasterDirective = __decorate([
|
|
2493
|
-
core.Directive({
|
|
2494
|
-
selector: '[visibilityObserverMaster]'
|
|
2495
|
-
})
|
|
2496
|
-
], VisibilityObserverMasterDirective);
|
|
2497
2975
|
return VisibilityObserverMasterDirective;
|
|
2498
|
-
}());
|
|
2976
|
+
}());
|
|
2977
|
+
VisibilityObserverMasterDirective.decorators = [
|
|
2978
|
+
{ type: i0.Directive, args: [{
|
|
2979
|
+
selector: '[visibilityObserverMaster]'
|
|
2980
|
+
},] }
|
|
2981
|
+
];
|
|
2982
|
+
VisibilityObserverMasterDirective.ctorParameters = function () { return []; };
|
|
2499
2983
|
|
|
2500
2984
|
var VisibilityObserverDirective = /** @class */ (function () {
|
|
2501
2985
|
// I initialize the intersection observer directive.
|
|
@@ -2536,76 +3020,76 @@
|
|
|
2536
3020
|
});
|
|
2537
3021
|
}
|
|
2538
3022
|
};
|
|
2539
|
-
VisibilityObserverDirective.ctorParameters = function () { return [
|
|
2540
|
-
{ type: VisibilityObserverMasterDirective },
|
|
2541
|
-
{ type: core.ElementRef }
|
|
2542
|
-
]; };
|
|
2543
|
-
__decorate([
|
|
2544
|
-
core.Input()
|
|
2545
|
-
], VisibilityObserverDirective.prototype, "observerEnabled", void 0);
|
|
2546
|
-
VisibilityObserverDirective = __decorate([
|
|
2547
|
-
core.Directive({
|
|
2548
|
-
selector: '[visibilityObserver]',
|
|
2549
|
-
exportAs: 'intersection'
|
|
2550
|
-
})
|
|
2551
|
-
], VisibilityObserverDirective);
|
|
2552
3023
|
return VisibilityObserverDirective;
|
|
2553
|
-
}());
|
|
3024
|
+
}());
|
|
3025
|
+
VisibilityObserverDirective.decorators = [
|
|
3026
|
+
{ type: i0.Directive, args: [{
|
|
3027
|
+
selector: '[visibilityObserver]',
|
|
3028
|
+
exportAs: 'intersection'
|
|
3029
|
+
},] }
|
|
3030
|
+
];
|
|
3031
|
+
VisibilityObserverDirective.ctorParameters = function () { return [
|
|
3032
|
+
{ type: VisibilityObserverMasterDirective },
|
|
3033
|
+
{ type: i0.ElementRef }
|
|
3034
|
+
]; };
|
|
3035
|
+
VisibilityObserverDirective.propDecorators = {
|
|
3036
|
+
observerEnabled: [{ type: i0.Input }]
|
|
3037
|
+
};
|
|
2554
3038
|
|
|
2555
3039
|
var LoaderComponent = /** @class */ (function () {
|
|
2556
3040
|
function LoaderComponent() {
|
|
2557
3041
|
}
|
|
2558
|
-
LoaderComponent = __decorate([
|
|
2559
|
-
core.Component({
|
|
2560
|
-
selector: 'rp-loader',
|
|
2561
|
-
template: "\n <div class=\"loader-wrapper\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"44\" height=\"44\" viewBox=\"0 0 44 44\" stroke=\"#3760a1\">\n <g fill=\"none\" fill-rule=\"evenodd\" stroke-width=\"3\">\n <circle class=\"ripple1\" cx=\"22\" cy=\"22\" r=\"19\">\n </circle>\n <circle class=\"ripple2\" cx=\"22\" cy=\"22\" r=\"19\">\n </circle>\n </g>\n </svg>\n </div>\n ",
|
|
2562
|
-
styles: [":host{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none}:host .loader-wrapper{z-index:1100;position:absolute;width:54px;height:54px}:host .loader-wrapper svg{width:100%;height:100%}:host .loader-wrapper svg .ripple1{transform-origin:center;-webkit-animation:1.5s infinite ripple;animation:1.5s infinite ripple}:host .loader-wrapper svg .ripple2{transform-origin:center;-webkit-animation:1.5s .4s infinite ripple;animation:1.5s .4s infinite ripple}@-webkit-keyframes ripple{0%{transform:scale(0);opacity:1}100%{transform:scale(1);opacity:0}}@keyframes ripple{0%{transform:scale(0);opacity:1}100%{transform:scale(1);opacity:0}}"]
|
|
2563
|
-
})
|
|
2564
|
-
], LoaderComponent);
|
|
2565
3042
|
return LoaderComponent;
|
|
2566
|
-
}());
|
|
3043
|
+
}());
|
|
3044
|
+
LoaderComponent.decorators = [
|
|
3045
|
+
{ type: i0.Component, args: [{
|
|
3046
|
+
selector: 'rp-loader',
|
|
3047
|
+
template: "\n <div class=\"loader-wrapper\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"44\" height=\"44\" viewBox=\"0 0 44 44\" stroke=\"#3760a1\">\n <g fill=\"none\" fill-rule=\"evenodd\" stroke-width=\"3\">\n <circle class=\"ripple1\" cx=\"22\" cy=\"22\" r=\"19\">\n </circle>\n <circle class=\"ripple2\" cx=\"22\" cy=\"22\" r=\"19\">\n </circle>\n </g>\n </svg>\n </div>\n ",
|
|
3048
|
+
styles: [":host{-webkit-user-select:none;user-select:none;pointer-events:none}:host .loader-wrapper{z-index:1100;position:absolute;width:54px;height:54px}:host .loader-wrapper svg{width:100%;height:100%}:host .loader-wrapper svg .ripple1{transform-origin:center;animation:ripple 1.5s infinite}:host .loader-wrapper svg .ripple2{transform-origin:center;animation:ripple 1.5s infinite .4s}@keyframes ripple{0%{transform:scale(0);opacity:1}to{transform:scale(1);opacity:0}}\n"]
|
|
3049
|
+
},] }
|
|
3050
|
+
];
|
|
2567
3051
|
|
|
2568
3052
|
var SharedModule = /** @class */ (function () {
|
|
2569
3053
|
function SharedModule() {
|
|
2570
3054
|
}
|
|
2571
|
-
SharedModule = __decorate([
|
|
2572
|
-
core.NgModule({
|
|
2573
|
-
imports: [
|
|
2574
|
-
common.CommonModule
|
|
2575
|
-
],
|
|
2576
|
-
declarations: [
|
|
2577
|
-
LoaderComponent
|
|
2578
|
-
],
|
|
2579
|
-
exports: [
|
|
2580
|
-
LoaderComponent
|
|
2581
|
-
]
|
|
2582
|
-
})
|
|
2583
|
-
], SharedModule);
|
|
2584
3055
|
return SharedModule;
|
|
2585
|
-
}());
|
|
3056
|
+
}());
|
|
3057
|
+
SharedModule.decorators = [
|
|
3058
|
+
{ type: i0.NgModule, args: [{
|
|
3059
|
+
imports: [
|
|
3060
|
+
common.CommonModule
|
|
3061
|
+
],
|
|
3062
|
+
declarations: [
|
|
3063
|
+
LoaderComponent
|
|
3064
|
+
],
|
|
3065
|
+
exports: [
|
|
3066
|
+
LoaderComponent
|
|
3067
|
+
]
|
|
3068
|
+
},] }
|
|
3069
|
+
];
|
|
2586
3070
|
|
|
2587
3071
|
var AnswersModule = /** @class */ (function () {
|
|
2588
3072
|
function AnswersModule() {
|
|
2589
3073
|
}
|
|
2590
|
-
AnswersModule = __decorate([
|
|
2591
|
-
core.NgModule({
|
|
2592
|
-
imports: [
|
|
2593
|
-
common.CommonModule,
|
|
2594
|
-
SharedModule
|
|
2595
|
-
],
|
|
2596
|
-
declarations: [
|
|
2597
|
-
AnswersComponent,
|
|
2598
|
-
AnswerComponent,
|
|
2599
|
-
VisibilityObserverDirective,
|
|
2600
|
-
VisibilityObserverMasterDirective
|
|
2601
|
-
],
|
|
2602
|
-
exports: [
|
|
2603
|
-
AnswersComponent
|
|
2604
|
-
]
|
|
2605
|
-
})
|
|
2606
|
-
], AnswersModule);
|
|
2607
3074
|
return AnswersModule;
|
|
2608
|
-
}());
|
|
3075
|
+
}());
|
|
3076
|
+
AnswersModule.decorators = [
|
|
3077
|
+
{ type: i0.NgModule, args: [{
|
|
3078
|
+
imports: [
|
|
3079
|
+
common.CommonModule,
|
|
3080
|
+
SharedModule
|
|
3081
|
+
],
|
|
3082
|
+
declarations: [
|
|
3083
|
+
AnswersComponent,
|
|
3084
|
+
AnswerComponent,
|
|
3085
|
+
VisibilityObserverDirective,
|
|
3086
|
+
VisibilityObserverMasterDirective
|
|
3087
|
+
],
|
|
3088
|
+
exports: [
|
|
3089
|
+
AnswersComponent
|
|
3090
|
+
]
|
|
3091
|
+
},] }
|
|
3092
|
+
];
|
|
2609
3093
|
|
|
2610
3094
|
var SelectionViewModel = /** @class */ (function () {
|
|
2611
3095
|
function SelectionViewModel() {
|
|
@@ -2616,21 +3100,19 @@
|
|
|
2616
3100
|
return SelectionViewModel;
|
|
2617
3101
|
}());
|
|
2618
3102
|
var SelectionsComponent = /** @class */ (function () {
|
|
2619
|
-
function SelectionsComponent(
|
|
2620
|
-
this.
|
|
3103
|
+
function SelectionsComponent(_builder) {
|
|
3104
|
+
this._builder = _builder;
|
|
2621
3105
|
this.selectionViewModels = [];
|
|
2622
|
-
this.selectionClick = new
|
|
3106
|
+
this.selectionClick = new i0.EventEmitter();
|
|
2623
3107
|
}
|
|
2624
3108
|
Object.defineProperty(SelectionsComponent.prototype, "selections", {
|
|
2625
3109
|
set: function (value) {
|
|
2626
3110
|
this._prepareSelections(value);
|
|
2627
3111
|
this._loadThumbnails();
|
|
2628
3112
|
},
|
|
2629
|
-
enumerable:
|
|
3113
|
+
enumerable: false,
|
|
2630
3114
|
configurable: true
|
|
2631
3115
|
});
|
|
2632
|
-
SelectionsComponent.prototype.ngOnInit = function () {
|
|
2633
|
-
};
|
|
2634
3116
|
SelectionsComponent.prototype.expandClicked = function (selectionViewModel, mouseEvent) {
|
|
2635
3117
|
mouseEvent.preventDefault();
|
|
2636
3118
|
mouseEvent.stopImmediatePropagation();
|
|
@@ -2649,7 +3131,7 @@
|
|
|
2649
3131
|
this.selectionViewModels.forEach(function (viewModel) { return __awaiter(_this, void 0, void 0, function () {
|
|
2650
3132
|
return __generator(this, function (_a) {
|
|
2651
3133
|
switch (_a.label) {
|
|
2652
|
-
case 0: return [4 /*yield*/, this.
|
|
3134
|
+
case 0: return [4 /*yield*/, this._builder.getImageForSelectionOrAnswer(viewModel.selection).then(function (imageSrc) {
|
|
2653
3135
|
viewModel.thumbnail = imageSrc === "" ? null : imageSrc;
|
|
2654
3136
|
})];
|
|
2655
3137
|
case 1:
|
|
@@ -2680,51 +3162,53 @@
|
|
|
2680
3162
|
}
|
|
2681
3163
|
});
|
|
2682
3164
|
};
|
|
2683
|
-
SelectionsComponent.ctorParameters = function () { return [
|
|
2684
|
-
{ type: ImageCacheService }
|
|
2685
|
-
]; };
|
|
2686
|
-
__decorate([
|
|
2687
|
-
core.Input()
|
|
2688
|
-
], SelectionsComponent.prototype, "selections", null);
|
|
2689
|
-
__decorate([
|
|
2690
|
-
core.Output()
|
|
2691
|
-
], SelectionsComponent.prototype, "selectionClick", void 0);
|
|
2692
|
-
SelectionsComponent = __decorate([
|
|
2693
|
-
core.Component({
|
|
2694
|
-
selector: "selections",
|
|
2695
|
-
template: "\n <div class=\"ione-configurator\">\n <div class=\"rp-selections-summary\">\n <header class=\"drawer__header\">\n <h2 class=\"mat-title\" [textContent]=\"'Configuratie'\"></h2>\n <!--<button>-->\n <!---->\n <!--</button>-->\n </header>\n <div class=\"selections-content\">\n <ng-container *ngFor=\"let selectionViewModel of selectionViewModels\">\n\n <div class=\"co-summary-line\" (click)=\"selectSelection(selectionViewModel.selection, $event)\">\n <div class=\"selection-thumbnail\">\n <rp-loader *ngIf=\"selectionViewModel.thumbnail === ''\"></rp-loader>\n <img visibilityObserver *ngIf=\"selectionViewModel.thumbnail !== '' && selectionViewModel.thumbnail !== null\" class=\"selection-img\" [src]=\"selectionViewModel.thumbnail\">\n </div>\n <div class=\"titles\">\n <div class=\"title-wrapper\">\n <label class=\"question\" [textContent]=\"selectionViewModel.selection.question\"></label>\n <span class=\"answer\" [textContent]=\"selectionViewModel.selection.answer\"></span>\n <div *ngIf=\"selectionViewModel.children.length > 0 && selectionViewModel.expanded\" @showHideChildren>\n <div class=\"child-selection\" *ngFor=\"let selection of selectionViewModel.children\"\n (click)=\"selectSelection(selection, $event)\"\n >\n <label class=\"question\" [textContent]=\"selection.commercialQuestion\"></label>\n <span class=\"answer\" [textContent]=\"selection.answer\"></span>\n </div>\n </div>\n </div>\n </div>\n \n <div class=\"price-wrapper\">\n <span class=\"price-value\"></span>\n </div>\n\n <div class=\"collapse-wrapper\">\n <div class=\"collapse-content\">\n <div class=\"collapse-handle\" [class.expanded]=\"selectionViewModel.expanded\"\n *ngIf=\"selectionViewModel.children.length > 0\" (click)=\"expandClicked(selectionViewModel, $event)\"></div>\n </div>\n </div>\n </div>\n\n </ng-container>\n </div>\n </div>\n </div>\n ",
|
|
2696
|
-
animations: [
|
|
2697
|
-
animations.trigger('showHideChildren', [
|
|
2698
|
-
animations.state('void', animations.style({ 'height': '0' })),
|
|
2699
|
-
animations.state('*', animations.style({ 'height': '*' })),
|
|
2700
|
-
animations.transition('void <=> *', animations.animate(200))
|
|
2701
|
-
])
|
|
2702
|
-
],
|
|
2703
|
-
styles: [".ione-configurator .rp-answers-slideout{position:absolute;top:0;right:0;width:400px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}.ione-configurator .answers-title{margin-left:10px;color:#1a1a1a}.ione-configurator .answers-container{height:100vh;overflow-y:scroll}.ione-configurator .answer-content{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid #d3d3d3;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px rgba(211,211,211,.5);background:#fff}.ione-configurator .thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .img-size{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-wrapper{display:block}.ione-configurator .answer-title{font-size:12px;position:relative;overflow:hidden;cursor:pointer}.ione-configurator .question{font-weight:700;color:#1a1a1a}.ione-configurator .answer{font-size:12px;font-style:italic;margin-top:3px}.ione-configurator .collapse-content,.ione-configurator .collapse-wrapper{display:block}.ione-configurator .collapse-handle{position:absolute;top:10px;right:12px;border:solid #000;border-width:0 3px 3px 0;display:inline-block;padding:3px;transform:rotate(45deg);-webkit-transform:rotate(45deg)}.ione-configurator .collapse-handle.expanded{transform:rotate(-135deg);-webkit-transform:rotate(-135deg)}.ione-configurator .child-selection{margin-left:10px;display:flex;flex-direction:column;margin-top:5px}.ione-configurator .mat-title{margin-left:10px;color:#1a1a1a}.ione-configurator .drawer__header{height:48px}.ione-configurator .rp-selections-summary{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;background:0 0;overflow:auto;position:absolute;top:0;right:0;width:400px}.ione-configurator .selections-content{overflow-y:auto}.ione-configurator .co-summary-line{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid #d3d3d3;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px rgba(211,211,211,.5);background:#fff}.ione-configurator .selection-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .selection-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .answer-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .unloaded{background-color:#d3d3d3}.ione-configurator .titles{margin-left:14px;-ms-grid-row-align:center;align-self:center}.ione-configurator .title-wrapper{display:flex;flex-direction:column}.ione-configurator .answer-title-wrapper{text-align:center;-ms-grid-row-align:center;align-self:center;margin-left:14px}"]
|
|
2704
|
-
})
|
|
2705
|
-
], SelectionsComponent);
|
|
2706
3165
|
return SelectionsComponent;
|
|
2707
|
-
}());
|
|
3166
|
+
}());
|
|
3167
|
+
SelectionsComponent.decorators = [
|
|
3168
|
+
{ type: i0.Component, args: [{
|
|
3169
|
+
selector: "selections",
|
|
3170
|
+
template: "\n <div class=\"ione-configurator\">\n <div class=\"rp-selections-summary\">\n <header class=\"drawer__header\">\n <h2 class=\"mat-title\" [textContent]=\"'Configuratie'\"></h2>\n <!--<button>-->\n <!---->\n <!--</button>-->\n </header>\n <div class=\"selections-content\">\n <ng-container *ngFor=\"let selectionViewModel of selectionViewModels\">\n\n <div class=\"co-summary-line\" (click)=\"selectSelection(selectionViewModel.selection, $event)\">\n <div class=\"selection-thumbnail\">\n <rp-loader *ngIf=\"selectionViewModel.thumbnail === ''\"></rp-loader>\n <img visibilityObserver *ngIf=\"selectionViewModel.thumbnail !== '' && selectionViewModel.thumbnail !== null\" class=\"selection-img\" [src]=\"selectionViewModel.thumbnail\">\n </div>\n <div class=\"titles\">\n <div class=\"title-wrapper\">\n <label class=\"question\" [textContent]=\"selectionViewModel.selection.question\"></label>\n <span class=\"answer\" [textContent]=\"selectionViewModel.selection.answer\"></span>\n <div *ngIf=\"selectionViewModel.children.length > 0 && selectionViewModel.expanded\" @showHideChildren>\n <div class=\"child-selection\" *ngFor=\"let selection of selectionViewModel.children\"\n (click)=\"selectSelection(selection, $event)\"\n >\n <label class=\"question\" [textContent]=\"selection.commercialQuestion\"></label>\n <span class=\"answer\" [textContent]=\"selection.answer\"></span>\n </div>\n </div>\n </div>\n </div>\n \n <div class=\"price-wrapper\">\n <span class=\"price-value\"></span>\n </div>\n\n <div class=\"collapse-wrapper\">\n <div class=\"collapse-content\">\n <div class=\"collapse-handle\" [class.expanded]=\"selectionViewModel.expanded\"\n *ngIf=\"selectionViewModel.children.length > 0\" (click)=\"expandClicked(selectionViewModel, $event)\"></div>\n </div>\n </div>\n </div>\n\n </ng-container>\n </div>\n </div>\n </div>\n ",
|
|
3171
|
+
animations: [
|
|
3172
|
+
animations.trigger('showHideChildren', [
|
|
3173
|
+
animations.state('void', animations.style({ 'height': '0' })),
|
|
3174
|
+
animations.state('*', animations.style({ 'height': '*' })),
|
|
3175
|
+
animations.transition('void <=> *', animations.animate(200))
|
|
3176
|
+
])
|
|
3177
|
+
],
|
|
3178
|
+
styles: [".ione-configurator .rp-answers-slideout{position:absolute;top:0;right:0;width:400px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}.ione-configurator .answers-title{margin-left:10px;color:#1a1a1a}.ione-configurator .answers-container{height:100vh;overflow-y:scroll}.ione-configurator .answer-content{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid lightgray;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px #d3d3d380;background:white}.ione-configurator .thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .img-size{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-wrapper{display:block}.ione-configurator .answer-title{font-size:12px;position:relative;overflow:hidden;cursor:pointer}.ione-configurator .question{font-weight:bold;color:#1a1a1a}.ione-configurator .answer{font-size:12px;font-style:italic;margin-top:3px}.ione-configurator .collapse-wrapper{display:block}.ione-configurator .collapse-content{display:block}.ione-configurator .collapse-handle{position:absolute;top:10px;right:12px;border:solid black;border-width:0 3px 3px 0;display:inline-block;padding:3px;transform:rotate(45deg);-webkit-transform:rotate(45deg)}.ione-configurator .collapse-handle.expanded{transform:rotate(-135deg);-webkit-transform:rotate(-135deg)}.ione-configurator .child-selection{margin-left:10px;display:flex;flex-direction:column;margin-top:5px}.ione-configurator .mat-title{margin-left:10px;color:#1a1a1a}.ione-configurator .drawer__header{height:48px}.ione-configurator .rp-selections-summary{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;background:transparent;overflow:auto;position:absolute;top:0;right:0;width:400px}.ione-configurator .selections-content{overflow-y:auto}.ione-configurator .co-summary-line{position:relative;overflow:hidden;cursor:pointer;font-size:12px;border:1px solid lightgray;padding:10px;display:flex;flex-direction:row;border-radius:3px;margin-bottom:3px;box-shadow:2px 1px #d3d3d380;background:white}.ione-configurator .selection-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .selection-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .answer-thumbnail{width:54px;min-width:54px;height:54px;min-height:54px;border:1px solid #d3d3d3;border-radius:5px}.ione-configurator .answer-img{width:54px;min-width:54px;height:54px;min-height:54px;border-radius:5px}.ione-configurator .unloaded{background-color:#d3d3d3}.ione-configurator .titles{margin-left:14px;align-self:center}.ione-configurator .title-wrapper{display:flex;flex-direction:column}.ione-configurator .answer-title-wrapper{text-align:center;align-self:center;margin-left:14px}\n"]
|
|
3179
|
+
},] }
|
|
3180
|
+
];
|
|
3181
|
+
SelectionsComponent.ctorParameters = function () { return [
|
|
3182
|
+
{ type: Builder }
|
|
3183
|
+
]; };
|
|
3184
|
+
SelectionsComponent.propDecorators = {
|
|
3185
|
+
selections: [{ type: i0.Input }],
|
|
3186
|
+
selectionClick: [{ type: i0.Output }]
|
|
3187
|
+
};
|
|
2708
3188
|
|
|
2709
3189
|
var SelectionsModule = /** @class */ (function () {
|
|
2710
3190
|
function SelectionsModule() {
|
|
2711
3191
|
}
|
|
2712
|
-
SelectionsModule = __decorate([
|
|
2713
|
-
core.NgModule({
|
|
2714
|
-
imports: [
|
|
2715
|
-
common.CommonModule,
|
|
2716
|
-
SharedModule
|
|
2717
|
-
],
|
|
2718
|
-
declarations: [
|
|
2719
|
-
SelectionsComponent
|
|
2720
|
-
],
|
|
2721
|
-
exports: [
|
|
2722
|
-
SelectionsComponent
|
|
2723
|
-
]
|
|
2724
|
-
})
|
|
2725
|
-
], SelectionsModule);
|
|
2726
3192
|
return SelectionsModule;
|
|
2727
|
-
}());
|
|
3193
|
+
}());
|
|
3194
|
+
SelectionsModule.decorators = [
|
|
3195
|
+
{ type: i0.NgModule, args: [{
|
|
3196
|
+
imports: [
|
|
3197
|
+
common.CommonModule,
|
|
3198
|
+
SharedModule
|
|
3199
|
+
],
|
|
3200
|
+
declarations: [
|
|
3201
|
+
SelectionsComponent
|
|
3202
|
+
],
|
|
3203
|
+
exports: [
|
|
3204
|
+
SelectionsComponent
|
|
3205
|
+
]
|
|
3206
|
+
},] }
|
|
3207
|
+
];
|
|
3208
|
+
|
|
3209
|
+
/**
|
|
3210
|
+
* Generated bundle index. Do not edit.
|
|
3211
|
+
*/
|
|
2728
3212
|
|
|
2729
3213
|
exports.AnswersComponent = AnswersComponent;
|
|
2730
3214
|
exports.AnswersModule = AnswersModule;
|
|
@@ -2732,14 +3216,13 @@
|
|
|
2732
3216
|
exports.ConfiguratorService = ConfiguratorService;
|
|
2733
3217
|
exports.SelectionsComponent = SelectionsComponent;
|
|
2734
3218
|
exports.SelectionsModule = SelectionsModule;
|
|
2735
|
-
exports
|
|
2736
|
-
exports
|
|
2737
|
-
exports
|
|
2738
|
-
exports
|
|
2739
|
-
exports
|
|
2740
|
-
exports.ɵf = VisibilityObserverMasterDirective;
|
|
3219
|
+
exports["ɵa"] = SharedModule;
|
|
3220
|
+
exports["ɵb"] = LoaderComponent;
|
|
3221
|
+
exports["ɵc"] = AnswerComponent;
|
|
3222
|
+
exports["ɵd"] = VisibilityObserverDirective;
|
|
3223
|
+
exports["ɵe"] = VisibilityObserverMasterDirective;
|
|
2741
3224
|
|
|
2742
3225
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
2743
3226
|
|
|
2744
|
-
}))
|
|
3227
|
+
}));
|
|
2745
3228
|
//# sourceMappingURL=colijnit-configurator.umd.js.map
|