Skip to content

Commit

Permalink
chore: clean up obsolete html comments and removed unused localizatio…
Browse files Browse the repository at this point in the history
…n keys

BREAKING CHANGES: Removed unused newsletter localization keys.
  • Loading branch information
shauke committed May 20, 2022
1 parent 95d0a71 commit 652195e
Show file tree
Hide file tree
Showing 11 changed files with 24 additions and 105 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ describe('Changing User', () => {
page.fillForm(_.user.login, _.user.password).submit().its('response.statusCode').should('equal', 200)
);
at(ProfilePage, page => {
page.name.should('have.text', `${_.user.firstName} ${_.user.lastName}`);
page.phone.should('have.text', _.user.phoneHome);
page.companyName.should('have.text', _.user.companyName1);
page.name.should('contain', `${_.user.firstName} ${_.user.lastName}`);
page.phone.should('contain', _.user.phoneHome);
page.companyName.should('contain', _.user.companyName1);
page.taxationId.should('be.empty');
});
});
Expand All @@ -37,8 +37,8 @@ describe('Changing User', () => {
page.fillForm(_.newDetails).submit().its('response.statusCode').should('equal', 200)
);
at(ProfilePage, page => {
page.companyName.should('have.text', `${_.newDetails.companyName}${_.newDetails.companyName2}`);
page.taxationId.should('have.text', _.newDetails.taxationID);
page.companyName.should('contain', `${_.newDetails.companyName}${_.newDetails.companyName2}`);
page.taxationId.should('contain', _.newDetails.taxationID);
});
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ describe('Changing User', () => {
);

at(ProfilePage, page => {
page.name.should('have.text', `${_.user.firstName} ${_.user.lastName}`);
page.phone.should('have.text', _.user.phoneHome);
page.name.should('contain', `${_.user.firstName} ${_.user.lastName}`);
page.phone.should('contain', _.user.phoneHome);
});
});

