monkey-front-core 0.0.284 → 0.0.286

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.
@@ -1,7 +1,7 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { Component, Input, NgModule, Pipe, ViewEncapsulation, Injectable, EventEmitter, Directive, Output, HostBinding, HostListener, forwardRef, Self, InjectionToken, Inject, Optional, SkipSelf, NgZone, ErrorHandler } from '@angular/core';
3
3
  import * as i1 from 'monkey-style-guide';
4
- import { MonkeyButtonModule, MonkeyModalModule, MonkeyIconModule, MonkeyInputModule, MonkeyUtils, MonkeyStyleGuideModule, MonkeyStyleGuideModalService, MonkeyStyleGuideSettingsService, MonkeyStyleGuideSnackbarService } from 'monkey-style-guide';
4
+ import { MonkeyButtonModule, MonkeyModalModule, MonkeyIconModule, MonkeyInputModule, MonkeyRadioButtonModule, MonkeyOptionModule, MonkeyUtils, MonkeyStyleGuideModule, MonkeyStyleGuideModalService, MonkeyStyleGuideSettingsService, MonkeyStyleGuideSnackbarService } from 'monkey-style-guide';
5
5
  import * as i2 from '@angular/common';
6
6
  import { CommonModule, formatNumber, CurrencyPipe } from '@angular/common';
7
7
  import * as i1$1 from '@ngx-translate/core';
@@ -1693,6 +1693,72 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
1693
1693
  }]
1694
1694
  }] });
1695
1695
 
