@startinblox/components-ds4go 3.3.1 → 3.3.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/dist/index.js +5 -5
- package/package.json +1 -1
- package/src/components/solid-dsp-catalog.ts +14 -5
package/dist/index.js
CHANGED
|
@@ -9001,7 +9001,7 @@ let Ce = class extends re {
|
|
|
9001
9001
|
_openModal(t) {
|
|
9002
9002
|
if (t.preventDefault(), this.route)
|
|
9003
9003
|
if ("use-id" in (this.component.routeAttributes || {}))
|
|
9004
|
-
M(this.route, t.detail["@id"]);
|
|
9004
|
+
this.object = t.detail, this.dataSrc = t.detail["@id"], M(this.route, t.detail["@id"]);
|
|
9005
9005
|
else {
|
|
9006
9006
|
const e = t.detail["@type"]?.at(-1) ?? t.detail["@type"];
|
|
9007
9007
|
if (e) {
|
|
@@ -9016,10 +9016,10 @@ let Ce = class extends re {
|
|
|
9016
9016
|
}
|
|
9017
9017
|
}
|
|
9018
9018
|
_closeModal(t) {
|
|
9019
|
-
t.preventDefault(), this.route && M(this.route, this.defaultDataSrc);
|
|
9019
|
+
t.preventDefault(), this.route && (M(this.route, this.defaultDataSrc), this.dataSrc = void 0, this.object = void 0);
|
|
9020
9020
|
}
|
|
9021
9021
|
_closeModalFromBackground(t) {
|
|
9022
|
-
t.preventDefault(), this.route && t.target?.classList.contains("modal") && M(this.route, this.defaultDataSrc);
|
|
9022
|
+
t.preventDefault(), this.route && t.target?.classList.contains("modal") && (M(this.route, this.defaultDataSrc), this.dataSrc = void 0, this.object = void 0);
|
|
9023
9023
|
}
|
|
9024
9024
|
_resultCountUpdate(t) {
|
|
9025
9025
|
this.resultCount = t.detail ?? 0;
|
|
@@ -9081,10 +9081,10 @@ let Ce = class extends re {
|
|
|
9081
9081
|
class="modal"
|
|
9082
9082
|
@click=${this._closeModalFromBackground}
|
|
9083
9083
|
>
|
|
9084
|
-
<ds4go-catalog
|
|
9084
|
+
<ds4go-catalog-modal
|
|
9085
9085
|
.object=${this.object}
|
|
9086
9086
|
@close=${this._closeModal}
|
|
9087
|
-
></ds4go-catalog>
|
|
9087
|
+
></ds4go-catalog-modal>
|
|
9088
9088
|
</div>` : l}
|
|
9089
9089
|
</div>
|
|
9090
9090
|
</tems-viewport>`
|
package/package.json
CHANGED
|
@@ -86,7 +86,7 @@ export class DSPCatalog extends OrbitDSPComponent {
|
|
|
86
86
|
document.removeEventListener("dsp-connector-ready", listener);
|
|
87
87
|
};
|
|
88
88
|
document.addEventListener("dsp-connector-ready", listener);
|
|
89
|
-
|
|
89
|
+
return;
|
|
90
90
|
}
|
|
91
91
|
|
|
92
92
|
if (objSrc) {
|
|
@@ -110,6 +110,8 @@ export class DSPCatalog extends OrbitDSPComponent {
|
|
|
110
110
|
e.preventDefault();
|
|
111
111
|
if (this.route) {
|
|
112
112
|
if ("use-id" in (this.component.routeAttributes || {})) {
|
|
113
|
+
this.object = e.detail;
|
|
114
|
+
this.dataSrc = e.detail["@id"];
|
|
113
115
|
utils.requestNavigation(this.route, e.detail["@id"]);
|
|
114
116
|
} else {
|
|
115
117
|
const rdfType = e.detail["@type"]?.at(-1) ?? e.detail["@type"];
|
|
@@ -131,13 +133,20 @@ export class DSPCatalog extends OrbitDSPComponent {
|
|
|
131
133
|
|
|
132
134
|
_closeModal(e: Event) {
|
|
133
135
|
e.preventDefault();
|
|
134
|
-
if (this.route)
|
|
136
|
+
if (this.route) {
|
|
137
|
+
utils.requestNavigation(this.route, this.defaultDataSrc);
|
|
138
|
+
this.dataSrc = undefined;
|
|
139
|
+
this.object = undefined;
|
|
140
|
+
}
|
|
135
141
|
}
|
|
136
142
|
|
|
137
143
|
_closeModalFromBackground(e: Event) {
|
|
138
144
|
e.preventDefault();
|
|
139
|
-
if (this.route && e.target?.classList.contains("modal"))
|
|
145
|
+
if (this.route && e.target?.classList.contains("modal")) {
|
|
140
146
|
utils.requestNavigation(this.route, this.defaultDataSrc);
|
|
147
|
+
this.dataSrc = undefined;
|
|
148
|
+
this.object = undefined;
|
|
149
|
+
}
|
|
141
150
|
}
|
|
142
151
|
|
|
143
152
|
_resultCountUpdate(e: Event) {
|
|
@@ -220,10 +229,10 @@ export class DSPCatalog extends OrbitDSPComponent {
|
|
|
220
229
|
class="modal"
|
|
221
230
|
@click=${this._closeModalFromBackground}
|
|
222
231
|
>
|
|
223
|
-
<ds4go-catalog
|
|
232
|
+
<ds4go-catalog-modal
|
|
224
233
|
.object=${this.object}
|
|
225
234
|
@close=${this._closeModal}
|
|
226
|
-
></ds4go-catalog>
|
|
235
|
+
></ds4go-catalog-modal>
|
|
227
236
|
</div>`
|
|
228
237
|
: nothing}
|
|
229
238
|
</div>
|