ln-20-lib-components 0.0.8

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 ADDED
@@ -0,0 +1,63 @@
1
+ # LibComponents
2
+
3
+ This project was generated using [Angular CLI](https://github.com/angular/angular-cli) version 19.2.0.
4
+
5
+ ## Code scaffolding
6
+
7
+ Angular CLI includes powerful code scaffolding tools. To generate a new component, run:
8
+
9
+ ```bash
10
+ ng generate component component-name
11
+ ```
12
+
13
+ For a complete list of available schematics (such as `components`, `directives`, or `pipes`), run:
14
+
15
+ ```bash
16
+ ng generate --help
17
+ ```
18
+
19
+ ## Building
20
+
21
+ To build the library, run:
22
+
23
+ ```bash
24
+ ng build lib-components
25
+ ```
26
+
27
+ This command will compile your project, and the build artifacts will be placed in the `dist/` directory.
28
+
29
+ ### Publishing the Library
30
+
31
+ Once the project is built, you can publish your library by following these steps:
32
+
33
+ 1. Navigate to the `dist` directory:
34
+ ```bash
35
+ cd dist/lib-components
36
+ ```
37
+
38
+ 2. Run the `npm publish` command to publish your library to the npm registry:
39
+ ```bash
40
+ npm publish
41
+ ```
42
+
43
+ ## Running unit tests
44
+
45
+ To execute unit tests with the [Karma](https://karma-runner.github.io) test runner, use the following command:
46
+
47
+ ```bash
48
+ ng test
49
+ ```
50
+
51
+ ## Running end-to-end tests
52
+
53
+ For end-to-end (e2e) testing, run:
54
+
55
+ ```bash
56
+ ng e2e
57
+ ```
58
+
59
+ Angular CLI does not come with an end-to-end testing framework by default. You can choose one that suits your needs.
60
+
61
+ ## Additional Resources
62
+
63
+ For more information on using the Angular CLI, including detailed command references, visit the [Angular CLI Overview and Command Reference](https://angular.dev/tools/cli) page.
@@ -0,0 +1,111 @@
1
+ import * as i0 from '@angular/core';
2
+ import { Injectable, Component, EventEmitter, Output, Input } from '@angular/core';
3
+ import { CommonModule } from '@angular/common';
4
+
5
+ class LibComponentsService {
6
+ constructor() { }
7
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: LibComponentsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
8
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: LibComponentsService, providedIn: 'root' });
9
+ }
10
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: LibComponentsService, decorators: [{
11
+ type: Injectable,
12
+ args: [{
13
+ providedIn: 'root'
14
+ }]
15
+ }], ctorParameters: () => [] });
16
+
17
+ class LibComponentsComponent {
18
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: LibComponentsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
19
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.17", type: LibComponentsComponent, isStandalone: true, selector: "lib-lib-components", ngImport: i0, template: `
20
+ <p>
21
+ lib-components works!
22
+ </p>
23
+ `, isInline: true, styles: [""] });
24
+ }
25
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: LibComponentsComponent, decorators: [{
26
+ type: Component,
27
+ args: [{ selector: 'lib-lib-components', imports: [], template: `
28
+ <p>
29
+ lib-components works!
30
+ </p>
31
+ ` }]
32
+ }] });
33
+
34
+ class ButtonComponent {
35
+ variant = 'primary';
36
+ disabled = false;
37
+ onClick = new EventEmitter();
38
+ constructor() {
39
+ console.log('ButtonComponent constructor');
40
+ }
41
+ ngOnInit() {
42
+ console.log('ButtonComponent ngOnInit');
43
+ }
44
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: ButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
45
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.17", type: ButtonComponent, isStandalone: true, selector: "lib-button", inputs: { variant: "variant", disabled: "disabled" }, outputs: { onClick: "onClick" }, ngImport: i0, template: `
46
+ <button
47
+ [class]="'lib-button ' + (variant || 'primary')"
48
+ [disabled]="disabled"
49
+ (click)="onClick.emit()">
50
+ <ng-content></ng-content>
51
+ </button>
52
+ `, isInline: true, styles: [".lib-button{padding:8px 16px;border:none;border-radius:4px;cursor:pointer;font-size:14px;transition:opacity .2s ease}.lib-button.primary{background-color:#007bff;color:#fff}.lib-button.primary:hover:not(:disabled){background-color:#0056b3}.lib-button.secondary{background-color:#6c757d;color:#fff}.lib-button.secondary:hover:not(:disabled){background-color:#545b62}.lib-button:disabled{opacity:.6;cursor:not-allowed}\n"] });
53
+ }
54
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: ButtonComponent, decorators: [{
55
+ type: Component,
56
+ args: [{ selector: 'lib-button', standalone: true, imports: [], template: `
57
+ <button
58
+ [class]="'lib-button ' + (variant || 'primary')"
59
+ [disabled]="disabled"
60
+ (click)="onClick.emit()">
61
+ <ng-content></ng-content>
62
+ </button>
63
+ `, styles: [".lib-button{padding:8px 16px;border:none;border-radius:4px;cursor:pointer;font-size:14px;transition:opacity .2s ease}.lib-button.primary{background-color:#007bff;color:#fff}.lib-button.primary:hover:not(:disabled){background-color:#0056b3}.lib-button.secondary{background-color:#6c757d;color:#fff}.lib-button.secondary:hover:not(:disabled){background-color:#545b62}.lib-button:disabled{opacity:.6;cursor:not-allowed}\n"] }]
64
+ }], ctorParameters: () => [], propDecorators: { variant: [{
65
+ type: Input
66
+ }], disabled: [{
67
+ type: Input
68
+ }], onClick: [{
69
+ type: Output
70
+ }] } });
71
+
72
+ class EmptyMessageComponent {
73
+ constructor() {
74
+ console.log('EmptyMessageComponent constructor');
75
+ }
76
+ ngOnInit() {
77
+ console.log('EmptyMessageComponent ngOnInit');
78
+ }
79
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: EmptyMessageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
80
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.17", type: EmptyMessageComponent, isStandalone: true, selector: "lib-empty-message", ngImport: i0, template: `
81
+ <div class="empty-message">
82
+ <p class="empty-message-text">NO DATA AVAILABLE</p>
83
+ </div>
84
+ `, isInline: true, styles: [".empty-message{display:flex;align-items:center;justify-content:center;padding:2rem}.empty-message-text{text-align:center;color:#6c757d;margin:0;font-size:1rem}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }] });
85
+ }
86
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: EmptyMessageComponent, decorators: [{
87
+ type: Component,
88
+ args: [{ selector: 'lib-empty-message', standalone: true, imports: [CommonModule], template: `
89
+ <div class="empty-message">
90
+ <p class="empty-message-text">NO DATA AVAILABLE</p>
91
+ </div>
92
+ `, styles: [".empty-message{display:flex;align-items:center;justify-content:center;padding:2rem}.empty-message-text{text-align:center;color:#6c757d;margin:0;font-size:1rem}\n"] }]
93
+ }], ctorParameters: () => [] });
94
+
95
+ /*
96
+ * Public API Surface of lib-components
97
+
98
+ NPM TOKEN:
99
+ 4f5f941cb6703a2bea326507bd5098aa7dd8224ef4d9b434f6209c73855bf7ac
100
+ 8b61ac2dab0cf90c13878339c755b09f868b34906ad196a1138433f76f41feb4
101
+ 37b8f0500846352a33a9d1e2a8504e8a4332cd035a3819d9dc4b2dcdf557c3f0
102
+ 31f1ccdf0a47736bd3851647d485385323328542c49de9d95498d875e3977f5e
103
+ de13d65e8a0357ce9f2e18c899c8e7f6f728181baa031761ecdd7ef5cb166eb2
104
+ */
105
+
106
+ /**
107
+ * Generated bundle index. Do not edit.
108
+ */
109
+
110
+ export { ButtonComponent, EmptyMessageComponent, LibComponentsComponent, LibComponentsService };
111
+ //# sourceMappingURL=ln-20-lib-components.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ln-20-lib-components.mjs","sources":["../../../projects/lib-components/src/lib/lib-components.service.ts","../../../projects/lib-components/src/lib/lib-components.component.ts","../../../projects/lib-components/src/lib/button/button.component.ts","../../../projects/lib-components/src/lib/empty-message/empty-message.component.ts","../../../projects/lib-components/src/public-api.ts","../../../projects/lib-components/src/ln-20-lib-components.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class LibComponentsService {\r\n\r\n constructor() { }\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'lib-lib-components',\r\n imports: [],\r\n template: `\r\n <p>\r\n lib-components works!\r\n </p>\r\n `,\r\n styles: ``\r\n})\r\nexport class LibComponentsComponent {\r\n\r\n}\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'lib-button',\r\n standalone: true,\r\n imports: [],\r\n template: `\r\n <button \r\n [class]=\"'lib-button ' + (variant || 'primary')\" \r\n [disabled]=\"disabled\" \r\n (click)=\"onClick.emit()\">\r\n <ng-content></ng-content>\r\n </button>\r\n `,\r\n styles: [`\r\n .lib-button {\r\n padding: 8px 16px;\r\n border: none;\r\n border-radius: 4px;\r\n cursor: pointer;\r\n font-size: 14px;\r\n transition: opacity 0.2s ease;\r\n }\r\n \r\n .lib-button.primary {\r\n background-color: #007bff;\r\n color: white;\r\n }\r\n \r\n .lib-button.primary:hover:not(:disabled) {\r\n background-color: #0056b3;\r\n }\r\n \r\n .lib-button.secondary {\r\n background-color: #6c757d;\r\n color: white;\r\n }\r\n \r\n .lib-button.secondary:hover:not(:disabled) {\r\n background-color: #545b62;\r\n }\r\n \r\n .lib-button:disabled {\r\n opacity: 0.6;\r\n cursor: not-allowed;\r\n }\r\n `]\r\n})\r\nexport class ButtonComponent implements OnInit {\r\n\r\n @Input() variant: 'primary' | 'secondary' = 'primary';\r\n @Input() disabled: boolean = false;\r\n @Output() onClick = new EventEmitter<void>();\r\n\r\n constructor() {\r\n console.log('ButtonComponent constructor');\r\n }\r\n ngOnInit(): void {\r\n console.log('ButtonComponent ngOnInit');\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { Component, OnInit } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'lib-empty-message',\r\n standalone: true,\r\n imports: [CommonModule],\r\n template: `\r\n <div class=\"empty-message\">\r\n <p class=\"empty-message-text\">NO DATA AVAILABLE</p>\r\n </div>\r\n `,\r\n styles: [`\r\n .empty-message {\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 2rem;\r\n }\r\n \r\n .empty-message-text {\r\n text-align: center;\r\n color: #6c757d;\r\n margin: 0;\r\n font-size: 1rem;\r\n }\r\n `]\r\n})\r\nexport class EmptyMessageComponent implements OnInit{\r\n\r\n constructor() {\r\n console.log('EmptyMessageComponent constructor');\r\n }\r\n\r\n ngOnInit(): void {\r\n console.log('EmptyMessageComponent ngOnInit');\r\n }\r\n}\r\n","/*\r\n * Public API Surface of lib-components\r\n\r\nNPM TOKEN:\r\n4f5f941cb6703a2bea326507bd5098aa7dd8224ef4d9b434f6209c73855bf7ac\r\n8b61ac2dab0cf90c13878339c755b09f868b34906ad196a1138433f76f41feb4\r\n37b8f0500846352a33a9d1e2a8504e8a4332cd035a3819d9dc4b2dcdf557c3f0\r\n31f1ccdf0a47736bd3851647d485385323328542c49de9d95498d875e3977f5e\r\nde13d65e8a0357ce9f2e18c899c8e7f6f728181baa031761ecdd7ef5cb166eb2\r\n */\r\n\r\nexport * from './lib/lib-components.service';\r\nexport * from './lib/lib-components.component';\r\nexport * from './lib/button/button.component';\r\nexport * from './lib/empty-message/empty-message.component';\r\n\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;MAKa,oBAAoB,CAAA;AAE/B,IAAA,WAAA,GAAA,EAAgB;wGAFL,oBAAoB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EA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A,EAAA,SAAA,EAAA,IAAA,EAAA,qBAAqB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,mBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EArBtB,CAAA;;;;AAIT,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,mKAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EALS,YAAY,EAAA,CAAA,EAAA,CAAA;;4FAsBX,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAzBjC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,mBAAmB,cACjB,IAAI,EAAA,OAAA,EACP,CAAC,YAAY,CAAC,EAAA,QAAA,EACb,CAAA;;;;AAIT,EAAA,CAAA,EAAA,MAAA,EAAA,CAAA,mKAAA,CAAA,EAAA;;;ACXH;;;;;;;;;AASG;;ACTH;;AAEG;;;;"}
package/index.d.ts ADDED
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Generated bundle index. Do not edit.
3
+ */
4
+ /// <amd-module name="ln-20-lib-components" />
5
+ export * from './public-api';
@@ -0,0 +1,11 @@
1
+ import { EventEmitter, OnInit } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ export declare class ButtonComponent implements OnInit {
4
+ variant: 'primary' | 'secondary';
5
+ disabled: boolean;
6
+ onClick: EventEmitter<void>;
7
+ constructor();
8
+ ngOnInit(): void;
9
+ static ɵfac: i0.ɵɵFactoryDeclaration<ButtonComponent, never>;
10
+ static ɵcmp: i0.ɵɵComponentDeclaration<ButtonComponent, "lib-button", never, { "variant": { "alias": "variant"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; }, { "onClick": "onClick"; }, never, ["*"], true, never>;
11
+ }
@@ -0,0 +1,8 @@
1
+ import { OnInit } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ export declare class EmptyMessageComponent implements OnInit {
4
+ constructor();
5
+ ngOnInit(): void;
6
+ static ɵfac: i0.ɵɵFactoryDeclaration<EmptyMessageComponent, never>;
7
+ static ɵcmp: i0.ɵɵComponentDeclaration<EmptyMessageComponent, "lib-empty-message", never, {}, {}, never, never, true, never>;
8
+ }
@@ -0,0 +1,5 @@
1
+ import * as i0 from "@angular/core";
2
+ export declare class LibComponentsComponent {
3
+ static ɵfac: i0.ɵɵFactoryDeclaration<LibComponentsComponent, never>;
4
+ static ɵcmp: i0.ɵɵComponentDeclaration<LibComponentsComponent, "lib-lib-components", never, {}, {}, never, never, true, never>;
5
+ }
@@ -0,0 +1,6 @@
1
+ import * as i0 from "@angular/core";
2
+ export declare class LibComponentsService {
3
+ constructor();
4
+ static ɵfac: i0.ɵɵFactoryDeclaration<LibComponentsService, never>;
5
+ static ɵprov: i0.ɵɵInjectableDeclaration<LibComponentsService>;
6
+ }
package/package.json ADDED
@@ -0,0 +1,23 @@
1
+ {
2
+ "name": "ln-20-lib-components",
3
+ "version": "0.0.8",
4
+ "peerDependencies": {
5
+ "@angular/common": "^19.0.0",
6
+ "@angular/core": "^19.0.0"
7
+ },
8
+ "dependencies": {
9
+ "tslib": "^2.3.0"
10
+ },
11
+ "sideEffects": false,
12
+ "module": "fesm2022/ln-20-lib-components.mjs",
13
+ "typings": "index.d.ts",
14
+ "exports": {
15
+ "./package.json": {
16
+ "default": "./package.json"
17
+ },
18
+ ".": {
19
+ "types": "./index.d.ts",
20
+ "default": "./fesm2022/ln-20-lib-components.mjs"
21
+ }
22
+ }
23
+ }
@@ -0,0 +1,4 @@
1
+ export * from './lib/lib-components.service';
2
+ export * from './lib/lib-components.component';
3
+ export * from './lib/button/button.component';
4
+ export * from './lib/empty-message/empty-message.component';