1696
+ class CurrencyConfigComponent {
1697
+ constructor(modalService) {
1698
+ this.modalService = modalService;
1699
+ this.config = null;
1700
+ this._currency = 'BRL';
1701
+ this._currencies = ['BRL'];
1702
+ this.callback = () => { };
1703
+ // not to do
1704
+ }
1705
+ ngOnInit() {
1706
+ const { config } = this;
1707
+ this._currency = config?.data?.currency;
1708
+ this._currencies = config?.data?.currencies;
1709
+ this.callback = config?.data?.callback;
1710
+ }
1711
+ onClose() {
1712
+ this.modalService.close(this.modalRef);
1713
+ this.callback?.(this._currency);
1714
+ }
1715
+ onHandleChangeCurrency(currency) {
1716
+ this._currency = currency;
1717
+ }
1718
+ }
1719
+ CurrencyConfigComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: CurrencyConfigComponent, deps: [{ token: i1.MonkeyStyleGuideModalService }], target: i0.ɵɵFactoryTarget.Component });
1720
+ CurrencyConfigComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.1", type: CurrencyConfigComponent, selector: "monkeyecx-currency-config", inputs: { config: "config", modalRef: "modalRef" }, ngImport: i0, template: "<monkey-modal [config]=\"config\" [modalRef]=\"modalRef\" *ngIf=\"config\">\r\n <div class=\"alert-body\">\r\n <span class=\"title\">\r\n {{ 'MECX-ALERTS.CONFIG.CURRENCY.TITLE' | translate }}\r\n </span>\r\n <span class=\"message\">\r\n {{ 'MECX-ALERTS.CONFIG.CURRENCY.SUB-TITLE' | translate }}\r\n </span>\r\n <monkey-radiobutton [value]=\"_currency\"\r\n (onChange)=\"onHandleChangeCurrency($event)\">\r\n <monkey-option \r\n [label]=\"'CURRENCIES.'+currency | translate\"\r\n [value]=\"currency\"\r\n *ngFor=\"let currency of _currencies\">\r\n </monkey-option>\r\n </monkey-radiobutton>\r\n <span class=\"info\">\r\n {{ 'MECX-ALERTS.CONFIG.CURRENCY.INFO' | translate }}\r\n </span>\r\n </div>\r\n <div class=\"alert-footer\">\r\n <monkey-button type=\"tertiary\" color=\"theme\" (click)=\"onClose()\">\r\n {{ 'BUTTONS.CONFIRM' | translate }}\r\n </monkey-button>\r\n </div>\r\n</monkey-modal>", styles: [":host ::ng-deep monkey-modal mecx-monkey-modal{padding:0}:host ::ng-deep monkey-modal mecx-monkey-modal .body{margin-bottom:0}:host ::ng-deep monkey-modal .mecx-monkey-modal__size-md{max-width:448px}:host ::ng-deep mecx-form-field mecx-form-field-footer{display:none}:host ::ng-deep monkey-radiobutton mecx-form-field mecx-form-field-body.radiobutton{gap:12px}:host .alert-header{height:100%}@media screen and (max-width: 959px){:host .alert-header{min-height:212px}}:host .alert-header img{border-radius:12px 12px 0 0;-o-object-fit:cover;object-fit:cover;width:100%;max-height:280px}@media screen and (max-width: 959px){:host .alert-header img{height:200px}}:host .alert-body{display:flex;flex-direction:column;gap:16px;padding:24px;margin:auto}:host .alert-body .title{font-style:normal;font-weight:700;font-size:32px;line-height:40px;color:#1f2024}:host .alert-body .message{font-style:normal;font-weight:400;font-size:16px;line-height:24px;letter-spacing:.03em;color:#545a63}:host .alert-body .info{color:#9a9ca1;line-height:24px;font-size:14px}:host .alert-footer{display:flex;justify-content:flex-end;align-items:center;padding:0 24px 24px;position:sticky;bottom:0;background:#fafafa}\n"], components: [{ type: i1.MonkeyModalComponent, selector: "monkey-modal", inputs: ["config", "modalRef", "onHandleConfirm"] }, { type: i1.MonkeyRadioButtonComponent, selector: "monkey-radiobutton", inputs: ["label", "helperMessage", "placeholder", "icon", "infoMessage", "errorMessage", "value"], outputs: ["onChange"] }, { type: i1.MonkeyOptionComponent, selector: "monkey-option", inputs: ["type", "label", "value", "selectAll", "selected", "enableClick"], outputs: ["onSelectOption"] }, { type: i1.MonkeyButtonComponent, selector: "monkey-button", inputs: ["label", "icon", "iconPosition", "type", "color", "disabled", "size"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], pipes: { "translate": i1$1.TranslatePipe } });
1721
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: CurrencyConfigComponent, decorators: [{
1722
+ type: Component,
1723
+ args: [{ selector: 'monkeyecx-currency-config', template: "<monkey-modal [config]=\"config\" [modalRef]=\"modalRef\" *ngIf=\"config\">\r\n <div class=\"alert-body\">\r\n <span class=\"title\">\r\n {{ 'MECX-ALERTS.CONFIG.CURRENCY.TITLE' | translate }}\r\n </span>\r\n <span class=\"message\">\r\n {{ 'MECX-ALERTS.CONFIG.CURRENCY.SUB-TITLE' | translate }}\r\n </span>\r\n <monkey-radiobutton [value]=\"_currency\"\r\n (onChange)=\"onHandleChangeCurrency($event)\">\r\n <monkey-option \r\n [label]=\"'CURRENCIES.'+currency | translate\"\r\n [value]=\"currency\"\r\n *ngFor=\"let currency of _currencies\">\r\n </monkey-option>\r\n </monkey-radiobutton>\r\n <span class=\"info\">\r\n {{ 'MECX-ALERTS.CONFIG.CURRENCY.INFO' | translate }}\r\n </span>\r\n </div>\r\n <div class=\"alert-footer\">\r\n <monkey-button type=\"tertiary\" color=\"theme\" (click)=\"onClose()\">\r\n {{ 'BUTTONS.CONFIRM' | translate }}\r\n </monkey-button>\r\n </div>\r\n</monkey-modal>", styles: [":host ::ng-deep monkey-modal mecx-monkey-modal{padding:0}:host ::ng-deep monkey-modal mecx-monkey-modal .body{margin-bottom:0}:host ::ng-deep monkey-modal .mecx-monkey-modal__size-md{max-width:448px}:host ::ng-deep mecx-form-field mecx-form-field-footer{display:none}:host ::ng-deep monkey-radiobutton mecx-form-field mecx-form-field-body.radiobutton{gap:12px}:host .alert-header{height:100%}@media screen and (max-width: 959px){:host .alert-header{min-height:212px}}:host .alert-header img{border-radius:12px 12px 0 0;-o-object-fit:cover;object-fit:cover;width:100%;max-height:280px}@media screen and (max-width: 959px){:host .alert-header img{height:200px}}:host .alert-body{display:flex;flex-direction:column;gap:16px;padding:24px;margin:auto}:host .alert-body .title{font-style:normal;font-weight:700;font-size:32px;line-height:40px;color:#1f2024}:host .alert-body .message{font-style:normal;font-weight:400;font-size:16px;line-height:24px;letter-spacing:.03em;color:#545a63}:host .alert-body .info{color:#9a9ca1;line-height:24px;font-size:14px}:host .alert-footer{display:flex;justify-content:flex-end;align-items:center;padding:0 24px 24px;position:sticky;bottom:0;background:#fafafa}\n"] }]
1724
+ }], ctorParameters: function () { return [{ type: i1.MonkeyStyleGuideModalService }]; }, propDecorators: { config: [{
1725
+ type: Input
1726
+ }], modalRef: [{
1727
+ type: Input
1728
+ }] } });
1729
+
1730
+ class CurrencyConfigModule {
1731
+ }
1732
+ CurrencyConfigModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: CurrencyConfigModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1733
+ CurrencyConfigModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: CurrencyConfigModule, declarations: [CurrencyConfigComponent], imports: [CommonModule,
1734
+ MonkeyButtonModule,
1735
+ MonkeyRadioButtonModule,
1736
+ MonkeyOptionModule,
1737
+ MonkeyModalModule, i1$1.TranslateModule], exports: [CurrencyConfigComponent] });
1738
+ CurrencyConfigModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: CurrencyConfigModule, imports: [[
1739
+ CommonModule,
1740
+ MonkeyButtonModule,
1741
+ MonkeyRadioButtonModule,
1742
+ MonkeyOptionModule,
1743
+ MonkeyModalModule,
1744
+ TranslateModule.forChild()
1745
+ ]] });
1746
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: CurrencyConfigModule, decorators: [{
1747
+ type: NgModule,
1748
+ args: [{
1749
+ declarations: [CurrencyConfigComponent],
1750
+ imports: [
1751
+ CommonModule,
1752
+ MonkeyButtonModule,
1753
+ MonkeyRadioButtonModule,
1754
+ MonkeyOptionModule,
1755
+ MonkeyModalModule,
1756
+ TranslateModule.forChild()
1757
+ ],
1758
+ exports: [CurrencyConfigComponent]
1759
+ }]
1760
+ }] });
1761
+
1696
1762
  /* eslint-disable space-before-function-paren */
