@salesforcedevs/docs-components 0.70.1-alpha.0 → 0.74.3-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -173,15 +173,23 @@ export default class Breadcrumbs extends LightningElement {
|
|
|
173
173
|
breadcrumbs: Breadcrumb[],
|
|
174
174
|
offset: number = 0
|
|
175
175
|
): number {
|
|
176
|
-
return breadcrumbs.reduce(
|
|
177
|
-
(
|
|
176
|
+
return breadcrumbs.reduce((previousValue, element) => {
|
|
177
|
+
if (!element.label) {
|
|
178
|
+
console.error(
|
|
179
|
+
"Breadcrumb label not found for element: ",
|
|
180
|
+
element
|
|
181
|
+
);
|
|
182
|
+
return previousValue;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
return (
|
|
178
186
|
previousValue +
|
|
179
187
|
Math.min(
|
|
180
188
|
element.label.length *
|
|
181
189
|
(this.pixelPerCharacter || CONSTANTS.pixelPerCharacter),
|
|
182
190
|
CONSTANTS.minWidthPerCrumb
|
|
183
|
-
)
|
|
184
|
-
|
|
185
|
-
);
|
|
191
|
+
)
|
|
192
|
+
);
|
|
193
|
+
}, (breadcrumbs.length - 1) * CONSTANTS.pixelPerCrumbSpace + offset);
|
|
186
194
|
}
|
|
187
195
|
}
|
|
@@ -150,7 +150,7 @@ export default class Content extends LightningElement {
|
|
|
150
150
|
is: ContentCallout
|
|
151
151
|
});
|
|
152
152
|
const detailEls = calloutEl.querySelectorAll(
|
|
153
|
-
"p, div.data, ol, ul, p+.codeSection, .mediaBd > span.ph"
|
|
153
|
+
"p, .p, div.data, ol, ul, p+.codeSection, p~.codeSection, div >.codeSection, .mediaBd > span.ph"
|
|
154
154
|
);
|
|
155
155
|
detailEls.forEach((detailEl) => {
|
|
156
156
|
if (detailEl.innerHTML.trim() !== "") {
|
|
@@ -159,7 +159,7 @@ export default class Content extends LightningElement {
|
|
|
159
159
|
});
|
|
160
160
|
|
|
161
161
|
let flag = 1;
|
|
162
|
-
for (let i = 0; i < detailEls.length; i++) {
|
|
162
|
+
for (let i: number = 0; i < detailEls.length; i++) {
|
|
163
163
|
flag &= detailEls[i].innerHTML.trim() === "";
|
|
164
164
|
}
|
|
165
165
|
|