@salesforcedevs/dx-components 0.19.3-alpha.15 → 0.19.3-alpha.19
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
|
@@ -146,6 +146,7 @@ export default class SidebarSearch extends LightningElement {
|
|
|
146
146
|
if (!this.didRender && this.value) {
|
|
147
147
|
console.log('dispatching highlight term in the render')
|
|
148
148
|
this.dispatchHighlightedTermChange();
|
|
149
|
+
window.addEventListener('search-syncer-initialized', () => console.log('SEARCH SYNCER INITD'))
|
|
149
150
|
}
|
|
150
151
|
|
|
151
152
|
this.didRender = true;
|
|
@@ -34,6 +34,7 @@ export const highlightTerms = (
|
|
|
34
34
|
innerHtml = innerHtml.replace(searchExp, "<mark>$&</mark>");
|
|
35
35
|
}
|
|
36
36
|
|
|
37
|
+
element.setAttribute('lwc:dom', 'manual')
|
|
37
38
|
element.innerHTML = innerHtml;
|
|
38
39
|
} catch (e) {
|
|
39
40
|
console.error(e, element);
|
|
@@ -43,8 +44,8 @@ export const highlightTerms = (
|
|
|
43
44
|
const mark = element.querySelector("mark");
|
|
44
45
|
if (mark && !scrolled) {
|
|
45
46
|
scrolled = true;
|
|
46
|
-
console.log("scrolling",
|
|
47
|
-
|
|
47
|
+
console.log("scrolling", mark);
|
|
48
|
+
mark.scrollIntoView({ block: "nearest" });
|
|
48
49
|
}
|
|
49
50
|
});
|
|
50
51
|
};
|