SAP / spartacus

Spartacus is a lean, Angular-based JavaScript storefront for SAP Commerce Cloud that communicates exclusively through the Commerce REST API.
Apache License 2.0
740 stars 386 forks source link

[in code review but...] Ability to "...see more" on product descriptions on tabs #8086

Open temitopeog opened 4 years ago

temitopeog commented 4 years ago

Is your feature request related to a problem? Please describe. The ability to cut down a very long description on all product tabs so a user wouldnt have to go through a long description of texts before they reach the next tab.

Describe the solution you'd like The user can choose to "...see more" of the product description or just scroll down to the next tab

Describe alternatives you've considered None

Additional context Related to https://github.com/SAP/spartacus/issues/7629

Expected

Display a preview of the product description to the user. Prompt the show more button to allow them to fully expand the description.

Short descriptions (400 characters or less), won't render the show more button.

QA Steps

Visit product details for the following item: http://localhost:4200/electronics-spa/en/USD/Open-Catalogue/Cameras/DigitalCameras/Digital-Compacts/NV10/p/553637

  1. Click show more to view full content.

    preview1 preview2
  2. Test items with short descriptions http://localhost:4200/electronics-spa/en/USD/product/300938/Photosmart%20E317%20Digital%20Camera

Xymmer commented 3 years ago

This was in code review but never finished, it's been a while so let's finish this in 3.x

ren-tham commented 3 years ago

PR: (#9952 ). I used a different approach and didn't reuse a lot of the code found in branch feature/GH-8086. I've closed the PR associated with it.