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 🙏

© 2025 – Pkg Stats / Ryan Hefner

tufud-material

v1.0.0

Published

shared components library to use in tufud.co

Downloads

46

Readme

Tufud Material Components

tf-header

  • Input quantity: number | undefined Output quantityEmitter
  • Input cartIcon: boolean (show/hide cart button | default: true)
  • Input shoppingCartAmount: string
  • Input header (menu list with options and routes added as array of {name:string, route:string})
  • Input usernameboxDisabled: boolean
  • Output openCartEmit (cart empty emmit)
  • Output logoutEmit (logout button empty emmit) *Output() routeLink = new EventEmitter() *mandatory, emits route string. Use a method with route.navigate([event])

tf-pagination

  • Input pageSize: number
  • Input length: number
  • Input pageIndex: number
  • Input itemsQuantity: number
  • Output page = new EventEmitter() Use @ViewChild decorator to access to this component properties, example:

@ViewChild(PaginationComponent) nameOfTheInstance: PagiantionComponent

tf-minus-plus

  • Output quantityEmitter = new EventEmitter()
  • Input quantity: number

tf-table-layout

  • Input displayedColumns: TLHeader[] = [] : Array donde se ingresan todos los headers de la tabla,cada header es un objeto que tiene una propiedad column con el nombre del dato, una propiedad displayName con el nombre para mostrar y un propiedad additionalText con texto addicional que puede ser agregado condicionalmente por el componente padre.

  • Input dataSource: MatTableDataSource | any[] = []: Array donde se ingresan los datos de cada celda

  • Input actions: TLActions[] = []: Array del tipo TLActions, cada propiedad de un objteto TLActions le asigna una carácteristica especifica a cada una de las acciones que se renderizaran en la columnas de acciones o detalle

  • Input columnsWithActions: string[] = []: Array con las columnas que contendran acciones, si el nombre de la columna no está en este array no se activará el evento click sobre sus datos

  • Input currencyColumns: string[] = []: Array con las columnas en cuyos datos se debe renderizar antes el signo

  • Input() statusInfoCollection: StatusInfo[] = []: Array con las opciones de estilos de estatus variable. Si la propieded editable es true se renderiza un select con las edit_option

  • Input() noHeaderInMobileStyles: string[] = []: Array con las nombres de las columnas que no requieren headers en estilos mobile.

  • Input() showCartButton: boolean | undefined: Booleano para indicar si queremo añador el botón de carrito que utilizamos para sumar productos al carrito por ejemplo

  • Input() isQuantityModifiable: boolean | undefined: Booleano ue cuando está en true renderiza un plus-minus button para modificar cantidades que está asociado al evento quantityEvent

  • Input() nameColumnWidth: number = 0: Con este número podemos indicar el ancho de la columna name, el resto de las columnas se se repartiran el ancho de pantalla restante.

  • Output() clickEventDataEmmitter = new EventEmitter(): Emite los datos del registro asociado a ese click

  • Output() quantityEventEmmitter = new EventEmitter(): Emite los datos del registro asociado a ese click y la variación de la cantidad asociada

  • Output() statusEventEmmitter = new EventEmitter(): Emite los datos del registro asociado a los cambios en el selector y el valor nuevo del selector

tf-input

  • Input inputId?: string
  • Input inputType: TFInputType
  • Input inputLabelText?: string
  • Input inputPlaceholder?: string
  • Input formGroup?: FormGroup
  • Input formControlName: string
  • Input formControl: FormControl
  • Input required: boolean
  • Input errors?: Errors[]
  • Input showSearchIconAndSpinner?: boolean
  • Input loadingCondition?: boolean
  • Input inputWidth? : string
  • Input inputHeight?: string
  • Input containerHeight?: string

Requirements:

import { TufudMaterialLibraryModule } from 'tufud-material';

tf-header needs to have this in the project to work: import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; also needed for testing the lib. If you add it in the lib module remove it before build

tf-footer needs to add the resource path of the library in the angular.json of the application:

"assets": [
  "src/favicon.ico",
  "src/assets",
  {
    "glob": "**/*",
    "input": "node_modules/tufud-material/assets",
    "output": "tfassets"
  }
],

tf-footer You need to add the resource path of the library in the angular.json of the application:

"assets": [
  "src/favicon.ico",
  "src/assets",
  {
    "glob": "**/*",
    "input": "node_modules/tufud-material/assets",
    "output": "tfassets"
  }
],

Code scaffolding

Run ng generate component component-name --project tufud-material to generate a new component. You can also use ng generate directive|pipe|service|class|guard|interface|enum|module --project tufud-material.

Note: Don't forget to add --project tufud-material or else it will be added to the default project in your angular.json file.

Build

Run ng build tufud-material to build the project. The build artifacts will be stored in the dist/ directory.

Publishing

After building your library with ng build tufud-material, go to the dist folder cd dist/tufud-material and run npm publish.