@tipolox/litgrid-angular 1.0.0 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +49 -0
  2. package/package.json +2 -2
package/README.md ADDED
@@ -0,0 +1,49 @@
1
+ # @tipolox/litgrid-angular
2
+
3
+ Angular integration for LitGrid's `yc-grid` Web Component. The standalone `DataGridComponent` provides Angular inputs, typed outputs, and an imperative component API. The Web Component dependency is included.
4
+
5
+ ## Install
6
+
7
+ ```bash
8
+ npm install @tipolox/litgrid-angular
9
+ ```
10
+
11
+ Requires Angular 17 or later (`@angular/core` and `@angular/common` peers: `>=17.0.0`). Use a modern browser with native Web Component support and a bundler that supports ECMAScript modules.
12
+
13
+ ## Quick start
14
+
15
+ ```ts
16
+ import { Component } from '@angular/core'
17
+ import { DataGridComponent } from '@tipolox/litgrid-angular'
18
+ import type { GridColumn } from '@tipolox/litgrid-angular'
19
+
20
+ @Component({
21
+ selector: 'app-users-grid',
22
+ standalone: true,
23
+ imports: [DataGridComponent],
24
+ template: `
25
+ <litgrid-data-grid [data]="data" [columns]="columns" [height]="400" />
26
+ `
27
+ })
28
+ export class UsersGridComponent {
29
+ readonly data = [
30
+ { id: 1, name: 'Ada' },
31
+ { id: 2, name: 'Grace' }
32
+ ]
33
+ readonly columns: GridColumn[] = [
34
+ { key: 'id', header: 'ID', width: 80 },
35
+ { key: 'name', header: 'Name', width: 180 }
36
+ ]
37
+ }
38
+ ```
39
+
40
+ Import `UsersGridComponent` into your application's standalone component and render `<app-users-grid />`. `height` defines the viewport used for row virtualization.
41
+
42
+ ## Resources
43
+
44
+ - [Live demo](https://tipolox.com/litgrid/demo)
45
+ - [Repository](https://github.com/tipolox/litgrid)
46
+ - [Angular guide](https://github.com/tipolox/litgrid/blob/main/docs/angular-guide.md)
47
+ - [API reference](https://github.com/tipolox/litgrid/blob/main/docs/api-reference.md)
48
+
49
+ Licensed under the [MIT License](https://github.com/tipolox/litgrid/blob/main/LICENSE).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tipolox/litgrid-angular",
3
- "version": "1.0.0",
3
+ "version": "1.0.2",
4
4
  "description": "Angular wrapper for LitGrid",
5
5
  "sideEffects": true,
6
6
  "peerDependencies": {
@@ -8,7 +8,7 @@
8
8
  "@angular/core": ">=17.0.0"
9
9
  },
10
10
  "dependencies": {
11
- "@tipolox/litgrid-web": "^1.0.0",
11
+ "@tipolox/litgrid-web": "^1.0.2",
12
12
  "tslib": "^2.8.1"
13
13
  },
14
14
  "keywords": [