← DataGrid API

Component · v2.7.1

NgbDataGridViewsComponent

Explicit, application-owned persistence; grid changes are never saved automatically.

Import

import { NgbDataGridViewsComponent } from '@angular-bootstrap/ngbootstrap';

Selector:ngb-datagrid-views

Declaration

class NgbDataGridViewsComponent implements OnDestroy

Inputs

grid

grid: Datagrid

storageKey

Namespace by grid, user and tenant. Required even for an in-memory collection.

storageKey: string

store

Properties

selector

selector?: ElementRef<HTMLSelectElement>

nameField

set nameField(value: ElementRef<HTMLInputElement> | undefined)

views

readonly views: i0.WritableSignal<NgbDataGridSavedView[]>

selected

readonly selected: i0.WritableSignal<string>

ready

readonly ready: i0.WritableSignal<boolean>

busy

readonly busy: i0.WritableSignal<boolean>

dirty

readonly dirty: i0.WritableSignal<boolean>

mode

readonly mode: i0.WritableSignal<"save" | "rename" | null>

confirmDelete

readonly confirmDelete: i0.WritableSignal<boolean>

message

readonly message: i0.WritableSignal<string>

error

readonly error: i0.WritableSignal<string>

name

name: string

Default:''

Methods

selectedView

selectedView(): NgbDataGridSavedView | undefined

begin

begin(mode: 'save' | 'rename'): void

cancel

cancel(): void

selectView

selectView(id: string): void

reset

reset(): void

saveName

saveName(): Promise<void>

update

update(): Promise<void>

remove

remove(): Promise<void>

Referenced types

Source: src/datagrid/src/views/datagrid-views.component.ts in the installed @angular-bootstrap/ngbootstrap package. Angular compiler metadata and private members are omitted.

This project is not affiliated with ng-bootstrap or ngx-bootstrap. Those projects focus mainly on Bootstrap components for Angular. ngbootstrap focuses on Angular UI for data-heavy apps, especially Data Grid, Angular-native Form Builder, drag and drop workflows, documentation examples, and performance-focused Angular patterns.