refactor: leave culture name only

This commit is contained in:
Azgaar 2024-02-14 20:06:44 +01:00
parent 830fa97d42
commit 3d8af76e42
2 changed files with 10 additions and 13 deletions

View file

@ -4688,13 +4688,14 @@
class="icon-arrows-cw pointer"
></span>
</div>
<div id="provinceCultureName" data-tip="Dominant culture in the province. This decides the naming criteria">
Province culture:&nbsp;<span id="provinceCultureDisplay"></span>
</div>
<div id="provinceCultureBaseName" data-tip="Namesbase used by the dominant culture in the province.">
Province language:&nbsp;<span id="provinceLanguageDisplay"></span>
</div>
<div
id="provinceCultureName"
data-tip="Dominant culture in the province. This defines culture-based naming. Can be changed via the Cultures Editor"
style="margin-top: 0.2em"
>
Dominant culture:&nbsp;<span id="provinceCultureDisplay"></span>
</div>
</div>
<div id="namesbaseEditor" class="dialog stable textual" style="display: none">

View file

@ -500,13 +500,9 @@ function editProvinces() {
document.getElementById("provinceNameEditorShort").value = p.name;
applyOption(provinceNameEditorSelectForm, p.formName);
document.getElementById("provinceNameEditorFull").value = p.fullName;
const cultureId = pack.cells.culture[p.center];
const cultureName = pack.cultures[cultureId].name;
const provinceLangID = pack.cultures[pack.cells.culture[pack.provinces[province].center]].base;
const provinceNameBase = Names.getNameBases()[provinceLangID].name;
document.getElementById("provinceCultureDisplay").innerText = cultureName;
document.getElementById("provinceLanguageDisplay").innerText = provinceNameBase;
document.getElementById("provinceCultureDisplay").innerText = pack.cultures[cultureId].name;
$("#provinceNameEditor").dialog({
resizable: false,