Skip to content

Commit cd1ccb7

Browse files
committed
[refactor] package name change
1 parent c9721a8 commit cd1ccb7

27 files changed

+106
-119
lines changed

.github/workflows/npm-publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030

3131
- name: Publish to NPM
3232
run: |
33-
cd dist/ngx-simple-datatable
33+
cd dist/ngx-simple-datatables
3434
npm publish --access public
3535
env:
3636
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}

README.md

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,7 @@
22

33
A lightweight, high-performance Angular data table component with features like virtual scrolling, column freezing, and customizable templates.
44

5-
6-
7-
![NgxSimpleDatatable Screenshot](projects/ngx-simple-datatable/assets/image.png)
5+
![NgxSimpleDatatable Screenshot](projects/ngx-simple-datatables/assets/image.png)
86

97
## Features
108

@@ -41,13 +39,13 @@ export class AppModule {}
4139
2. Use the component in your template:
4240

4341
```html
44-
<ngx-simple-datatable
42+
<ngx-simple-datatables
4543
[columns]="columns"
4644
[data]="data"
4745
[rowHeight]="40"
4846
[headerHeight]="50"
4947
>
50-
</ngx-simple-datatable>
48+
</ngx-simple-datatables>
5149
```
5250

5351
3. Define your columns and data in your component:
@@ -136,7 +134,7 @@ columns: ColumnConfig[] = [
136134
Use Angular templates to customize cell content:
137135

138136
```html
139-
<ngx-simple-datatable [columns]="columns" [data]="data">
137+
<ngx-simple-datatables [columns]="columns" [data]="data">
140138
<ng-template #cellTemplate let-row="row" let-column="column">
141139
<ng-container [ngSwitch]="column.field">
142140
<ng-container *ngSwitchCase="'status'">
@@ -152,23 +150,23 @@ Use Angular templates to customize cell content:
152150
<ng-container *ngSwitchDefault> {{ row[column.field] }} </ng-container>
153151
</ng-container>
154152
</ng-template>
155-
</ngx-simple-datatable>
153+
</ngx-simple-datatables>
156154
```
157155

158156
### Custom Header Templates
159157

160158
Customize header appearance and behavior:
161159

162160
```html
163-
<ngx-simple-datatable [columns]="columns" [data]="data">
161+
<ngx-simple-datatables [columns]="columns" [data]="data">
164162
<ng-template #headerTemplate let-column="column">
165163
<div class="custom-header">
166164
<i class="fas fa-info-circle" [title]="column.header"></i>
167165
<span>{{ column.header }}</span>
168166
<i class="fas fa-sort" *ngIf="column.sortable"></i>
169167
</div>
170168
</ng-template>
171-
</ngx-simple-datatable>
169+
</ngx-simple-datatables>
172170
```
173171

174172
### Theming
@@ -265,17 +263,17 @@ You can customize the table appearance by overriding the following CSS custom pr
265263

266264
## Development
267265

268-
Run `ng build ngx-simple-datatable` to build the library. The build artifacts will be stored in the `dist/` directory.
266+
Run `ng build ngx-simple-datatables` to build the library. The build artifacts will be stored in the `dist/` directory.
269267

270268
## Publishing
271269

272-
After building your library with `ng build ngx-simple-datatable`, go to the dist folder `cd dist/ngx-simple-datatable` and run `npm publish`.
270+
After building your library with `ng build ngx-simple-datatables`, go to the dist folder `cd dist/ngx-simple-datatables` and run `npm publish`.
273271

274-
After building your library with `ng build ngx-simple-datatable`, go to the dist folder `cd dist/ngx-simple-datatable` and run `npm publish`.
272+
After building your library with `ng build ngx-simple-datatables`, go to the dist folder `cd dist/ngx-simple-datatables` and run `npm publish`.
275273

276274
## Running unit tests
277275

278-
Run `ng test ngx-simple-datatable` to execute the unit tests via [Karma](https://karma-runner.github.io).
276+
Run `ng test ngx-simple-datatables` to execute the unit tests via [Karma](https://karma-runner.github.io).
279277

280278
## Further help
281279

angular.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,31 +3,31 @@
33
"version": 1,
44
"newProjectRoot": "projects",
55
"projects": {
6-
"ngx-simple-datatable": {
6+
"ngx-simple-datatables": {
77
"projectType": "library",
8-
"root": "projects/ngx-simple-datatable",
9-
"sourceRoot": "projects/ngx-simple-datatable/src",
8+
"root": "projects/ngx-simple-datatables",
9+
"sourceRoot": "projects/ngx-simple-datatables/src",
1010
"prefix": "lib",
1111
"architect": {
1212
"build": {
1313
"builder": "@angular-devkit/build-angular:ng-packagr",
1414
"options": {
15-
"project": "projects/ngx-simple-datatable/ng-package.json"
15+
"project": "projects/ngx-simple-datatables/ng-package.json"
1616
},
1717
"configurations": {
1818
"production": {
19-
"tsConfig": "projects/ngx-simple-datatable/tsconfig.lib.prod.json"
19+
"tsConfig": "projects/ngx-simple-datatables/tsconfig.lib.prod.json"
2020
},
2121
"development": {
22-
"tsConfig": "projects/ngx-simple-datatable/tsconfig.lib.json"
22+
"tsConfig": "projects/ngx-simple-datatables/tsconfig.lib.json"
2323
}
2424
},
2525
"defaultConfiguration": "production"
2626
},
2727
"test": {
2828
"builder": "@angular-devkit/build-angular:karma",
2929
"options": {
30-
"tsConfig": "projects/ngx-simple-datatable/tsconfig.spec.json",
30+
"tsConfig": "projects/ngx-simple-datatables/tsconfig.spec.json",
3131
"polyfills": [
3232
"zone.js",
3333
"zone.js/testing"

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
2-
"name": "ngx-simple-datatable-workspace",
2+
"name": "ngx-simple-datatables-workspace",
33
"version": "1.17.0",
44
"scripts": {
55
"ng": "ng",
66
"start": "ng serve",
7-
"start:lib": "ng build ngx-simple-datatable --watch",
8-
"build:lib": "ng build ngx-simple-datatable",
7+
"start:lib": "ng build ngx-simple-datatables --watch",
8+
"build:lib": "ng build ngx-simple-datatables",
99
"build": "ng build",
1010
"watch": "ng build --watch --configuration development",
1111
"test": "ng test",

projects/example-app/src/app/app.component.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<div class="app-container">
22
<h1>Dynamic Table Example</h1>
33
<div class="table-wrapper">
4-
<ngx-simple-datatable [columns]="columns" [data]="data" [rowHeight]="26" [headerHeight]="26">
4+
<ngx-simple-datatables [columns]="columns" [data]="data" [rowHeight]="26" [headerHeight]="26">
55
<ng-template #headerTemplate let-column="column">
66

77
<span class="custom-header">{{ column?.header }}</span>
@@ -22,7 +22,7 @@ <h1>Dynamic Table Example</h1>
2222
</div>
2323

2424
</ng-template>
25-
</ngx-simple-datatable>
25+
</ngx-simple-datatables>
2626

2727
</div>
2828
</div>

projects/example-app/src/app/app.component.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
import { Component } from "@angular/core";
22
import { RouterOutlet } from "@angular/router";
3-
import { NgxSimpleDatatableComponent } from "ngx-simple-datatable";
4-
import { ColumnConfig } from "../../../ngx-simple-datatable/src/interfaces/column-config.interface";
3+
import { ColumnConfig } from "../../../ngx-simple-datatables/src/interfaces/column-config.interface";
54
import { CommonModule } from "@angular/common";
5+
import { NgxSimpleDatatablesComponent } from "../../../ngx-simple-datatables/src/public-api";
66

77
@Component({
88
selector: "app-root",
99
standalone: true,
10-
imports: [NgxSimpleDatatableComponent, CommonModule],
10+
imports: [NgxSimpleDatatablesComponent, CommonModule],
1111
templateUrl: "./app.component.html",
1212
styleUrl: "./app.component.css",
1313
})

projects/ngx-simple-datatable/src/lib/ngx-simple-datatable.component.spec.ts

Lines changed: 0 additions & 23 deletions
This file was deleted.

projects/ngx-simple-datatable/src/lib/ngx-simple-datatable.service.spec.ts

Lines changed: 0 additions & 16 deletions
This file was deleted.

projects/ngx-simple-datatable/src/lib/ngx-simple-datatable.service.ts

Lines changed: 0 additions & 9 deletions
This file was deleted.

0 commit comments

Comments
 (0)