Passa al contenuto principale

UI Components

Shared and reusable UI components across the Gauzy frontend.

Component Librariesโ€‹

LibraryPackagePurpose
Nebular@nebular/themePrimary UI framework
Angular Material@angular/materialAdditional components
Smart Tableangular2-smart-tableData tables
FullCalendar@fullcalendar/angularCalendar views
CKEditor@ckeditor/ckeditor5-angularRich text editor

Custom Componentsโ€‹

Smart Tableโ€‹

Used extensively for data grids:

settings = {
columns: {
name: { title: "Name", type: "string" },
email: { title: "Email", type: "string" },
role: { title: "Role", type: "string" },
},
actions: { add: false, edit: true, delete: true },
pager: { perPage: 10 },
};

Date/Time Pickersโ€‹

  • Nebular datepicker for date selection
  • Custom time range pickers
  • Calendar integration for scheduling

Tag Selectorsโ€‹

Multi-select tag components for:

  • Employee skills
  • Task labels
  • Project tags

Avatar & Statusโ€‹

Employee avatar components with online/offline status indicators.

Design Patternsโ€‹

Container/Presentationalโ€‹

Container Component (Smart)
โ”œโ”€โ”€ Fetches data from store/service
โ”œโ”€โ”€ Handles user interactions
โ””โ”€โ”€ Passes data to presentational components

Presentational Component (Dumb)
โ”œโ”€โ”€ Receives data via @Input()
โ”œโ”€โ”€ Emits events via @Output()
โ””โ”€โ”€ Purely visual, no service dependencies

Form Componentsโ€‹

Reactive forms with validation:

this.form = this.fb.group({
name: ["", [Validators.required, Validators.minLength(3)]],
email: ["", [Validators.required, Validators.email]],
role: ["", Validators.required],
});