1697
1763
  /* eslint-disable func-names */
1698
1764
  function MonkeyEcxCoreCharts(render = true) {
@@ -5207,7 +5273,8 @@ MonkeyFrontCoreModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", ve
5207
5273
  MonkeyFrontCoreModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: MonkeyFrontCoreModule, imports: [CommonModule,
5208
5274
  HttpClientModule, i1$1.TranslateModule, MonkeyEcxConfigModule, MonkeyEcxHttpConfigInterceptorModule, MonkeyEcxErrorHandlingModule, MonkeyStyleGuideModule, i1$6.ServiceWorkerModule, ClosedToMaintenanceModule,
5209
5275
  VersionChangedModule,
5210
- AlertsModule] });
5276
+ AlertsModule,
5277
+ CurrencyConfigModule] });
5211
5278
  MonkeyFrontCoreModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: MonkeyFrontCoreModule, providers: [
5212
5279
  MonkeyStyleGuideModalService,
5213
5280
  MonkeyStyleGuideSettingsService,
@@ -5223,7 +5290,8 @@ MonkeyFrontCoreModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", v
5223
5290
  ServiceWorkerModule.register('ngsw-worker.js'),
5224
5291
  ClosedToMaintenanceModule,
5225
5292
  VersionChangedModule,
5226
- AlertsModule
5293
+ AlertsModule,
5294
+ CurrencyConfigModule
5227
5295
  ]] });
