Skip to content
This repository has been archived by the owner on Nov 3, 2021. It is now read-only.

Commit

Permalink
Bug 1078174 - [Contact] Improve UI on contact settings
Browse files Browse the repository at this point in the history
  • Loading branch information
Pavel Ivanov committed Nov 24, 2014
1 parent 401691e commit 5104717
Show file tree
Hide file tree
Showing 12 changed files with 19 additions and 59 deletions.
21 changes: 1 addition & 20 deletions apps/communications/contacts/js/views/settings.js
Expand Up @@ -551,29 +551,10 @@ contacts.Settings = (function() {
// If the total is not available then an empty string is showed
var theTotal = total || '';

var totalsMsgContent = _('facebook-import-msg', {
navigator.mozL10n.setAttributes(fbTotalsMsg, 'facebook-import-msg2', {
'imported': imported,
'total': theTotal
});

// This is to support the case of a long literal, particularly
// when 0 or 1 friends are imported
var msgPart1 = totalsMsgContent;
var msgPart2 = null;
if (imported <= 1) {
var position = totalsMsgContent.indexOf('(');
if (position != -1) {
msgPart1 = totalsMsgContent.substring(0, position - 1);
msgPart2 = totalsMsgContent.substring(position);
}
}
fbTotalsMsg.innerHTML = '';
fbTotalsMsg.appendChild(document.createTextNode(msgPart1));
if (msgPart2) {
var span = document.createElement('span');
span.textContent = msgPart2;
fbTotalsMsg.appendChild(span);
}
};

var onFbImport = function onFbImportClick(evt) {
Expand Down
4 changes: 0 additions & 4 deletions apps/communications/contacts/style/app.css
Expand Up @@ -246,10 +246,6 @@ li button.activity > b em {
pointer-events: none;
}

[data-type="list"] li aside.pack-end {
margin: 0 2rem 0 0;
}

/* Selection tag extended from shared/style/buttons.css */
.view-select-tag .selection-list li button {
background-color: #fff;
Expand Down
20 changes: 13 additions & 7 deletions apps/communications/contacts/style/contacts.css
Expand Up @@ -407,39 +407,44 @@ gaia-header [data-icon] {
justify-content: space-between;
}
#view-settings [data-type="list"] li#settingsOrder aside {
top: 0.5rem;
pointer-events: none;
align-self: flex-end;
align-self: center;
}

/* Cutom FB item */
#view-settings [data-type="list"] .fb-item {
height: auto;
border-bottom: none;
display: flex;
flex-direction: column;
}

#view-settings [data-type="list"] .fb-item p {
padding-left: 4.3rem;
padding-left: 4.2rem;
font-size: 1.4rem;
}

#view-settings [data-type="list"] .fb-item p span {
display: block;
padding-bottom: 0.4rem;
}

#view-settings [data-type="list"] .fb-item {
background: url(/contacts/style/images/f_logo.png) no-repeat 0 calc(50% + 0.5rem) / 3rem;
}

#view-settings [data-type="list"] .fb-item p:first-of-type {
background: url(/contacts/style/images/f_logo.png) no-repeat 0.5rem calc(50% + 0.5rem) / 3rem;
height: 3rem;
font-size: 1.9rem;
line-height: 3rem;
}

#view-settings [data-type="list"] .fb-item aside {
width: 6.5rem;
height: 6rem;
height: 5rem;
pointer-events: none;
position: absolute;
top: 0;
top: 1rem;
right: 0;
}

Expand Down Expand Up @@ -682,7 +687,8 @@ gaia-header [data-icon] {
margin-top: 1rem;
}

#sources > li {
#sources > li,
#contactsManagement > li {
border-bottom: none;
height: auto;
}
Expand Down
Binary file modified apps/communications/contacts/style/images/f_logo@1.5x.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified apps/communications/contacts/style/images/sync_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified apps/communications/contacts/style/images/sync_icon@1.5x.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified apps/communications/contacts/style/images/sync_icon@2.25x.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified apps/communications/contacts/style/images/sync_icon@2x.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 2 additions & 7 deletions shared/locales/import_contacts/import_contacts.ar.properties
Expand Up @@ -33,10 +33,5 @@ genericProgress = {{current}}/{{total}}

# Facebook import
facebook = فيسبوك
facebook-import-msg = {[ plural(imported) ]}
facebook-import-msg[zero] = لم يتم استيراد أي صديق من ({{total}})
facebook-import-msg[one] = تم استيراد صديق واحد (من {{total}})
facebook-import-msg[two] = تم استيراد {{imported}}/{{total}} أصدقاء
facebook-import-msg[few] = تم استيراد {{imported}}/{{total}} أصدقاء
facebook-import-msg[many] = تم استيراد {{imported}}/{{total}} أصدقاء
facebook-import-msg[other] = تم استيراد {{imported}}/{{total}} أصدقاء
facebook-import-msg2 = تم استيراد {{imported}}/{{total}} أ

Expand Up @@ -35,13 +35,7 @@ genericProgress = {{current}}/{{total}}

# Facebook import
facebook = Facebook
facebook-import-msg = {[ plural(imported) ]}
facebook-import-msg[zero] = No friends imported (out of {{total}})
facebook-import-msg[one] = One friend imported (out of {{total}})
facebook-import-msg[two] = {{imported}}/{{total}} friends imported
facebook-import-msg[few] = {{imported}}/{{total}} friends imported
facebook-import-msg[many] = {{imported}}/{{total}} friends imported
facebook-import-msg[other] = {{imported}}/{{total}} friends imported
facebook-import-msg2 = {{imported}}/{{total}} friends imported

contactsMerged = {[ plural(numDups) ]}
contactsMerged[zero] = No duplicated contacts merged
Expand Down
8 changes: 1 addition & 7 deletions shared/locales/import_contacts/import_contacts.fr.properties
Expand Up @@ -34,10 +34,4 @@ genericProgress = {{current}}/{{total}}

# Facebook import
facebook = Facebook
facebook-import-msg = {[ plural(imported) ]}
facebook-import-msg[zero] = Aucun ami importé (sur {{total}})
facebook-import-msg[one] = Un ami importé (sur {{total}})
facebook-import-msg[two] = {{imported}}/{{total}} amis importés
facebook-import-msg[few] = {{imported}}/{{total}} amis importés
facebook-import-msg[many] = {{imported}}/{{total}} amis importés
facebook-import-msg[other] = {{imported}}/{{total}} amis importés
facebook-import-msg2 = {{imported}}/{{total}} amis importés
Expand Up @@ -34,10 +34,4 @@ genericProgress = {{current}}/{{total}}

# Facebook import
facebook = Facebook
facebook-import-msg = {[ plural(imported) ]}
facebook-import-msg[zero] = 未匯入朋友(共 {{total}} 位)
facebook-import-msg[one] = 已匯入 1 位朋友(共 {{total}} 位)
facebook-import-msg[two] = 已匯入 {{imported}}/{{total}} 位朋友
facebook-import-msg[few] = 已匯入 {{imported}}/{{total}} 位朋友
facebook-import-msg[many] = 已匯入 {{imported}}/{{total}} 位朋友
facebook-import-msg[other] = 已匯入 {{imported}}/{{total}} 位朋友
facebook-import-msg2 = 已匯入 {{imported}}/{{total}} 位朋友

0 comments on commit 5104717

Please sign in to comment.