Skip to content

Commit

Permalink
fix(ui5-combobox): remove incorrect sample (SAP#4482)
Browse files Browse the repository at this point in the history
  • Loading branch information
niyap authored and eshpak committed Jan 8, 2022
1 parent 2ebcaa5 commit a2469a4
Showing 1 changed file with 0 additions and 73 deletions.
73 changes: 0 additions & 73 deletions packages/main/test/samples/ComboBox.sample.html
Original file line number Diff line number Diff line change
Expand Up @@ -214,77 +214,4 @@ <h3>ComboBox with Grouping of Items</h3>

</section>

<section>
<h3>Lazy loading</h3>

<div class="snippet responsive-snippet">
<ui5-combobox placeholder="Enter value" id="lazy-cb"></ui5-combobox>

<script>
const combo = document.getElementById("lazy-cb");

combo.addEventListener("input", function (event) {
while (combo.firstChild) {
combo.removeChild(combo.firstChild);
}

event.target.loading = true;

fetch("https://restcountries.eu/rest/v2/?fields=name")
.then(function (response) {
response.json()
.then(function (list) {

list.forEach(function (country) {
const element = document.createElement("ui5-cb-item");

element.setAttribute("text", country.name);
combo.appendChild(element);
});

event.target.loading = false;

});
})
.catch(function () { });
});
</script>
</div>

<pre class="prettyprint lang-html"><xmp>
<ui5-combobox placeholder="Enter value" id="lazy-cb"></ui5-combobox>

<script>
const combo = document.getElementById("lazy-cb");

combo.addEventListener("input", function (event) {
while (combo.firstChild) {
combo.removeChild(combo.firstChild);
}

event.target.loading = true;

fetch("https://restcountries.eu/rest/v2/?fields=name")
.then(function (response) {
response.json()
.then(function (list) {

list.forEach(function (country) {
const element = document.createElement("ui5-cb-item");

element.setAttribute("text", country.name);
combo.appendChild(element);
});

event.target.loading = false;

});
})
.catch(function () { });
});
</script>
</xmp></pre>
</pre>
</section>

<!-- JSDoc marker -->

0 comments on commit a2469a4

Please sign in to comment.