Skip to content

Commit

Permalink
minor changes
Browse files Browse the repository at this point in the history
* demo file with fixed date of first map
* hide comparison button (instead of only disable)
* JSON filename without version info because it includes all maps
* wording "Version" to "Karte"
* remove unneeded code
  • Loading branch information
alex-rind committed Feb 26, 2024
1 parent c1eadec commit e97a56a
Show file tree
Hide file tree
Showing 4 changed files with 167 additions and 167 deletions.
314 changes: 162 additions & 152 deletions public/Rosa_Braunsteigl-Mueller.json
Original file line number Diff line number Diff line change
@@ -1,157 +1,167 @@
{
"ego": {
"name": "Rosa Braunsteigl-Müller",
"currentGender": "weiblich",
"age": "45",
"note": "lorem ipsum"
},
"alteri": [
{
"id": 11,
"name": "Ewald",
"role": "Familienangehörige*r",
"roleDefault": true,
"human": true,
"currentGender": "nicht festgelegt",
"genderDefault": true,
"age": "",
"note": "",
"deceased": false,
"edgeType": 1,
"edgeTypeByUser": -1,
"angle": 82.59647651462154,
"distance": 61.56025977017402
},
{
"id": 10,
"name": "Josefine",
"role": "Großtante",
"roleDefault": false,
"human": true,
"currentGender": "weiblich",
"genderDefault": false,
"age": "86",
"note": "",
"deceased": false,
"edgeType": "0",
"edgeTypeByUser": "0",
"angle": 63.66630822906832,
"distance": 78.41498418743308
},
{
"id": 9,
"name": "Strolchi",
"role": "Hund",
"roleDefault": false,
"human": false,
"currentGender": "nicht festgelegt",
"genderDefault": true,
"age": "",
"note": "",
"deceased": false,
"edgeType": 0,
"edgeTypeByUser": -1,
"angle": 32.91800440620509,
"distance": 49.93474976494444
},
{
"id": 8,
"name": "Susi",
"role": "Studienkolleg*in",
"contactOfPartner": false,
"human": true,
"currentGender": "weiblich",
"age": "27",
"note": "",
"edgeType": 1,
"angle": -131.1060924804431,
"distance": 42.31366368839073
},
{
"id": 7,
"name": "Dr. Maier",
"role": "Ärzt*in",
"contactOfPartner": false,
"human": true,
"currentGender": "nicht festgelegt",
"age": "",
"note": "",
"edgeType": 1,
"angle": -50.92234207573893,
"distance": 93.73453583270009
},
{
"id": 5,
"name": "Hubert",
"role": "Vater",
"contactOfPartner": false,
"human": true,
"currentGender": "männlich",
"age": "",
"note": "",
"deceased": true,
"edgeType": 0,
"angle": 70,
"distance": 103
},
{
"id": 4,
"name": "Lara",
"role": "Freund*in",
"contactOfPartner": false,
"human": true,
"currentGender": "divers",
"age": "34",
"note": "",
"edgeType": 2,
"angle": 137.52753497925326,
"distance": 75.01518991342189
},
{
"id": 3,
"name": "Max",
"role": "Studienkolleg*in",
"contactOfPartner": false,
"human": true,
"currentGender": "nicht festgelegt",
"age": "",
"note": "",
"edgeType": 1,
"angle": -114.86833156298106,
"distance": 71.90407620902847
},
{
"id": 2,
"name": "Richard",
"role": "Lebensgefährt*in",
"contactOfPartner": false,
"human": true,
"currentGender": "männlich",
"age": "",
"note": "",
"edgeType": 1,
"angle": 15.195768445698295,
"distance": 19.709025754817713
},
{
"versions": [
{
"id": 1,
"name": "Maria",
"role": "Mutter",
"contactOfPartner": false,
"human": true,
"currentGender": "weiblich",
"age": "",
"note": "",
"edgeType": 1,
"angle": 30.051411748698495,
"distance": 27.853551485665644
"title": "Erstgespräch",
"date": "2024-02-26",
"nwk": {
"ego": {
"name": "Rosa Braunsteigl-Müller",
"currentGender": "weiblich",
"age": "45",
"note": "lorem ipsum"
},
"alteri": [
{
"id": 11,
"name": "Ewald",
"role": "Familienangehörige*r",
"roleDefault": true,
"human": true,
"currentGender": "nicht festgelegt",
"genderDefault": true,
"age": "",
"note": "",
"deceased": false,
"edgeType": 1,
"edgeTypeByUser": -1,
"angle": 82.59647651462154,
"distance": 61.56025977017402
},
{
"id": 10,
"name": "Josefine",
"role": "Großtante",
"roleDefault": false,
"human": true,
"currentGender": "weiblich",
"genderDefault": false,
"age": "86",
"note": "",
"deceased": false,
"edgeType": "0",
"edgeTypeByUser": "0",
"angle": 63.66630822906832,
"distance": 78.41498418743308
},
{
"id": 9,
"name": "Strolchi",
"role": "Hund",
"roleDefault": false,
"human": false,
"currentGender": "nicht festgelegt",
"genderDefault": true,
"age": "",
"note": "",
"deceased": false,
"edgeType": 0,
"edgeTypeByUser": -1,
"angle": 32.91800440620509,
"distance": 49.93474976494444
},
{
"id": 8,
"name": "Susi",
"role": "Studienkolleg*in",
"contactOfPartner": false,
"human": true,
"currentGender": "weiblich",
"age": "27",
"note": "",
"edgeType": 1,
"angle": -131.1060924804431,
"distance": 42.31366368839073
},
{
"id": 7,
"name": "Dr. Maier",
"role": "Ärzt*in",
"contactOfPartner": false,
"human": true,
"currentGender": "nicht festgelegt",
"age": "",
"note": "",
"edgeType": 1,
"angle": -50.92234207573893,
"distance": 93.73453583270009
},
{
"id": 5,
"name": "Hubert",
"role": "Vater",
"contactOfPartner": false,
"human": true,
"currentGender": "männlich",
"age": "",
"note": "",
"deceased": true,
"edgeType": 0,
"angle": 70,
"distance": 103
},
{
"id": 4,
"name": "Lara",
"role": "Freund*in",
"contactOfPartner": false,
"human": true,
"currentGender": "divers",
"age": "34",
"note": "",
"edgeType": 2,
"angle": 137.52753497925326,
"distance": 75.01518991342189
},
{
"id": 3,
"name": "Max",
"role": "Studienkolleg*in",
"contactOfPartner": false,
"human": true,
"currentGender": "nicht festgelegt",
"age": "",
"note": "",
"edgeType": 1,
"angle": -114.86833156298106,
"distance": 71.90407620902847
},
{
"id": 2,
"name": "Richard",
"role": "Lebensgefährt*in",
"contactOfPartner": false,
"human": true,
"currentGender": "männlich",
"age": "",
"note": "",
"edgeType": 1,
"angle": 15.195768445698295,
"distance": 19.709025754817713
},
{
"id": 1,
"name": "Maria",
"role": "Mutter",
"contactOfPartner": false,
"human": true,
"currentGender": "weiblich",
"age": "",
"note": "",
"edgeType": 1,
"angle": 30.051411748698495,
"distance": 27.853551485665644
}
],
"connections": [
{ "id1": 1, "id2": 4 },
{ "id1": 1, "id2": 2 },
{ "id1": 1, "id2": 10 },
{ "id1": 11, "id2": 10 },
{ "id1": 11, "id2": 1 }
]
}
}
],
"connections": [
{ "id1": 1, "id2": 4 },
{ "id1": 1, "id2": 2 },
{ "id1": 1, "id2": 10 },
{ "id1": 11, "id2": 10 },
{ "id1": 11, "id2": 1 }
]
"currentVersion": 1
}
7 changes: 3 additions & 4 deletions src/components/ComparisonOptionsPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,14 @@
<span>Karte wechseln</span>
</button>

<!-- TODO hide comparison button before merging into main -->
<!-- TODO hide comparison button in the production code in main branch
<button class="button" @click.stop="toggleComparison" disabled>
<span class="icon">
<font-awesome-icon icon="compress-arrows-alt" />
</span>
<span v-if="!nwkcomparison">Vergleich ein</span>
<span v-else>Vergleich aus</span>
</button>
</button> -->
</div>

<div v-if="newVersion">
Expand Down Expand Up @@ -233,8 +233,7 @@ export default defineComponent({
};
const deleteVersion = () => {
const index: number = currentVersion.value - 1; // TODO AR 29 Aug 2023 bad smell, check!
store.commit("removeCurrentVersion", index);
store.commit("removeCurrentVersion");
};
return {
Expand Down
11 changes: 1 addition & 10 deletions src/components/SideMenu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -174,16 +174,7 @@ export default defineComponent({
store.commit("prepareToSaveJSON");
let nwkJSON = JSON.stringify(store.state.record);
let filename =
store.state.nwk.ego.name +
" " +
visibleNWKVersion.value?.title +
" " +
visibleNWKVersion.value?.date?.substring(8, 10) +
"." +
visibleNWKVersion.value?.date?.substring(5, 7) +
"." +
visibleNWKVersion.value?.date?.substring(0, 4);
let filename = store.state.nwk.ego.name;
if (store.state.pseudonym.active) {
const tempNWK = JSON.parse(nwkJSON) as NWK;
Expand Down
2 changes: 1 addition & 1 deletion src/views/PdfView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
<div id="egobar">
<p class="name">{{ "Ankerperson: " + ego.name }}</p>
<span v-if="versions.length && currentVersion >= 0">
Gedruckte Version: {{ visibleNWKVersion?.title || "" }}
Gedruckte Karte: {{ visibleNWKVersion?.title || "" }}
vom
<!-- TODO use internationalizable date formater -->
{{
Expand Down

0 comments on commit e97a56a

Please sign in to comment.