ngx-dsxlibrary 1.21.41 → 1.21.43
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.
|
@@ -625,11 +625,11 @@ class LoadingLottieComponent {
|
|
|
625
625
|
});
|
|
626
626
|
}
|
|
627
627
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.1", ngImport: i0, type: LoadingLottieComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
628
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.1", type: LoadingLottieComponent, isStandalone: true, selector: "app-loading-lottie", inputs: { jsonUrl: { classPropertyName: "jsonUrl", publicName: "jsonUrl", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@if(_spinnerService.spinnerVisible()){\r\n<div class=\"loader-container\">\r\n <ng-lottie [options]=\"options\" [width]=\"size()\" [height]=\"size()\"></ng-lottie>\r\n <p class=\"loading-text\">©DevsoftXela {{ currentYear }}</p>\r\n</div>\r\n}\r\n", styles: [".loader-container{position:fixed;top:0;left:0;width:100vw;height:100vh;background-color:#
|
|
628
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.1", type: LoadingLottieComponent, isStandalone: true, selector: "app-loading-lottie", inputs: { jsonUrl: { classPropertyName: "jsonUrl", publicName: "jsonUrl", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@if(_spinnerService.spinnerVisible()){\r\n<div class=\"loader-container\">\r\n <ng-lottie [options]=\"options\" [width]=\"size()\" [height]=\"size()\"></ng-lottie>\r\n <p class=\"loading-text\">©DevsoftXela {{ currentYear }}</p>\r\n</div>\r\n}\r\n", styles: [".loader-container{position:fixed;top:0;left:0;width:100vw;height:100vh;background-color:#000c;display:flex;justify-content:center;align-items:center;z-index:9999;overflow:hidden;opacity:0;animation:overlayFadeIn .25s ease-out forwards}.loading-text{position:absolute;bottom:calc(53% - 175px);z-index:2;font-family:Montserrat,sans-serif;text-transform:uppercase;background:linear-gradient(45deg,#0ff,#f0f);-webkit-background-clip:text;background-clip:text;color:transparent;font-weight:700;text-align:center;pointer-events:none}@keyframes overlayFadeIn{0%{opacity:0}to{opacity:1}}\n"], dependencies: [{ kind: "component", type: LottieComponent, selector: "ng-lottie", inputs: ["width", "height"] }] });
|
|
629
629
|
}
|
|
630
630
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.1", ngImport: i0, type: LoadingLottieComponent, decorators: [{
|
|
631
631
|
type: Component,
|
|
632
|
-
args: [{ selector: 'app-loading-lottie', imports: [LottieComponent], template: "@if(_spinnerService.spinnerVisible()){\r\n<div class=\"loader-container\">\r\n <ng-lottie [options]=\"options\" [width]=\"size()\" [height]=\"size()\"></ng-lottie>\r\n <p class=\"loading-text\">©DevsoftXela {{ currentYear }}</p>\r\n</div>\r\n}\r\n", styles: [".loader-container{position:fixed;top:0;left:0;width:100vw;height:100vh;background-color:#
|
|
632
|
+
args: [{ selector: 'app-loading-lottie', imports: [LottieComponent], template: "@if(_spinnerService.spinnerVisible()){\r\n<div class=\"loader-container\">\r\n <ng-lottie [options]=\"options\" [width]=\"size()\" [height]=\"size()\"></ng-lottie>\r\n <p class=\"loading-text\">©DevsoftXela {{ currentYear }}</p>\r\n</div>\r\n}\r\n", styles: [".loader-container{position:fixed;top:0;left:0;width:100vw;height:100vh;background-color:#000c;display:flex;justify-content:center;align-items:center;z-index:9999;overflow:hidden;opacity:0;animation:overlayFadeIn .25s ease-out forwards}.loading-text{position:absolute;bottom:calc(53% - 175px);z-index:2;font-family:Montserrat,sans-serif;text-transform:uppercase;background:linear-gradient(45deg,#0ff,#f0f);-webkit-background-clip:text;background-clip:text;color:transparent;font-weight:700;text-align:center;pointer-events:none}@keyframes overlayFadeIn{0%{opacity:0}to{opacity:1}}\n"] }]
|
|
633
633
|
}], ctorParameters: () => [], propDecorators: { jsonUrl: [{ type: i0.Input, args: [{ isSignal: true, alias: "jsonUrl", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }] } });
|
|
634
634
|
|
|
635
635
|
class CssV2Component {
|
|
@@ -2308,21 +2308,63 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.1", ngImpor
|
|
|
2308
2308
|
}]
|
|
2309
2309
|
}] });
|
|
2310
2310
|
|
|
2311
|
+
/**
|
|
2312
|
+
* Servicio genérico para consumir endpoints REST de la API.
|
|
2313
|
+
*
|
|
2314
|
+
* @typeParam T Tipo de dato que representa el recurso manejado por el endpoint.
|
|
2315
|
+
*/
|
|
2311
2316
|
class EndpointService {
|
|
2317
|
+
/** Cliente HTTP de Angular utilizado para realizar las peticiones. */
|
|
2312
2318
|
http = inject(HttpClient);
|
|
2319
|
+
/** Configuración de entorno que contiene la URL base de la API. */
|
|
2313
2320
|
environment = inject(ENVIRONMENT);
|
|
2321
|
+
/**
|
|
2322
|
+
* Construye la URL completa del endpoint a partir de la configuración de entorno.
|
|
2323
|
+
*
|
|
2324
|
+
* @param endpoint Segmento del endpoint (por ejemplo: 'usuarios', 'facturas').
|
|
2325
|
+
* @returns URL absoluta del endpoint.
|
|
2326
|
+
*/
|
|
2314
2327
|
getUrl(endpoint) {
|
|
2315
2328
|
return `${this.environment.myAppUrl}api/${endpoint}`;
|
|
2316
2329
|
}
|
|
2330
|
+
/**
|
|
2331
|
+
* Obtiene un listado de recursos del endpoint especificado.
|
|
2332
|
+
*
|
|
2333
|
+
* @param endpoint Segmento del endpoint (sin la parte de `api/`).
|
|
2334
|
+
* @param invalidateCache Indica si se invalida la caché del lado del servidor.
|
|
2335
|
+
* @returns Observable con un arreglo de elementos del tipo `T`.
|
|
2336
|
+
*/
|
|
2317
2337
|
list(endpoint, invalidateCache = false) {
|
|
2318
2338
|
return this.http.get(`${this.getUrl(endpoint)}/listar/${invalidateCache}`);
|
|
2319
2339
|
}
|
|
2340
|
+
/**
|
|
2341
|
+
* Obtiene un recurso por su identificador.
|
|
2342
|
+
*
|
|
2343
|
+
* @param endpoint Segmento del endpoint (sin la parte de `api/`).
|
|
2344
|
+
* @param id Identificador del recurso a recuperar.
|
|
2345
|
+
* @returns Observable con el elemento del tipo `T`.
|
|
2346
|
+
*/
|
|
2320
2347
|
edit(endpoint, id) {
|
|
2321
2348
|
return this.http.get(`${this.getUrl(endpoint)}/get-id/${id}`);
|
|
2322
2349
|
}
|
|
2350
|
+
/**
|
|
2351
|
+
* Crea o actualiza un recurso en el endpoint especificado.
|
|
2352
|
+
*
|
|
2353
|
+
* @param endpoint Segmento del endpoint (sin la parte de `api/`).
|
|
2354
|
+
* @param values Objeto con los datos del recurso a guardar.
|
|
2355
|
+
* @returns Observable con el resultado del servicio que envuelve al tipo `T`.
|
|
2356
|
+
*/
|
|
2323
2357
|
save(endpoint, values) {
|
|
2324
2358
|
return this.http.put(`${this.getUrl(endpoint)}/save`, values);
|
|
2325
2359
|
}
|
|
2360
|
+
/**
|
|
2361
|
+
* Elimina un recurso del endpoint especificado.
|
|
2362
|
+
*
|
|
2363
|
+
* @param endpoint Segmento del endpoint (sin la parte de `api/`).
|
|
2364
|
+
* @param id Identificador del recurso a eliminar.
|
|
2365
|
+
* @param softDelete Indica si la eliminación es lógica (por defecto) o física.
|
|
2366
|
+
* @returns Observable con el modelo de respuesta HTTP genérico.
|
|
2367
|
+
*/
|
|
2326
2368
|
delete(endpoint, id, softDelete = true) {
|
|
2327
2369
|
return this.http.delete(`${this.getUrl(endpoint)}/delete/${id}/${softDelete}`);
|
|
2328
2370
|
}
|