Skip to content

Commit

Permalink
fixup! Add shared items and events for each contact
Browse files Browse the repository at this point in the history
Signed-off-by: greta <[email protected]>
  • Loading branch information
GretaD committed Oct 26, 2023
1 parent 2a117d5 commit a187fb3
Showing 1 changed file with 33 additions and 6 deletions.
39 changes: 33 additions & 6 deletions src/components/ContactDetails.vue
Original file line number Diff line number Diff line change
Expand Up @@ -265,9 +265,6 @@
</template>
</NcButton>
</div>
<NcRelatedResourcesPanel v-if="nextcloudVersion"
provider-id="account"
:item-id="contact.uid" />
<!-- contact details -->
<section class="contact-details">
<!-- properties iteration -->
Expand Down Expand Up @@ -310,13 +307,27 @@
class="property--groups property--last"
@update:value="updateGroups" />
</div>
<div v-if="nextcloudVersion" class="related-resources">
<NcRelatedResourcesPanel provider-id="account"
resource-type="files"
:item-id="contact.uid" />
<NcRelatedResourcesPanel provider-id="account"
resource-type="talk"
:item-id="contact.uid" />
<NcRelatedResourcesPanel provider-id="account"
resource-type="calendar"
:item-id="contact.uid" />
<NcRelatedResourcesPanel provider-id="account"
resource-type="deck"
:item-id="contact.uid" />
</div>
<!-- new property select -->
<AddNewProp v-if="!isReadOnly"
:bus="bus"
:contact="contact" />

<!-- Last modified-->
<PropertyRev v-if="contact.rev" :value="contact.rev" />
<PropertyRev v-if="contact.rev" :value="contact.rev" class="last-edit" />
</template>
</AppContentDetails>
</template>
Expand Down Expand Up @@ -682,8 +693,7 @@ export default {
return this.contact.addressbook.id === 'z-server-generated--system'
},
nextcloudVersion() {
// TODO: remove it when NC 25 is not supported anymore
return parseInt(OC.config.version.split('.')[0]) >= 26
return parseInt(OC.config.version.split('.')[0]) >= 28

Check warning on line 696 in src/components/ContactDetails.vue

View check run for this annotation

Codecov / codecov/patch

src/components/ContactDetails.vue#L695-L696

Added lines #L695 - L696 were not covered by tests
},
},

Expand Down Expand Up @@ -997,6 +1007,7 @@ export default {
align-items: flex-start;
padding: 50px 0 20px;
gap: 15px;
float: left;

Check warning on line 1010 in src/components/ContactDetails.vue

View check run for this annotation

Codecov / codecov/patch

src/components/ContactDetails.vue#L1010

Added line #L1010 was not covered by tests
}
@media only screen and (max-width: 600px) {
.contact-details-wrapper {
Expand Down Expand Up @@ -1066,5 +1077,21 @@ section.contact-details {
background-color: var(--color-primary-element-light-hover) !important;

}
.related-resources {
display:inline-grid;
margin-top: 88px;
flex-direction: column;
}
@media only screen and (max-width: 1600px) {
.related-resources {
float: left;
display: inline-grid;
margin-left: 80px;
flex-direction: column
}
}

Check warning on line 1092 in src/components/ContactDetails.vue

View check run for this annotation

Codecov / codecov/patch

src/components/ContactDetails.vue#L1092

Added line #L1092 was not covered by tests
.last-edit {
display: inline-flex;

Check warning on line 1094 in src/components/ContactDetails.vue

View check run for this annotation

Codecov / codecov/patch

src/components/ContactDetails.vue#L1094

Added line #L1094 was not covered by tests
}

</style>

0 comments on commit a187fb3

Please sign in to comment.