ngx-st-date-format 1.0.14 → 16.0.0
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.
- package/README.md +24 -24
- package/{esm2020 → esm2022}/lib/ngx-st-date-format.module.mjs +5 -5
- package/{esm2020 → esm2022}/lib/pipes/date-format.pipe.mjs +4 -4
- package/{esm2020 → esm2022}/lib/pipes/date-time-format.pipe.mjs +4 -4
- package/{esm2020 → esm2022}/lib/pipes/time-format.pipe.mjs +4 -4
- package/{esm2020 → esm2022}/public-api.mjs +1 -1
- package/{fesm2015 → fesm2022}/ngx-st-date-format.mjs +13 -13
- package/fesm2022/ngx-st-date-format.mjs.map +1 -0
- package/package.json +7 -13
- package/fesm2015/ngx-st-date-format.mjs.map +0 -1
- package/fesm2020/ngx-st-date-format.mjs +0 -108
- package/fesm2020/ngx-st-date-format.mjs.map +0 -1
- /package/{esm2020 → esm2022}/ngx-st-date-format.mjs +0 -0
package/README.md
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
# NgxStDateFormat
|
|
2
|
-
|
|
3
|
-
This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 14.2.0.
|
|
4
|
-
|
|
5
|
-
## Code scaffolding
|
|
6
|
-
|
|
7
|
-
Run `ng generate component component-name --project ngx-st-date-format` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module --project ngx-st-date-format`.
|
|
8
|
-
> Note: Don't forget to add `--project ngx-st-date-format` or else it will be added to the default project in your `angular.json` file.
|
|
9
|
-
|
|
10
|
-
## Build
|
|
11
|
-
|
|
12
|
-
Run `ng build ngx-st-date-format` to build the project. The build artifacts will be stored in the `dist/` directory.
|
|
13
|
-
|
|
14
|
-
## Publishing
|
|
15
|
-
|
|
16
|
-
After building your library with `ng build ngx-st-date-format`, go to the dist folder `cd dist/ngx-st-date-format` and run `npm publish`.
|
|
17
|
-
|
|
18
|
-
## Running unit tests
|
|
19
|
-
|
|
20
|
-
Run `ng test ngx-st-date-format` to execute the unit tests via [Karma](https://karma-runner.github.io).
|
|
21
|
-
|
|
22
|
-
## Further help
|
|
23
|
-
|
|
24
|
-
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.io/cli) page.
|
|
1
|
+
# NgxStDateFormat
|
|
2
|
+
|
|
3
|
+
This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 14.2.0.
|
|
4
|
+
|
|
5
|
+
## Code scaffolding
|
|
6
|
+
|
|
7
|
+
Run `ng generate component component-name --project ngx-st-date-format` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module --project ngx-st-date-format`.
|
|
8
|
+
> Note: Don't forget to add `--project ngx-st-date-format` or else it will be added to the default project in your `angular.json` file.
|
|
9
|
+
|
|
10
|
+
## Build
|
|
11
|
+
|
|
12
|
+
Run `ng build ngx-st-date-format` to build the project. The build artifacts will be stored in the `dist/` directory.
|
|
13
|
+
|
|
14
|
+
## Publishing
|
|
15
|
+
|
|
16
|
+
After building your library with `ng build ngx-st-date-format`, go to the dist folder `cd dist/ngx-st-date-format` and run `npm publish`.
|
|
17
|
+
|
|
18
|
+
## Running unit tests
|
|
19
|
+
|
|
20
|
+
Run `ng test ngx-st-date-format` to execute the unit tests via [Karma](https://karma-runner.github.io).
|
|
21
|
+
|
|
22
|
+
## Further help
|
|
23
|
+
|
|
24
|
+
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.io/cli) page.
|
|
@@ -4,11 +4,11 @@ import { DateTimeFormatPipe } from './pipes/date-time-format.pipe';
|
|
|
4
4
|
import { TimeFormatPipe } from './pipes/time-format.pipe';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
6
|
export class StDateFormatModule {
|
|
7
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: StDateFormatModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
8
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: StDateFormatModule, declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe], exports: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe] }); }
|
|
9
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: StDateFormatModule }); }
|
|
7
10
|
}
|
|
8
|
-
|
|
9
|
-
StDateFormatModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: StDateFormatModule, declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe], exports: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe] });
|
|
10
|
-
StDateFormatModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: StDateFormatModule });
|
|
11
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: StDateFormatModule, decorators: [{
|
|
11
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: StDateFormatModule, decorators: [{
|
|
12
12
|
type: NgModule,
|
|
13
13
|
args: [{
|
|
14
14
|
declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],
|
|
@@ -16,4 +16,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImpor
|
|
|
16
16
|
exports: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],
|
|
17
17
|
}]
|
|
18
18
|
}] });
|
|
19
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
19
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibmd4LXN0LWRhdGUtZm9ybWF0Lm1vZHVsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3V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YXRQaXBlIH0gZnJvbSAnLi9waXBlcy90aW1lLWZvcm1hdC5waXBlJztcclxuXHJcbkBOZ01vZHVsZSh7XHJcbiAgZGVjbGFyYXRpb25zOiBbRGF0ZUZvcm1hdFBpcGUsIERhdGVUaW1lRm9ybWF0UGlwZSwgVGltZUZvcm1hdFBpcGVdLFxyXG4gIGltcG9ydHM6IFtdLFxyXG4gIGV4cG9ydHM6IFtEYXRlRm9ybWF0UGlwZSwgRGF0ZVRpbWVGb3JtYXRQaXBlLCBUaW1lRm9ybWF0UGlwZV0sXHJcbn0pXHJcbmV4cG9ydCBjbGFzcyBTdERhdGVGb3JtYXRNb2R1bGUge31cclxuIl19
|
|
@@ -15,13 +15,13 @@ export class DateFormatPipe {
|
|
|
15
15
|
return '';
|
|
16
16
|
}
|
|
17
17
|
}
|
|
18
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DateFormatPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
19
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: DateFormatPipe, name: "stDateFormatPipe" }); }
|
|
18
20
|
}
|
|
19
|
-
|
|
20
|
-
DateFormatPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: DateFormatPipe, name: "stDateFormatPipe" });
|
|
21
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: DateFormatPipe, decorators: [{
|
|
21
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DateFormatPipe, decorators: [{
|
|
22
22
|
type: Pipe,
|
|
23
23
|
args: [{
|
|
24
24
|
name: 'stDateFormatPipe',
|
|
25
25
|
}]
|
|
26
26
|
}], ctorParameters: function () { return []; } });
|
|
27
|
-
//# sourceMappingURL=data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25zdHJ1Y3RvcigpIHt9XHJcblxyXG4gIHRyYW5zZm9ybSh2YWx1ZTogc3RyaW5nIHwgRGF0ZSB8IHVuZGVmaW5lZCk6IHN0cmluZyB7XHJcbiAgICBpZiAodmFsdWUpIHtcclxuICAgICAgaWYgKHZhbHVlIGluc3RhbmNlb2YgRGF0ZSkge1xyXG4gICAgICAgIHJldHVybiB2YWx1ZS50b0xvY2FsZURhdGVTdHJpbmcoKTtcclxuICAgICAgfVxyXG4gICAgICBlbHNlIHtcclxuICAgICAgICByZXR1cm4gbmV3IERhdGUodmFsdWUpLnRvTG9jYWxlRGF0ZVN0cmluZygpO1xyXG4gICAgICB9XHJcbiAgICB9XHJcbiAgICBlbHNlIHtcclxuICAgICAgcmV0dXJuICcnO1xyXG4gICAgfVxyXG4gIH1cclxufVxyXG4iXX0=
|
|
@@ -15,13 +15,13 @@ export class DateTimeFormatPipe {
|
|
|
15
15
|
return '';
|
|
16
16
|
}
|
|
17
17
|
}
|
|
18
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DateTimeFormatPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
19
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: DateTimeFormatPipe, name: "stDateTimeFormatPipe" }); }
|
|
18
20
|
}
|
|
19
|
-
|
|
20
|
-
DateTimeFormatPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: DateTimeFormatPipe, name: "stDateTimeFormatPipe" });
|
|
21
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: DateTimeFormatPipe, decorators: [{
|
|
21
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DateTimeFormatPipe, decorators: [{
|
|
22
22
|
type: Pipe,
|
|
23
23
|
args: [{
|
|
24
24
|
name: 'stDateTimeFormatPipe',
|
|
25
25
|
}]
|
|
26
26
|
}], ctorParameters: function () { return []; } });
|
|
27
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
27
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGF0ZS10aW1lLWZvcm1hdC5waXBlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmd4LXN0LWRhdGUtZm9ybWF0L3NyYy9saWIvcGlwZXMvZGF0ZS10aW1lLWZvcm1hdC5waXBlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBQyxJQUFJLEVBQWdCLE1BQU0sZUFBZSxDQUFDOztBQUtsRCxNQUFNLE9BQU8sa0JBQWtCO0lBQzdCLGdCQUFlLENBQUM7SUFFaEIsU0FBUyxDQUFDLEtBQWdDO1FBQ3hDLElBQUksS0FBSyxFQUFFO1lBQ1QsSUFBSSxLQUFLLFlBQVksSUFBSSxFQUFFO2dCQUN6QixPQUFPLEtBQUssQ0FBQyxjQUFjLEVBQUUsQ0FBQzthQUMvQjtpQkFBTTtnQkFDTCxPQUFPLElBQUksSUFBSSxDQUFDLEtBQUssQ0FBQyxDQUFDLGNBQWMsRUFBRSxDQUFDO2FBQ3pDO1NBQ0Y7YUFBTTtZQUNMLE9BQU8sRUFBRSxDQUFDO1NBQ1g7SUFDSCxDQUFDOytHQWJVLGtCQUFrQjs2R0FBbEIsa0JBQWtCOzs0RkFBbEIsa0JBQWtCO2tCQUg5QixJQUFJO21CQUFDO29CQUNKLElBQUksRUFBRSxzQkFBc0I7aUJBQzdCIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHtQaXBlLCBQaXBlVHJhbnNmb3JtfSBmcm9tIFwiQGFuZ3VsYXIvY29yZVwiO1xyXG5cclxuQFBpcGUoe1xyXG4gIG5hbWU6ICdzdERhdGVUaW1lRm9ybWF0UGlwZScsXHJcbn0pXHJcbmV4cG9ydCBjbGFzcyBEYXRlVGltZUZvcm1hdFBpcGUgaW1wbGVtZW50cyBQaXBlVHJhbnNmb3JtIHtcclxuICBjb25zdHJ1Y3RvcigpIHt9XHJcblxyXG4gIHRyYW5zZm9ybSh2YWx1ZTogc3RyaW5nIHwgRGF0ZSB8IHVuZGVmaW5lZCk6IHN0cmluZyB7XHJcbiAgICBpZiAodmFsdWUpIHtcclxuICAgICAgaWYgKHZhbHVlIGluc3RhbmNlb2YgRGF0ZSkge1xyXG4gICAgICAgIHJldHVybiB2YWx1ZS50b0xvY2FsZVN0cmluZygpO1xyXG4gICAgICB9IGVsc2Uge1xyXG4gICAgICAgIHJldHVybiBuZXcgRGF0ZSh2YWx1ZSkudG9Mb2NhbGVTdHJpbmcoKTtcclxuICAgICAgfVxyXG4gICAgfSBlbHNlIHtcclxuICAgICAgcmV0dXJuICcnO1xyXG4gICAgfVxyXG4gIH1cclxufVxyXG4iXX0=
|
|
@@ -21,13 +21,13 @@ export class TimeFormatPipe {
|
|
|
21
21
|
return '';
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TimeFormatPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
25
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: TimeFormatPipe, name: "stTimeFormatPipe" }); }
|
|
24
26
|
}
|
|
25
|
-
|
|
26
|
-
TimeFormatPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: TimeFormatPipe, name: "stTimeFormatPipe" });
|
|
27
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TimeFormatPipe, decorators: [{
|
|
27
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TimeFormatPipe, decorators: [{
|
|
28
28
|
type: Pipe,
|
|
29
29
|
args: [{
|
|
30
30
|
name: 'stTimeFormatPipe',
|
|
31
31
|
}]
|
|
32
32
|
}], ctorParameters: function () { return []; } });
|
|
33
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
33
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGltZS1mb3JtYXQucGlwZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL25neC1zdC1kYXRlLWZvcm1hdC9zcmMvbGliL3BpcGVzL3RpbWUtZm9ybWF0LnBpcGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFDLElBQUksRUFBZ0IsTUFBTSxlQUFlLENBQUM7O0FBS2xELE1BQU0sT0FBTyxjQUFjO0lBQ3pCLGdCQUFlLENBQUM7SUFFaEIsU0FBUyxDQUFDLEtBQWdDO1FBQ3hDLElBQUksS0FBSyxFQUFFO1lBQ1QsSUFBSSxLQUFLLFlBQVksSUFBSSxFQUFFO2dCQUN6QixPQUFPLEtBQUssQ0FBQyxrQkFBa0IsQ0FBQyxFQUFFLEVBQUU7b0JBQ2xDLElBQUksRUFBRSxTQUFTO29CQUNmLE1BQU0sRUFBRSxTQUFTO2lCQUNsQixDQUFDLENBQUM7YUFDSjtpQkFDSTtnQkFDSCxPQUFPLElBQUksSUFBSSxDQUFDLEtBQUssQ0FBQyxDQUFDLGtCQUFrQixDQUFDLEVBQUUsRUFBRTtvQkFDNUMsSUFBSSxFQUFFLFNBQVM7b0JBQ2YsTUFBTSxFQUFFLFNBQVM7aUJBQ2xCLENBQUMsQ0FBQzthQUNKO1NBQ0Y7YUFDSTtZQUNILE9BQU8sRUFBRSxDQUFDO1NB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pipe';
|
|
|
5
5
|
export * from './lib/pipes/date-time-format.pipe';
|
|
6
6
|
export * from './lib/pipes/time-format.pipe';
|
|
7
7
|
export * from './lib/ngx-st-date-format.module';
|
|
8
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
8
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL25neC1zdC1kYXRlLWZvcm1hdC9zcmMvcHVibGljLWFwaS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7R0FFRztBQUVILGNBQWMsOEJBQThCLENBQUM7QUFDN0MsY0FBYyxtQ0FBbUMsQ0FBQztBQUNsRCxjQUFjLDhCQUE4QixDQUFDO0FBQzdDLGNBQWMsaUNBQWlDLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKlxyXG4gKiBQdWJsaWMgQVBJIFN1cmZhY2Ugb2Ygbmd4LXN0LWRhdGUtZm9ybWF0XHJcbiAqL1xyXG5cclxuZXhwb3J0ICogZnJvbSAnLi9saWIvcGlwZXMvZGF0ZS1mb3JtYXQucGlwZSc7XHJcbmV4cG9ydCAqIGZyb20gJy4vbGliL3BpcGVzL2RhdGUtdGltZS1mb3JtYXQucGlwZSc7XHJcbmV4cG9ydCAqIGZyb20gJy4vbGliL3BpcGVzL3RpbWUtZm9ybWF0LnBpcGUnO1xyXG5leHBvcnQgKiBmcm9tICcuL2xpYi9uZ3gtc3QtZGF0ZS1mb3JtYXQubW9kdWxlJztcclxuIl19
|
|
@@ -16,10 +16,10 @@ class DateFormatPipe {
|
|
|
16
16
|
return '';
|
|
17
17
|
}
|
|
18
18
|
}
|
|
19
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DateFormatPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
20
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: DateFormatPipe, name: "stDateFormatPipe" }); }
|
|
19
21
|
}
|
|
20
|
-
|
|
21
|
-
DateFormatPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: DateFormatPipe, name: "stDateFormatPipe" });
|
|
22
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: DateFormatPipe, decorators: [{
|
|
22
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DateFormatPipe, decorators: [{
|
|
23
23
|
type: Pipe,
|
|
24
24
|
args: [{
|
|
25
25
|
name: 'stDateFormatPipe',
|
|
@@ -41,10 +41,10 @@ class DateTimeFormatPipe {
|
|
|
41
41
|
return '';
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DateTimeFormatPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
45
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: DateTimeFormatPipe, name: "stDateTimeFormatPipe" }); }
|
|
44
46
|
}
|
|
45
|
-
|
|
46
|
-
DateTimeFormatPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: DateTimeFormatPipe, name: "stDateTimeFormatPipe" });
|
|
47
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: DateTimeFormatPipe, decorators: [{
|
|
47
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DateTimeFormatPipe, decorators: [{
|
|
48
48
|
type: Pipe,
|
|
49
49
|
args: [{
|
|
50
50
|
name: 'stDateTimeFormatPipe',
|
|
@@ -72,10 +72,10 @@ class TimeFormatPipe {
|
|
|
72
72
|
return '';
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TimeFormatPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
76
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: TimeFormatPipe, name: "stTimeFormatPipe" }); }
|
|
75
77
|
}
|
|
76
|
-
|
|
77
|
-
TimeFormatPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: TimeFormatPipe, name: "stTimeFormatPipe" });
|
|
78
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TimeFormatPipe, decorators: [{
|
|
78
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TimeFormatPipe, decorators: [{
|
|
79
79
|
type: Pipe,
|
|
80
80
|
args: [{
|
|
81
81
|
name: 'stTimeFormatPipe',
|
|
@@ -83,11 +83,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImpor
|
|
|
83
83
|
}], ctorParameters: function () { return []; } });
|
|
84
84
|
|
|
85
85
|
class StDateFormatModule {
|
|
86
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: StDateFormatModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
87
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: StDateFormatModule, declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe], exports: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe] }); }
|
|
88
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: StDateFormatModule }); }
|
|
86
89
|
}
|
|
87
|
-
|
|
88
|
-
StDateFormatModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: StDateFormatModule, declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe], exports: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe] });
|
|
89
|
-
StDateFormatModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: StDateFormatModule });
|
|
90
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: StDateFormatModule, decorators: [{
|
|
90
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: StDateFormatModule, decorators: [{
|
|
91
91
|
type: NgModule,
|
|
92
92
|
args: [{
|
|
93
93
|
declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ngx-st-date-format.mjs","sources":["../../../projects/ngx-st-date-format/src/lib/pipes/date-format.pipe.ts","../../../projects/ngx-st-date-format/src/lib/pipes/date-time-format.pipe.ts","../../../projects/ngx-st-date-format/src/lib/pipes/time-format.pipe.ts","../../../projects/ngx-st-date-format/src/lib/ngx-st-date-format.module.ts","../../../projects/ngx-st-date-format/src/public-api.ts","../../../projects/ngx-st-date-format/src/ngx-st-date-format.ts"],"sourcesContent":["import {Pipe, PipeTransform} from \"@angular/core\";\r\n\r\n@Pipe({\r\n name: 'stDateFormatPipe',\r\n})\r\nexport class DateFormatPipe implements PipeTransform {\r\n constructor() {}\r\n\r\n transform(value: string | Date | undefined): string {\r\n if (value) {\r\n if (value instanceof Date) {\r\n return value.toLocaleDateString();\r\n }\r\n else {\r\n return new Date(value).toLocaleDateString();\r\n }\r\n }\r\n else {\r\n return '';\r\n }\r\n }\r\n}\r\n","import {Pipe, PipeTransform} from \"@angular/core\";\r\n\r\n@Pipe({\r\n name: 'stDateTimeFormatPipe',\r\n})\r\nexport class DateTimeFormatPipe implements PipeTransform {\r\n constructor() {}\r\n\r\n transform(value: string | Date | undefined): string {\r\n if (value) {\r\n if (value instanceof Date) {\r\n return value.toLocaleString();\r\n } else {\r\n return new Date(value).toLocaleString();\r\n }\r\n } else {\r\n return '';\r\n }\r\n }\r\n}\r\n","import {Pipe, PipeTransform} from \"@angular/core\";\r\n\r\n@Pipe({\r\n name: 'stTimeFormatPipe',\r\n})\r\nexport class TimeFormatPipe implements PipeTransform {\r\n constructor() {}\r\n\r\n transform(value: string | Date | undefined): string {\r\n if (value) {\r\n if (value instanceof Date) {\r\n return value.toLocaleTimeString([], {\r\n hour: '2-digit',\r\n minute: '2-digit',\r\n });\r\n }\r\n else {\r\n return new Date(value).toLocaleTimeString([], {\r\n hour: '2-digit',\r\n minute: '2-digit',\r\n });\r\n }\r\n }\r\n else {\r\n return '';\r\n }\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { DateFormatPipe } from './pipes/date-format.pipe';\r\nimport { DateTimeFormatPipe } from './pipes/date-time-format.pipe';\r\nimport { TimeFormatPipe } from './pipes/time-format.pipe';\r\n\r\n@NgModule({\r\n declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],\r\n imports: [],\r\n exports: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],\r\n})\r\nexport class StDateFormatModule {}\r\n","/*\r\n * Public API Surface of ngx-st-date-format\r\n */\r\n\r\nexport * from './lib/pipes/date-format.pipe';\r\nexport * from './lib/pipes/date-time-format.pipe';\r\nexport * from './lib/pipes/time-format.pipe';\r\nexport * from './lib/ngx-st-date-format.module';\r\n","/**\n * Generated bundle index. Do not edit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AA,CAJd,cAAc,EAAE,kBAAkB,EAAE,cAAc,CAAA,EAAA,OAAA,EAAA,CAEvD,cAAc,EAAE,kBAAkB,EAAE,cAAc,CAAA,EAAA,CAAA,CAAA,EAAA;gHAEjD,kBAAkB,EAAA,CAAA,CAAA,EAAA;;4FAAlB,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAL9B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE,CAAC,cAAc,EAAE,kBAAkB,EAAE,cAAc,CAAC;AAClE,oBAAA,OAAO,EAAE,EAAE;AACX,oBAAA,OAAO,EAAE,CAAC,cAAc,EAAE,kBAAkB,EAAE,cAAc,CAAC;AAC9D,iBAAA,CAAA;;;ACTD;;AAEG;;ACFH;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,18 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ngx-st-date-format",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "16.0.0",
|
|
4
4
|
"peerDependencies": {
|
|
5
|
-
"@angular/common": "^
|
|
6
|
-
"@angular/core": "^
|
|
5
|
+
"@angular/common": "^16.2.12",
|
|
6
|
+
"@angular/core": "^16.2.12"
|
|
7
7
|
},
|
|
8
8
|
"dependencies": {
|
|
9
9
|
"tslib": "^2.3.0"
|
|
10
10
|
},
|
|
11
|
-
"module": "
|
|
12
|
-
"es2020": "fesm2020/ngx-st-date-format.mjs",
|
|
13
|
-
"esm2020": "esm2020/ngx-st-date-format.mjs",
|
|
14
|
-
"fesm2020": "fesm2020/ngx-st-date-format.mjs",
|
|
15
|
-
"fesm2015": "fesm2015/ngx-st-date-format.mjs",
|
|
11
|
+
"module": "fesm2022/ngx-st-date-format.mjs",
|
|
16
12
|
"typings": "index.d.ts",
|
|
17
13
|
"exports": {
|
|
18
14
|
"./package.json": {
|
|
@@ -20,11 +16,9 @@
|
|
|
20
16
|
},
|
|
21
17
|
".": {
|
|
22
18
|
"types": "./index.d.ts",
|
|
23
|
-
"
|
|
24
|
-
"
|
|
25
|
-
"
|
|
26
|
-
"node": "./fesm2015/ngx-st-date-format.mjs",
|
|
27
|
-
"default": "./fesm2020/ngx-st-date-format.mjs"
|
|
19
|
+
"esm2022": "./esm2022/ngx-st-date-format.mjs",
|
|
20
|
+
"esm": "./esm2022/ngx-st-date-format.mjs",
|
|
21
|
+
"default": "./fesm2022/ngx-st-date-format.mjs"
|
|
28
22
|
}
|
|
29
23
|
},
|
|
30
24
|
"sideEffects": false
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-st-date-format.mjs","sources":["../../../projects/ngx-st-date-format/src/lib/pipes/date-format.pipe.ts","../../../projects/ngx-st-date-format/src/lib/pipes/date-time-format.pipe.ts","../../../projects/ngx-st-date-format/src/lib/pipes/time-format.pipe.ts","../../../projects/ngx-st-date-format/src/lib/ngx-st-date-format.module.ts","../../../projects/ngx-st-date-format/src/public-api.ts","../../../projects/ngx-st-date-format/src/ngx-st-date-format.ts"],"sourcesContent":["import {Pipe, PipeTransform} from \"@angular/core\";\n\n@Pipe({\n name: 'stDateFormatPipe',\n})\nexport class DateFormatPipe implements PipeTransform {\n constructor() {}\n\n transform(value: string | Date | undefined): string {\n if (value) {\n if (value instanceof Date) {\n return value.toLocaleDateString();\n }\n else {\n return new Date(value).toLocaleDateString();\n }\n }\n else {\n return '';\n }\n }\n}\n","import {Pipe, PipeTransform} from \"@angular/core\";\n\n@Pipe({\n name: 'stDateTimeFormatPipe',\n})\nexport class DateTimeFormatPipe implements PipeTransform {\n constructor() {}\n\n transform(value: string | Date | undefined): string {\n if (value) {\n if (value instanceof Date) {\n return value.toLocaleString();\n } else {\n return new Date(value).toLocaleString();\n }\n } else {\n return '';\n }\n }\n}\n","import {Pipe, PipeTransform} from \"@angular/core\";\n\n@Pipe({\n name: 'stTimeFormatPipe',\n})\nexport class TimeFormatPipe implements PipeTransform {\n constructor() {}\n\n transform(value: string | Date | undefined): string {\n if (value) {\n if (value instanceof Date) {\n return value.toLocaleTimeString([], {\n hour: '2-digit',\n minute: '2-digit',\n });\n }\n else {\n return new Date(value).toLocaleTimeString([], {\n hour: '2-digit',\n minute: '2-digit',\n });\n }\n }\n else {\n return '';\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { DateFormatPipe } from './pipes/date-format.pipe';\nimport { DateTimeFormatPipe } from './pipes/date-time-format.pipe';\nimport { TimeFormatPipe } from './pipes/time-format.pipe';\n\n@NgModule({\n declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],\n imports: [],\n exports: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],\n})\nexport class StDateFormatModule {}\n","/*\n * Public API Surface of ngx-st-date-format\n */\n\nexport * from './lib/pipes/date-format.pipe';\nexport * from './lib/pipes/date-time-format.pipe';\nexport * from './lib/pipes/time-format.pipe';\nexport * from './lib/ngx-st-date-format.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;MAKa,cAAc,CAAA;AACzB,IAAA,WAAA,GAAA,GAAgB;AAEhB,IAAA,SAAS,CAAC,KAAgC,EAAA;AACxC,QAAA,IAAI,KAAK,EAAE;YACT,IAAI,KAAK,YAAY,IAAI,EAAE;AACzB,gBAAA,OAAO,KAAK,CAAC,kBAAkB,EAAE,CAAC;AACnC,aAAA;AACI,iBAAA;gBACH,OAAO,IAAI,IAAI,CAAC,KAAK,CAAC,CAAC,kBAAkB,EAAE,CAAC;AAC7C,aAAA;AACF,SAAA;AACI,aAAA;AACH,YAAA,OAAO,EAAE,CAAC;AACX,SAAA;KACF;;2GAfU,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,IAAA,EAAA,CAAA,CAAA;yGAAd,cAAc,EAAA,IAAA,EAAA,kBAAA,EAAA,CAAA,CAAA;2FAAd,cAAc,EAAA,UAAA,EAAA,CAAA;kBAH1B,IAAI;AAAC,YAAA,IAAA,E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AAA;AACF,SAAA;AACI,aAAA;AACH,YAAA,OAAO,EAAE,CAAC;AACX,SAAA;KACF;;2GArBU,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,IAAA,EAAA,CAAA,CAAA;yGAAd,cAAc,EAAA,IAAA,EAAA,kBAAA,EAAA,CAAA,CAAA;2FAAd,cAAc,EAAA,UAAA,EAAA,CAAA;kBAH1B,IAAI;AAAC,YAAA,IAAA,EAAA,CAAA;AACJ,oBAAA,IAAI,EAAE,kBAAkB;iBACzB,CAAA;;;MCMY,kBAAkB,CAAA;;+GAAlB,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;gHAAlB,kBAAkB,EAAA,YAAA,EAAA,CAJd,cAAc,EAAE,kBAAkB,EAAE,cAAc,CAAA,EAAA,OAAA,EAAA,CAEvD,cAAc,EAAE,kBAAkB,EAAE,cAAc,CAAA,EAAA,CAAA,CAAA;gHAEjD,kBAAkB,EAAA,CAAA,CAAA;2FAAlB,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAL9B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE,CAAC,cAAc,EAAE,kBAAkB,EAAE,cAAc,CAAC;AAClE,oBAAA,OAAO,EAAE,EAAE;AACX,oBAAA,OAAO,EAAE,CAAC,cAAc,EAAE,kBAAkB,EAAE,cAAc,CAAC;iBAC9D,CAAA;;;ACTD;;AAEG;;ACFH;;AAEG;;;;"}
|
|
@@ -1,108 +0,0 @@
|
|
|
1
|
-
import * as i0 from '@angular/core';
|
|
2
|
-
import { Pipe, NgModule } from '@angular/core';
|
|
3
|
-
|
|
4
|
-
class DateFormatPipe {
|
|
5
|
-
constructor() { }
|
|
6
|
-
transform(value) {
|
|
7
|
-
if (value) {
|
|
8
|
-
if (value instanceof Date) {
|
|
9
|
-
return value.toLocaleDateString();
|
|
10
|
-
}
|
|
11
|
-
else {
|
|
12
|
-
return new Date(value).toLocaleDateString();
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
else {
|
|
16
|
-
return '';
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
DateFormatPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: DateFormatPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
21
|
-
DateFormatPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: DateFormatPipe, name: "stDateFormatPipe" });
|
|
22
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: DateFormatPipe, decorators: [{
|
|
23
|
-
type: Pipe,
|
|
24
|
-
args: [{
|
|
25
|
-
name: 'stDateFormatPipe',
|
|
26
|
-
}]
|
|
27
|
-
}], ctorParameters: function () { return []; } });
|
|
28
|
-
|
|
29
|
-
class DateTimeFormatPipe {
|
|
30
|
-
constructor() { }
|
|
31
|
-
transform(value) {
|
|
32
|
-
if (value) {
|
|
33
|
-
if (value instanceof Date) {
|
|
34
|
-
return value.toLocaleString();
|
|
35
|
-
}
|
|
36
|
-
else {
|
|
37
|
-
return new Date(value).toLocaleString();
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
else {
|
|
41
|
-
return '';
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
DateTimeFormatPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: DateTimeFormatPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
46
|
-
DateTimeFormatPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: DateTimeFormatPipe, name: "stDateTimeFormatPipe" });
|
|
47
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: DateTimeFormatPipe, decorators: [{
|
|
48
|
-
type: Pipe,
|
|
49
|
-
args: [{
|
|
50
|
-
name: 'stDateTimeFormatPipe',
|
|
51
|
-
}]
|
|
52
|
-
}], ctorParameters: function () { return []; } });
|
|
53
|
-
|
|
54
|
-
class TimeFormatPipe {
|
|
55
|
-
constructor() { }
|
|
56
|
-
transform(value) {
|
|
57
|
-
if (value) {
|
|
58
|
-
if (value instanceof Date) {
|
|
59
|
-
return value.toLocaleTimeString([], {
|
|
60
|
-
hour: '2-digit',
|
|
61
|
-
minute: '2-digit',
|
|
62
|
-
});
|
|
63
|
-
}
|
|
64
|
-
else {
|
|
65
|
-
return new Date(value).toLocaleTimeString([], {
|
|
66
|
-
hour: '2-digit',
|
|
67
|
-
minute: '2-digit',
|
|
68
|
-
});
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
else {
|
|
72
|
-
return '';
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
TimeFormatPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TimeFormatPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
77
|
-
TimeFormatPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: TimeFormatPipe, name: "stTimeFormatPipe" });
|
|
78
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TimeFormatPipe, decorators: [{
|
|
79
|
-
type: Pipe,
|
|
80
|
-
args: [{
|
|
81
|
-
name: 'stTimeFormatPipe',
|
|
82
|
-
}]
|
|
83
|
-
}], ctorParameters: function () { return []; } });
|
|
84
|
-
|
|
85
|
-
class StDateFormatModule {
|
|
86
|
-
}
|
|
87
|
-
StDateFormatModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: StDateFormatModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
88
|
-
StDateFormatModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: StDateFormatModule, declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe], exports: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe] });
|
|
89
|
-
StDateFormatModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: StDateFormatModule });
|
|
90
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: StDateFormatModule, decorators: [{
|
|
91
|
-
type: NgModule,
|
|
92
|
-
args: [{
|
|
93
|
-
declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],
|
|
94
|
-
imports: [],
|
|
95
|
-
exports: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],
|
|
96
|
-
}]
|
|
97
|
-
}] });
|
|
98
|
-
|
|
99
|
-
/*
|
|
100
|
-
* Public API Surface of ngx-st-date-format
|
|
101
|
-
*/
|
|
102
|
-
|
|
103
|
-
/**
|
|
104
|
-
* Generated bundle index. Do not edit.
|
|
105
|
-
*/
|
|
106
|
-
|
|
107
|
-
export { DateFormatPipe, DateTimeFormatPipe, StDateFormatModule, TimeFormatPipe };
|
|
108
|
-
//# sourceMappingURL=ngx-st-date-format.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-st-date-format.mjs","sources":["../../../projects/ngx-st-date-format/src/lib/pipes/date-format.pipe.ts","../../../projects/ngx-st-date-format/src/lib/pipes/date-time-format.pipe.ts","../../../projects/ngx-st-date-format/src/lib/pipes/time-format.pipe.ts","../../../projects/ngx-st-date-format/src/lib/ngx-st-date-format.module.ts","../../../projects/ngx-st-date-format/src/public-api.ts","../../../projects/ngx-st-date-format/src/ngx-st-date-format.ts"],"sourcesContent":["import {Pipe, PipeTransform} from \"@angular/core\";\n\n@Pipe({\n name: 'stDateFormatPipe',\n})\nexport class DateFormatPipe implements PipeTransform {\n constructor() {}\n\n transform(value: string | Date | undefined): string {\n if (value) {\n if (value instanceof Date) {\n return value.toLocaleDateString();\n }\n else {\n return new Date(value).toLocaleDateString();\n }\n }\n else {\n return '';\n }\n }\n}\n","import {Pipe, PipeTransform} from \"@angular/core\";\n\n@Pipe({\n name: 'stDateTimeFormatPipe',\n})\nexport class DateTimeFormatPipe implements PipeTransform {\n constructor() {}\n\n transform(value: string | Date | undefined): string {\n if (value) {\n if (value instanceof Date) {\n return value.toLocaleString();\n } else {\n return new Date(value).toLocaleString();\n }\n } else {\n return '';\n }\n }\n}\n","import {Pipe, PipeTransform} from \"@angular/core\";\n\n@Pipe({\n name: 'stTimeFormatPipe',\n})\nexport class TimeFormatPipe implements PipeTransform {\n constructor() {}\n\n transform(value: string | Date | undefined): string {\n if (value) {\n if (value instanceof Date) {\n return value.toLocaleTimeString([], {\n hour: '2-digit',\n minute: '2-digit',\n });\n }\n else {\n return new Date(value).toLocaleTimeString([], {\n hour: '2-digit',\n minute: '2-digit',\n });\n }\n }\n else {\n return '';\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { DateFormatPipe } from './pipes/date-format.pipe';\nimport { DateTimeFormatPipe } from './pipes/date-time-format.pipe';\nimport { TimeFormatPipe } from './pipes/time-format.pipe';\n\n@NgModule({\n declarations: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],\n imports: [],\n exports: [DateFormatPipe, DateTimeFormatPipe, TimeFormatPipe],\n})\nexport class StDateFormatModule {}\n","/*\n * Public API Surface of ngx-st-date-format\n */\n\nexport * from './lib/pipes/date-format.pipe';\nexport * from './lib/pipes/date-time-format.pipe';\nexport * from './lib/pipes/time-format.pipe';\nexport * from './lib/ngx-st-date-format.module';\n","/**\n * Generated bundle index. Do not edit.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