Rename "only" to "disambiguation" to match naming convention used for pitch accents
This commit is contained in:
parent
6788bb31d2
commit
bb37b74288
@ -365,19 +365,19 @@ button.action-button {
|
|||||||
list-style-type: circle;
|
list-style-type: circle;
|
||||||
}
|
}
|
||||||
|
|
||||||
.term-definition-only-list[data-count="0"] {
|
.term-definition-disambiguation-list[data-count="0"] {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.term-definition-only-list:before {
|
.term-definition-disambiguation-list:before {
|
||||||
content: "(";
|
content: "(";
|
||||||
}
|
}
|
||||||
|
|
||||||
.term-definition-only-list:after {
|
.term-definition-disambiguation-list:after {
|
||||||
content: " only)";
|
content: " only)";
|
||||||
}
|
}
|
||||||
|
|
||||||
.term-definition-only+.term-definition-only:before {
|
.term-definition-disambiguation+.term-definition-disambiguation:before {
|
||||||
content: ", ";
|
content: ", ";
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -399,7 +399,7 @@ button.action-button {
|
|||||||
}
|
}
|
||||||
|
|
||||||
:root[data-compact-glossaries=true] .term-definition-tag-list,
|
:root[data-compact-glossaries=true] .term-definition-tag-list,
|
||||||
:root[data-compact-glossaries=true] .term-definition-only-list:not([data-count="0"]) {
|
:root[data-compact-glossaries=true] .term-definition-disambiguation-list:not([data-count="0"]) {
|
||||||
display: inline;
|
display: inline;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -30,10 +30,10 @@
|
|||||||
</div></div></template>
|
</div></div></template>
|
||||||
<template id="term-definition-item-template"><li class="term-definition-item">
|
<template id="term-definition-item-template"><li class="term-definition-item">
|
||||||
<div class="term-definition-tag-list tag-list"></div>
|
<div class="term-definition-tag-list tag-list"></div>
|
||||||
<div class="term-definition-only-list"></div>
|
<div class="term-definition-disambiguation-list"></div>
|
||||||
<ul class="term-glossary-list"></ul>
|
<ul class="term-glossary-list"></ul>
|
||||||
</li></template>
|
</li></template>
|
||||||
<template id="term-definition-only-template"><span class="term-definition-only"></span></template>
|
<template id="term-definition-disambiguation-template"><span class="term-definition-disambiguation"></span></template>
|
||||||
<template id="term-glossary-item-template"><li class="term-glossary-item"><span class="term-glossary-separator"> </span><span class="term-glossary"></span></li></template>
|
<template id="term-glossary-item-template"><li class="term-glossary-item"><span class="term-glossary-separator"> </span><span class="term-glossary"></span></li></template>
|
||||||
<template id="term-reason-template"><span class="term-reason"></span><span class="term-reason-separator"> </span></template>
|
<template id="term-reason-template"><span class="term-reason"></span><span class="term-reason-separator"> </span></template>
|
||||||
|
|
||||||
|
@ -176,13 +176,13 @@ class DisplayGenerator {
|
|||||||
const node = this._templateHandler.instantiate('term-definition-item');
|
const node = this._templateHandler.instantiate('term-definition-item');
|
||||||
|
|
||||||
const tagListContainer = node.querySelector('.term-definition-tag-list');
|
const tagListContainer = node.querySelector('.term-definition-tag-list');
|
||||||
const onlyListContainer = node.querySelector('.term-definition-only-list');
|
const onlyListContainer = node.querySelector('.term-definition-disambiguation-list');
|
||||||
const glossaryContainer = node.querySelector('.term-glossary-list');
|
const glossaryContainer = node.querySelector('.term-glossary-list');
|
||||||
|
|
||||||
node.dataset.dictionary = details.dictionary;
|
node.dataset.dictionary = details.dictionary;
|
||||||
|
|
||||||
this._appendMultiple(tagListContainer, this._createTag.bind(this), details.definitionTags);
|
this._appendMultiple(tagListContainer, this._createTag.bind(this), details.definitionTags);
|
||||||
this._appendMultiple(onlyListContainer, this._createTermOnly.bind(this), details.only);
|
this._appendMultiple(onlyListContainer, this._createTermDisambiguation.bind(this), details.only);
|
||||||
this._appendMultiple(glossaryContainer, this._createTermGlossaryItem.bind(this), details.glossary);
|
this._appendMultiple(glossaryContainer, this._createTermGlossaryItem.bind(this), details.glossary);
|
||||||
|
|
||||||
return node;
|
return node;
|
||||||
@ -197,10 +197,10 @@ class DisplayGenerator {
|
|||||||
return node;
|
return node;
|
||||||
}
|
}
|
||||||
|
|
||||||
_createTermOnly(only) {
|
_createTermDisambiguation(disambiguation) {
|
||||||
const node = this._templateHandler.instantiate('term-definition-only');
|
const node = this._templateHandler.instantiate('term-definition-disambiguation');
|
||||||
node.dataset.only = only;
|
node.dataset.term = disambiguation;
|
||||||
node.textContent = only;
|
node.textContent = disambiguation;
|
||||||
return node;
|
return node;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user