metronics-vue 1.7.23 → 1.7.25
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/metronics-vue.es.js
CHANGED
|
@@ -7161,21 +7161,24 @@ const Da = /* @__PURE__ */ N(Ma, [["render", $a]]), Na = {
|
|
|
7161
7161
|
name: "KtPageTitle",
|
|
7162
7162
|
computed: {
|
|
7163
7163
|
computedBreadcrumbs() {
|
|
7164
|
-
|
|
7164
|
+
console.log("--- [KT-Debug] Starting Breadcrumb Generation ---");
|
|
7165
|
+
const i = {};
|
|
7166
|
+
this.$route.matched.forEach((t, e) => {
|
|
7167
|
+
console.log(`[KT-Debug] Params found at Level ${e} (${t.path}):`, t.params), Object.assign(i, t.params);
|
|
7168
|
+
}), Object.assign(i, this.$route.params), console.log("[KT-Debug] FINAL MERGED PARAMS:", i);
|
|
7169
|
+
const s = [];
|
|
7165
7170
|
return this.$route.matched.forEach((t) => {
|
|
7166
7171
|
var r;
|
|
7167
7172
|
const e = (r = t.meta) == null ? void 0 : r.breadcrumb;
|
|
7168
7173
|
if (!e) return;
|
|
7169
7174
|
(Array.isArray(e) ? e : [e]).forEach((a) => {
|
|
7170
|
-
const o = typeof a == "object" ? a.label : a, l = typeof a == "object" ? a.to : null;
|
|
7171
|
-
|
|
7172
|
-
|
|
7173
|
-
|
|
7174
|
-
// Resolves links: "/clients/:client_id" -> "/clients/1"
|
|
7175
|
-
to: l ? this.resolveDynamicString(l, s, !0) : null
|
|
7175
|
+
const o = typeof a == "object" ? a.label : a, l = typeof a == "object" ? a.to : null, c = this.resolveDynamicString(o, i, !1), d = l ? this.resolveDynamicString(l, i, !0) : null;
|
|
7176
|
+
l && l.includes(":") && console.log(`[KT-Debug] Resolving Path: "${l}" -> "${d}"`), s.push({
|
|
7177
|
+
label: c,
|
|
7178
|
+
to: d
|
|
7176
7179
|
});
|
|
7177
7180
|
});
|
|
7178
|
-
}),
|
|
7181
|
+
}), console.log("--- [KT-Debug] Generation Complete ---"), s;
|
|
7179
7182
|
},
|
|
7180
7183
|
pageTitle() {
|
|
7181
7184
|
const i = this.computedBreadcrumbs[this.computedBreadcrumbs.length - 1];
|
|
@@ -7183,18 +7186,13 @@ const Da = /* @__PURE__ */ N(Ma, [["render", $a]]), Na = {
|
|
|
7183
7186
|
}
|
|
7184
7187
|
},
|
|
7185
7188
|
methods: {
|
|
7186
|
-
/**
|
|
7187
|
-
* The "Universal Resolver"
|
|
7188
|
-
* Finds any word starting with ":" and replaces it with the route param value.
|
|
7189
|
-
*/
|
|
7190
7189
|
resolveDynamicString(i, s, t) {
|
|
7191
7190
|
if (!i || typeof i != "string") return i;
|
|
7192
7191
|
const e = /:([a-zA-Z0-9_]+)/g;
|
|
7193
|
-
|
|
7194
|
-
const
|
|
7195
|
-
return
|
|
7192
|
+
return i.replace(e, (n, r) => {
|
|
7193
|
+
const a = s[r];
|
|
7194
|
+
return a != null ? t ? a : String(a).replace(/-/g, " ") : (console.warn(`[KT-Debug] WARNING: Param "${r}" was not found in the merged params list.`), n);
|
|
7196
7195
|
});
|
|
7197
|
-
return t || (n = n.replace(/\b\w/g, (r) => r.toUpperCase())), n;
|
|
7198
7196
|
}
|
|
7199
7197
|
}
|
|
7200
7198
|
}, Ba = { class: "kt-page-title flex flex-col gap-1" }, Ra = { class: "text-gray-900 text-lg font-semibold" }, ja = {
|