Hi,
there is a tooltip on the input which simply shows the previous placeholder/watermark.
Its gone, after typing any input.
I would like to disable this tooltip at all.
In case the locator is enabled as single source its gone and replaced by a locator message.
This shouldn't be disabled.
Seen on the sample here:
https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-search/
BTW:
Why dont you put samples into the docs any more as we were used to have on the old widget docs.
To be honest, I often am googlin for the widgets doc to get the samples related and their codepens.
Hope this will come back for components as well.
I believe the tool tip comes from the title.
const search = new Search({
view: view
});
view.ui.add(search, "top-right");
search.when(() => {
const input = search.container.querySelector("input");
if (input) {
input.removeAttribute("title");
}
})
Hi,
thanks for reaching out.
Despite youre using old widget, I cannot see any title on the input. Do you?
Sorry, not many have moved onto components yet. Try this.
<arcgis-search
id="search"
popup-disabled
></arcgis-search>
My guess is the title is now behind the shadow dom. So you might need to wait until the component is ready.
const search = document.getElementById("search");
search.addEventListener("arcgisReady", () => {
// access internal input inside shadow DOM
const input = search.shadowRoot?.querySelector("input");
// remove browser tooltip
input?.removeAttribute("title");
});