npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

svng-shopping-cart

v0.0.3

Published

```bash import {ShoppingCartModule} from 'svng-shopping-cart'; ``` ###Include in module Section ```bash imports: [ .... ShoppingCartModule ] ``` ###Selector ```bash <app-svsudo-shopping-cart></app-svsudo-shopping-cart> ``` ###Input Parameters ```b

Downloads

11

Readme

#Shopping Cart Angular UI component ###Module

import {ShoppingCartModule} from 'svng-shopping-cart';

###Include in module Section

imports: [
    ....
    ShoppingCartModule
]

###Selector

<app-svsudo-shopping-cart></app-svsudo-shopping-cart>

###Input Parameters

    title: string -> Title on the top of page.
    subtitle: string -> subtitle to be shown.
    continueLabel: string - button label for continue shopping
    showShadowForProduct: boolean -> decide weather to background shadow for each product in the list.
    showShadowForMainContent: boolean -> decide weather to background shadow for main section of page.
    currency: string -> what type of currency using for this cart list.
    shippingCost: number -> Shipping cost for a particular place.
    taxPercentage: number -> total tax percentage for customers.
    checkOutLabel: string ->  label for checkout button.
    messageForNoItems: string -> Message to show when the cart dont have any selected products.
    productList: Array of product Objects -> List of products selected by customer. (Each Product should have minimum of values mentioned in Product structure section in this readme file).

###Each Product Structure.

    id: string -> Unique value for each selected product.
    name: string -> Name of product.
    selectedItemCount: number -> User Selected same product count.
    costPerItem: number -> Cost of each selected product.
    stockStatus: 'IN'/'OUT' -> Weather the stock exist or not. (Please use the enum mentioned below for stockstatus).
    imgURL: string -> Use either http URL or relative Path.

###STOCK_STATUS enum import

    import {STOCK_STATUS} from 'shopping-cart-angular-ui';

###STOCK_STATUS enum Usage

    Use any of the following value
    STOCK_STATUS.IN -> The products which are in stock.
    STOCK_STATUS.OUT -> The products which are out of stock.

###Output Parameters

continue: void -> Event emitted when user clicks on contine button.
checkout -> Event Emitted when user clicks on checkout button with all the updated data as mentioned is checkout emitted info section below.

###Checkout-emitted-info

    productList: Holds list of products with updated values.
    subTotal: Holds sub-total of all products excluding tax and shipping
    totoalCost: Holds totoal cost of all products including sub-total, shipping, tax.
    totalTax: Holds the tax value on total bill not in percentage.

###Example Usage

    <app-svsudo-shopping-cart 
            title="Shopping cart name" 
            subtitle="sub title"
            continueLabel="contine Shopping"
            showShadowForProduct="true"
            showShadowForMainContent="true"
            currency="$"
            shippingCost="50"
            taxPercentage="5"
            checkOutLabel="checkout"
            messageForNoItems="No Items in cart"
            [productList]="productList"
            (checkout)="checkout($event)"
            (continue)="continue($event)"></app-svsudo-shopping-cart>
    Emitted checkout and continue button events should be handled by developer in there respective components.

###Sample Output sample_shopping_cart

###Note

    1. Need to include bootstrap cdn in your application index.html. 
      <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
    2. By default fonts of all the lables will be as per your application defaults. If you want to use same fonts as in the screenshot Please include following cdn in your application index.html

     <link href="https://fonts.googleapis.com/css?family=Montserrat:100,100i,200,200i,300,300i,400,400i,500,500i,600,600i,700,700i,900|Roboto:100,100i,300,300i,400,400i,500,500i,700,700i,900,900i|Stylish&display=swap"
    rel="stylesheet"> 

    and also include following css in application or global level css
    body { 
        margin: 0; 
        font-family: 'Montserrat', sans-serif;
        font-family: 'Roboto', sans-serif; 
        font-family: 'Stylish', sans-serif;
    }