Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add push warning on fixed contact #982

Merged
merged 1 commit into from
Sep 27, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions css/Properties/Properties.scss
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,8 @@ $property-value-max-width: 250px;
// External link (tel, mailto, http, ftp...)
&__ext {
position: absolute;
// 8px padding
right: 8px;
// 8px padding + actions
right: 44px + 8px;
opacity: 0;
&:hover,
&:focus,
Expand Down
10 changes: 10 additions & 0 deletions src/components/ContactDetails.vue
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,16 @@
class="header-icon header-icon--pulse icon-history-force-white"
@click="refreshContact" />

<!-- repaired contact message -->
<div v-if="fixed"
v-tooltip="{
content: t('contacts', 'This contact was broken and received a fix. Please review the content and click here to save it.'),
show: true,
trigger: 'manual',
}"
class="header-icon header-icon--pulse icon-up-force-white"
@click="updateContact" />

<!-- menu actions -->
<Actions class="header-menu" menu-align="right">
<ActionLink :href="contact.url"
Expand Down
6 changes: 3 additions & 3 deletions src/components/Properties/PropertyText.vue
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ export default {
} else if (this.propName === 'email') {
return 'mailto:'
// if no scheme (roughly checking for the colon char)
} else if (this.propType === 'uri' && this.value.indexOf(':') === -1) {
} else if (this.propType === 'uri' && this.localValue && this.localValue.indexOf(':') === -1) {
return 'https://'
} else if (this.propType === 'uri') {
return '' // return empty, we already have a scheme in the value
Expand All @@ -160,13 +160,13 @@ export default {
// format external link
externalHandler() {
if (this.URLScheme !== false) {
return `${this.URLScheme}${this.value}`
return `${this.URLScheme}${this.localValue}`
}
return ''
},

haveExtHandler() {
return this.externalHandler.trim() !== '' && this.value && this.value.length > 0
return this.externalHandler.trim() !== '' && this.localValue && this.localValue.length > 0
}
},

Expand Down