Expand All @@ -38,8 +38,8 @@ describe('Changing User', () => {
);
at(ProfilePage, page => {
page.header.myAccountLink.should('have.text', `${_.newDetails.firstName} ${_.newDetails.lastName}`);
page.name.should('have.text', `${_.newDetails.title} ${_.newDetails.firstName} ${_.newDetails.lastName}`);
page.phone.should('have.text', _.newDetails.phoneHome);
page.name.should('contain', `${_.newDetails.title} ${_.newDetails.firstName} ${_.newDetails.lastName}`);
page.phone.should('contain', _.newDetails.phoneHome);
});
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -82,15 +82,6 @@
<td *ngFor="let product of visibleProducts">{{ product.manufacturer }}</td>
</tr>

<!-- TODO: Manufacturer SKU
<tr>
<th>{{'product.manufacturer_sku.label' | translate}}
</th>
<td *ngFor="let product of visibleProducts">
</td>
</tr>
-->

<tr *ngFor="let commonAttributeName of commonAttributeNames$ | async">
<th>{{ commonAttributeName }}</th>
<td *ngFor="let product of visibleProducts">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,7 @@

<div *ngIf="displayTotal$ | async" class="clearfix section">
<div class="row justify-content-end list-body">
<!-- TODO: remove style attribute -->
<div class="col-sm-4 col-md-3 col-lg-2 text-right pr-0">{{ 'quote.items.total.label' | translate }}</div>
<!-- TODO: remove style attribute -->
<div class="col-sm-4 col-md-2 pr-0">
<div class="total-price text-right">{{ total$ | async | ishPrice }}</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<h1>{{ 'account.profile.heading' | translate }}</h1>

<!-- Email Template -->
<!-- Email -->
<div class="row section">
<div class="col-10 col-lg-8">
<h3>{{ 'account.profile.email.heading' | translate }}</h3>
Expand All @@ -9,20 +9,6 @@ <h3>{{ 'account.profile.email.heading' | translate }}</h3>
<dl class="row dl-horizontal dl-separator">
<dt class="col-md-4">{{ 'account.profile.email.label' | translate }}</dt>
<dd class="col-md-8" data-testing-id="email-field">{{ user.email }}</dd>
<!-- TODO: implement logic (extend REST response) to present email subscriptions
cSpell: disable
<dt>{{'account.profile.order_confirmation_subscription.text' | translate}}</dt>
<dd>
<isif condition="#Preferences:OrderConfirmationEmails#">
{{'account.profile.order_confirmation_email.text' | translate}}&nbsp;
</isif>
<isif condition="#isDefined(ReceiveNewsletters) AND ReceiveNewsletters#">
{{'account.profile.newsletter.text' | translate}}
</isif>
</dd>
cSpell: enable
-->
</dl>
</div>
</div>
Expand All @@ -40,7 +26,7 @@ <h3>{{ 'account.profile.email.heading' | translate }}</h3>
</div>
</div>

<!-- Password Template -->
<!-- Password -->
<div class="row section" *ishIdentityProviderCapability="'editPassword'">
<div class="col-10 col-lg-8">
<h3>{{ 'account.profile.password.heading' | translate }}</h3>
Expand Down Expand Up @@ -72,10 +58,9 @@ <h3>{{ 'account.company_profile.detail.heading' | translate }}</h3>
<div class="col-md-12">
<dl class="row dl-horizontal dl-separator">
<dt class="col-md-4">{{ 'account.company_profile.name.label' | translate }}</dt>
<!-- display: inline -->
<dd class="col-md-8" data-testing-id="company-field"
>{{ customer.companyName }}<br />{{ customer.companyName2 }}</dd
>
<dd class="col-md-8" data-testing-id="company-field">
{{ customer.companyName }}<br />{{ customer.companyName2 }}
</dd>
<ng-container *ngIf="customer.industry">
<dt class="col-md-4">{{ 'account.company_profile.industry.label' | translate }}</dt>
<dd class="col-md-8">{{ customer.industry }}</dd>
Expand All @@ -99,27 +84,26 @@ <h3>{{ 'account.company_profile.detail.heading' | translate }}</h3>
</div>
</div>

<!-- Profile Template -->
<!-- Profile -->
<div class="row section">
<div class="col-10 col-lg-8">
<h3>{{ 'account.profile.detail.heading' | translate }}</h3>
<div class="row">
<div class="col-md-12">
<dl class="row dl-horizontal dl-separator">
<dt class="col-md-4">{{ 'account.profile.name.label' | translate }}</dt>
<!-- display: inline -->
<dd class="col-md-8" data-testing-id="name-field"
>{{ user.title ? user.title + ' ' : '' }}{{ user.firstName }} {{ user.lastName }}</dd
>
<dd class="col-md-8" data-testing-id="name-field">
{{ user.title ? user.title + ' ' : '' }}{{ user.firstName }} {{ user.lastName }}
</dd>
<!-- Phone -->
<dt class="col-md-4">{{ 'account.profile.phone.label' | translate }}</dt>
<dd class="col-md-8" data-testing-id="phone-field">{{ user.phoneHome }}</dd>

<!-- Birthday
<dt class="col-md-4">{{ 'account.profile.birthday.label' | translate }}</dt>
<dd class="col-md-8" data-testing-id="birthday-field">{{
user.birthday ? (user.birthday | ishDate) : ('account.profile.birthday.not_available' | translate)
}}</dd>
<dd class="col-md-8" data-testing-id="birthday-field">
{{ user.birthday ? (user.birthday | ishDate) : ('account.profile.birthday.not_available' | translate) }}
</dd>
-->
</dl>
</div>
Expand All @@ -138,32 +122,6 @@ <h3>{{ 'account.profile.detail.heading' | translate }}</h3>
</div>
</div>

<!-- Newsletter Template -->
<!--
cSpell: disable-next-line
TODO: Newsletter configuration currently not available via REST API, need to get information for <isif condition="#isDefined(ReceiveNewsletters) AND ReceiveNewsletters#"><istext key="account.newsletter.subscribed"/><iselse> <istext key="account.newsletter.unsubscribed"/></isif>
<div class="row section">
<div class="col-10 col-lg-8">
<h3>{{'account.newsletter.label' | translate}}</h3>
<div class="row">
<div class="col-md-12">
<dl class="row">
<dt class="col-md-4">{{'account.newsletter.label' | translate}}</dt>
<dd class="col-md-8">
</dd>
</dl>
</div>
</div>
</div>
<div class="col-2 col-lg-4">
<a class="btn-tool" title="{{'account.profile.update.link' | translate}}">
<fa-icon [icon]="['fas', 'pencil-alt']"></fa-icon>
</a>
</div>
</div>
-->

<!-- Note -->
<p class="form-text">
{{ 'account.overview.note.heading' | translate }}:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
<!-- NOTE:
For the PWA the 'app_sf_base_cm:pagevariant.standard.pagelet2-Pagevariant' model only renders the content of the 'content' slot.
'header' and 'footer' slot content is not relevant for the PWA while the content of the Responsive Starter Store is reused.
-->
<ish-content-slot
[slot]="'app_sf_base_cm:slot.pagevariant.content.pagelet2-Slot'"
[pagelet]="pagelet"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@

<div *ngIf="total?.value && lineItems.length > 0" class="clearfix section">
<div class="row justify-content-end list-body">
<!-- TODO: remove style attribute -->
<div class="col-sm-4 col-md-3 col-lg-2 text-right pr-0">{{ 'quote.items.total.label' | translate }}</div>
<!-- TODO: remove style attribute -->
<div class="col-sm-4 col-md-2 pr-0">
<div class="total-price text-right">{{ total | ishPrice }}</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
<ng-container *ngIf="visible$ | async">
<ul>
<!-- display: inline -->
<li *ngFor="let item of parts$ | async"
>{{ item.quantity }} x <ish-product-name ishProductContext [sku]="item.sku" [link]="false"></ish-product-name
></li>
<li *ngFor="let item of parts$ | async">
{{ item.quantity }} x <ish-product-name ishProductContext [sku]="item.sku" [link]="false"></ish-product-name>
</li>
</ul>
</ng-container>
7 changes: 0 additions & 7 deletions src/assets/i18n/de_DE.json
Original file line number Diff line number Diff line change
Expand Up @@ -189,9 +189,6 @@
"account.navigation.logout.link": "Abmelden",
"account.navigation.quotes.link": "Preisangebote",
"account.new_user.heading": "Neue Benutzer",
"account.newsletter.label": "Newsletter",
"account.newsletter.subscribed": "Abonniert",
"account.newsletter.unsubscribed": "Nicht abonniert",
"account.option.select.text": "Bitte auswählen",
"account.order.most_recent.heading": "Letzte Bestellungen",
"account.order.questions.note": "Besuchen Sie die <a href=\"{{0}}\">Hilfe</a> auf unserer Website für umfassende Bestell- und Versandinformationen oder <a href=\"{{1}}\">kontaktieren Sie uns</a> rund um die Uhr.",
Expand Down Expand Up @@ -296,9 +293,6 @@
"account.profile.heading": "Profileinstellungen",
"account.profile.link": "Profileinstellungen",
"account.profile.name.label": "Name",
"account.profile.newsletter.text": "Newsletter",
"account.profile.order_confirmation_email.text": "Bestellbestätigungs-E-Mails",
"account.profile.order_confirmation_subscription.text": "Aktuelle Abonnements",
"account.profile.password.heading": "Kennwort",
"account.profile.password.label": "Kennwort",
"account.profile.phone.label": "Telefon",
Expand Down Expand Up @@ -857,7 +851,6 @@
"product.itemNumber.label": "Artikelnummer:",
"product.items.label": "{{0, plural, one{# Element} other{# Elemente}}}",
"product.manufacturer_name.label": "Herstellername",
"product.manufacturer_sku.label": "Hersteller-SKU",
"product.out_of_stock.text": "Nicht verfügbar",
"product.price.listPriceFallback.text": "{{0}}",
"product.price.na.text": "k. A.",
Expand Down
7 changes: 0 additions & 7 deletions src/assets/i18n/en_US.json
Original file line number Diff line number Diff line change
Expand Up @@ -189,9 +189,6 @@
"account.navigation.logout.link": "Logout",
"account.navigation.quotes.link": "Quoting",
"account.new_user.heading": "New Users",
"account.newsletter.label": "Newsletter",
"account.newsletter.subscribed": "Subscribed",
"account.newsletter.unsubscribed": "Not Subscribed",
"account.option.select.text": "Please select",
"account.order.most_recent.heading": "Most Recent Orders",
"account.order.questions.note": "Please visit the <a href=\"{{0}}\">Help</a> area of our website for comprehensive order and shipping information or <a href=\"{{1}}\">Contact Us</a> 24 hours a day.",
Expand Down Expand Up @@ -296,9 +293,6 @@
"account.profile.heading": "Profile Settings",
"account.profile.link": "Profile Settings",
"account.profile.name.label": "Name",
"account.profile.newsletter.text": "Newsletter E-mails",
"account.profile.order_confirmation_email.text": "Order Confirmation E-mails",
"account.profile.order_confirmation_subscription.text": "Current Subscriptions",
"account.profile.password.heading": "Password",
"account.profile.password.label": "Password",
"account.profile.phone.label": "Phone",
Expand Down Expand Up @@ -857,7 +851,6 @@
"product.itemNumber.label": "Product ID:",
"product.items.label": "{{0, plural, one{# list item} other{# list items}}}",
"product.manufacturer_name.label": "Manufacturer Name",
"product.manufacturer_sku.label": "Manufacturer SKU",
"product.out_of_stock.text": "Out of Stock",
"product.price.listPriceFallback.text": "{{0}}",
"product.price.na.text": "N/A",
Expand Down
7 changes: 0 additions & 7 deletions src/assets/i18n/fr_FR.json
Original file line number Diff line number Diff line change
Expand Up @@ -189,9 +189,6 @@
"account.navigation.logout.link": "Déconnexion",
"account.navigation.quotes.link": "Devis",
"account.new_user.heading": "Nouveaux utilisateurs",
"account.newsletter.label": "Newsletter",
"account.newsletter.subscribed": "Abonné",
"account.newsletter.unsubscribed": "Non abonné",
"account.option.select.text": "Veuillez sélectionner",
"account.order.most_recent.heading": "Les commandes les plus récentes",
"account.order.questions.note": "Merci de consulter la section <a href=\"{{0}}\">Aide</a> de notre site Web pour des renseignements détaillés sur votre commande et l’expédition ou <a href=\"{{1}}\">Contactez-nous</a> 24 heures sur 24.",
Expand Down Expand Up @@ -296,9 +293,6 @@
"account.profile.heading": "Paramètres de profil",
"account.profile.link": "Paramètres de profil",
"account.profile.name.label": "Nom",
"account.profile.newsletter.text": "Courriels newsletter",
"account.profile.order_confirmation_email.text": "Courriels de confirmation de commande",
"account.profile.order_confirmation_subscription.text": "Abonnements actuels",
"account.profile.password.heading": "Mot de passe",
"account.profile.password.label": "Mot de passe",
"account.profile.phone.label": "Téléphone",
Expand Down Expand Up @@ -857,7 +851,6 @@
"product.itemNumber.label": "ID produit :",
"product.items.label": "{{0, plural, one{# article} other{# articles}}}",
"product.manufacturer_name.label": "Nom du fabricant",
"product.manufacturer_sku.label": "UGS du fabricant",
"product.out_of_stock.text": "Stock épuisé",
"product.price.listPriceFallback.text": "{{0}}",
"product.price.na.text": "n.c.",
Expand Down

0 comments on commit 652195e

Please sign in to comment.