add category hints from methodlist
This commit is contained in:
parent
9722d09266
commit
207ecc31c9
|
@ -763,9 +763,9 @@ class CCPMethodEditorController extends HTMLElement{
|
||||||
}
|
}
|
||||||
|
|
||||||
renderCategoryHints(){
|
renderCategoryHints(){
|
||||||
const s = new Set(["Uncategorized", this.getCurrentCategory()])
|
|
||||||
const ml = document.querySelector("d4s-ccp-methodlist")
|
const ml = document.querySelector("d4s-ccp-methodlist")
|
||||||
const cats = ml ? [...s].concat(ml.getCategoryHints()) : [...s]
|
const cats = ml ? [...s].concat(ml.getCategoryHints()) : [...s]
|
||||||
|
if(cats.indexOf("Uncategorized") === -1) cats.push("Uncategorized")
|
||||||
return `
|
return `
|
||||||
<datalist id="categoryhints">
|
<datalist id="categoryhints">
|
||||||
${cats.map(c=>`<option value="${c}">${c}</option>`)}
|
${cats.map(c=>`<option value="${c}">${c}</option>`)}
|
||||||
|
|
Loading…
Reference in New Issue