5228
5296
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: MonkeyFrontCoreModule, decorators: [{
5229
5297
  type: NgModule,
@@ -5239,7 +5307,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
5239
5307
  ServiceWorkerModule.register('ngsw-worker.js'),
5240
5308
  ClosedToMaintenanceModule,
5241
5309
  VersionChangedModule,
5242
- AlertsModule
5310
+ AlertsModule,
5311
+ CurrencyConfigModule
5243
5312
  ],
5244
5313
  providers: [
5245
5314
  MonkeyStyleGuideModalService,
@@ -5257,5 +5326,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
5257
5326
  * Generated bundle index. Do not edit.
5258
5327
  */
5259
5328
 
5260
- export { AlertsComponent, AlertsModule, ClosedToMaintenanceComponent, ClosedToMaintenanceModule, decoratorsUtils as DecoratorsUtils, Link, MonkeyEcxAlertsService, MonkeyEcxAuthGuard, MonkeyEcxAuthGuardCompany, MonkeyEcxAuthGuardLogin, MonkeyEcxAuthenticationService, MonkeyEcxBlobSecurePipe, MonkeyEcxCommonsService, MonkeyEcxConfigModule, MonkeyEcxConfigService, MonkeyEcxCookieStorageService, MonkeyEcxCoreCharts, MonkeyEcxCoreClearDecorators, MonkeyEcxCoreLog, MonkeyEcxCoreService, MonkeyEcxCoreServiceConstructor, MonkeyEcxCoreServicePaged, MonkeyEcxCoreServiceQueue, MonkeyEcxDirectivesModule, MonkeyEcxDiscoveryParamsService, MonkeyEcxDisplayFirstNamePipe, MonkeyEcxDisplayInitialsPipe, MonkeyEcxDragDropDirective, MonkeyEcxErrorConfigService, MonkeyEcxErrorHandlingModule, MonkeyEcxErrorHandlingService, MonkeyEcxFeatureByProgramDirective, MonkeyEcxFeatureDirective, MonkeyEcxFeatureToggleService, MonkeyEcxFormatAddressPipe, MonkeyEcxFormatBeaufityJSONPipe, MonkeyEcxFormatCurrency, MonkeyEcxFormatCurrencyPipe, MonkeyEcxFormatDateGroupPipe, MonkeyEcxFormatDateTimelapsePipe, MonkeyEcxFormatDateUnixTimelapsePipe, MonkeyEcxFormatDocumentPipe, MonkeyEcxFormatDocumentTypePipe, MonkeyEcxFormatNumberPipe, MonkeyEcxFormatPhonePipe, MonkeyEcxFormatSizePipe, MonkeyEcxFormatTaxPipe, MonkeyEcxFormatUpper, MonkeyEcxFormatValue, MonkeyEcxFormatZipCodePipe, MonkeyEcxHandlingService, MonkeyEcxHttpConfigErrorInterceptor, MonkeyEcxHttpConfigHeaderInterceptor, MonkeyEcxHttpConfigInterceptorModule, MonkeyEcxHttpConfigLoadingInProgressInterceptor, MonkeyEcxHttpConfigQueueInterceptor, MonkeyEcxHttpErrorHandlingService, MonkeyEcxLoggedHandlingService, MonkeyEcxLogsConfigService, MonkeyEcxMaintenanceConfigService, MonkeyEcxModel, MonkeyEcxOnlyAlphaNumericDirective, MonkeyEcxOnlyNumbersDirective, MonkeyEcxOthersErrorsHandlingService, MonkeyEcxPaginationService, MonkeyEcxPipesModule, MonkeyEcxPopoverDirective, MonkeyEcxPopoverOptionsDirective, MonkeyEcxProgressBarComponent, MonkeyEcxProgressBarModule, MonkeyEcxProgressBarService, MonkeyEcxRequestDownloadHandlingService, MonkeyEcxRequestDownloadedHandlingService, MonkeyEcxRequestPagedHandling, MonkeyEcxRequestQueueHandlingService, MonkeyEcxRequestQueueModalHandlingService, MonkeyEcxRequestScheduleService, MonkeyEcxSecurityConsoleConfigService, MonkeyEcxSecurityDirective, MonkeyEcxService, MonkeyEcxServiceDownload, MonkeyEcxServiceUpload, MonkeyEcxServiceWorkerConfigService, MonkeyEcxSpecificationSearch, MonkeyEcxTextTruncatePipe, MonkeyEcxTokenStorageService, MonkeyEcxTooltipDirective, MonkeyEcxTruncateQtdPipe, MonkeyEcxUtils, MonkeyEcxi18nConfigService, MonkeyFrontCoreModule, OpSearch, POPOVER_OPTIONS, statics as Statics, validateUtils as ValidateUtils, Validators, VersionChangedComponent, VersionChangedModule, comboValidator, dateRangeValidator, dateStartEndValidator, dateValidator, documentValidator, emailValidator, passwordConfirmValidator, registerValidator, trueValidator, urlValidator, valueGreaterThanZero, zipCodeValidator };
5329
+ export { AlertsComponent, AlertsModule, ClosedToMaintenanceComponent, ClosedToMaintenanceModule, CurrencyConfigComponent, CurrencyConfigModule, decoratorsUtils as DecoratorsUtils, Link, MonkeyEcxAlertsService, MonkeyEcxAuthGuard, MonkeyEcxAuthGuardCompany, MonkeyEcxAuthGuardLogin, MonkeyEcxAuthenticationService, MonkeyEcxBlobSecurePipe, MonkeyEcxCommonsService, MonkeyEcxConfigModule, MonkeyEcxConfigService, MonkeyEcxCookieStorageService, MonkeyEcxCoreCharts, MonkeyEcxCoreClearDecorators, MonkeyEcxCoreLog, MonkeyEcxCoreService, MonkeyEcxCoreServiceConstructor, MonkeyEcxCoreServicePaged, MonkeyEcxCoreServiceQueue, MonkeyEcxDirectivesModule, MonkeyEcxDiscoveryParamsService, MonkeyEcxDisplayFirstNamePipe, MonkeyEcxDisplayInitialsPipe, MonkeyEcxDragDropDirective, MonkeyEcxErrorConfigService, MonkeyEcxErrorHandlingModule, MonkeyEcxErrorHandlingService, MonkeyEcxFeatureByProgramDirective, MonkeyEcxFeatureDirective, MonkeyEcxFeatureToggleService, MonkeyEcxFormatAddressPipe, MonkeyEcxFormatBeaufityJSONPipe, MonkeyEcxFormatCurrency, MonkeyEcxFormatCurrencyPipe, MonkeyEcxFormatDateGroupPipe, MonkeyEcxFormatDateTimelapsePipe, MonkeyEcxFormatDateUnixTimelapsePipe, MonkeyEcxFormatDocumentPipe, MonkeyEcxFormatDocumentTypePipe, MonkeyEcxFormatNumberPipe, MonkeyEcxFormatPhonePipe, MonkeyEcxFormatSizePipe, MonkeyEcxFormatTaxPipe, MonkeyEcxFormatUpper, MonkeyEcxFormatValue, MonkeyEcxFormatZipCodePipe, MonkeyEcxHandlingService, MonkeyEcxHttpConfigErrorInterceptor, MonkeyEcxHttpConfigHeaderInterceptor, MonkeyEcxHttpConfigInterceptorModule, MonkeyEcxHttpConfigLoadingInProgressInterceptor, MonkeyEcxHttpConfigQueueInterceptor, MonkeyEcxHttpErrorHandlingService, MonkeyEcxLoggedHandlingService, MonkeyEcxLogsConfigService, MonkeyEcxMaintenanceConfigService, MonkeyEcxModel, MonkeyEcxOnlyAlphaNumericDirective, MonkeyEcxOnlyNumbersDirective, MonkeyEcxOthersErrorsHandlingService, MonkeyEcxPaginationService, MonkeyEcxPipesModule, MonkeyEcxPopoverDirective, MonkeyEcxPopoverOptionsDirective, MonkeyEcxProgressBarComponent, MonkeyEcxProgressBarModule, MonkeyEcxProgressBarService, MonkeyEcxRequestDownloadHandlingService, MonkeyEcxRequestDownloadedHandlingService, MonkeyEcxRequestPagedHandling, MonkeyEcxRequestQueueHandlingService, MonkeyEcxRequestQueueModalHandlingService, MonkeyEcxRequestScheduleService, MonkeyEcxSecurityConsoleConfigService, MonkeyEcxSecurityDirective, MonkeyEcxService, MonkeyEcxServiceDownload, MonkeyEcxServiceUpload, MonkeyEcxServiceWorkerConfigService, MonkeyEcxSpecificationSearch, MonkeyEcxTextTruncatePipe, MonkeyEcxTokenStorageService, MonkeyEcxTooltipDirective, MonkeyEcxTruncateQtdPipe, MonkeyEcxUtils, MonkeyEcxi18nConfigService, MonkeyFrontCoreModule, OpSearch, POPOVER_OPTIONS, statics as Statics, validateUtils as ValidateUtils, Validators, VersionChangedComponent, VersionChangedModule, comboValidator, dateRangeValidator, dateStartEndValidator, dateValidator, documentValidator, emailValidator, passwordConfirmValidator, registerValidator, trueValidator, urlValidator, valueGreaterThanZero, zipCodeValidator };
5261
5330
  //# sourceMappingURL=monkey-front-core.mjs.map