@anglr/common 21.3.0 → 22.0.0-beta.20250123101532
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/changelog.md +20 -0
- package/es2022/floating-ui/src/services/floatingUiDomPosition.service.js +5 -4
- package/es2022/floating-ui/src/services/floatingUiDomPosition.service.js.map +1 -1
- package/es2022/forms/src/components/defaultValidationErrors/defaultValidationErrors.component.js +4 -4
- package/es2022/forms/src/components/defaultValidationErrors/defaultValidationErrors.component.js.map +1 -1
- package/es2022/forms/src/components/defaultValidationErrorsContainer/defaultValidationErrorsContainer.component.js +4 -4
- package/es2022/forms/src/components/defaultValidationErrorsContainer/defaultValidationErrorsContainer.component.js.map +1 -1
- package/es2022/forms/src/components/reservedSpaceValidationErrorsContainer/reservedSpaceValidationErrorsContainer.component.js +4 -4
- package/es2022/forms/src/components/reservedSpaceValidationErrorsContainer/reservedSpaceValidationErrorsContainer.component.js.map +1 -1
- package/es2022/forms/src/directives/groupHasError/groupHasError.directive.js +4 -5
- package/es2022/forms/src/directives/groupHasError/groupHasError.directive.js.map +1 -1
- package/es2022/forms/src/directives/groupHasErrorContainer/groupHasErrorContainer.directive.js +3 -4
- package/es2022/forms/src/directives/groupHasErrorContainer/groupHasErrorContainer.directive.js.map +1 -1
- package/es2022/forms/src/directives/hasError/hasError.directive.js +3 -4
- package/es2022/forms/src/directives/hasError/hasError.directive.js.map +1 -1
- package/es2022/forms/src/directives/numberInput/maxValueNumberValidator.directive.js +5 -5
- package/es2022/forms/src/directives/numberInput/maxValueNumberValidator.directive.js.map +1 -1
- package/es2022/forms/src/directives/numberInput/minValueNumberValidator.directive.js +5 -5
- package/es2022/forms/src/directives/numberInput/minValueNumberValidator.directive.js.map +1 -1
- package/es2022/forms/src/directives/numberInput/numberInputControlValueAccessor.directive.js +4 -4
- package/es2022/forms/src/directives/numberInput/numberInputControlValueAccessor.directive.js.map +1 -1
- package/es2022/forms/src/directives/numberInput/numberInputValidator.directive.js +5 -5
- package/es2022/forms/src/directives/numberInput/numberInputValidator.directive.js.map +1 -1
- package/es2022/forms/src/directives/requiredClass/requiredClass.directive.js +3 -4
- package/es2022/forms/src/directives/requiredClass/requiredClass.directive.js.map +1 -1
- package/es2022/forms/src/directives/validationErrorsContainer/validationErrorsContainer.directive.js +3 -4
- package/es2022/forms/src/directives/validationErrorsContainer/validationErrorsContainer.directive.js.map +1 -1
- package/es2022/forms/src/misc/utils.js +2 -1
- package/es2022/forms/src/misc/utils.js.map +1 -1
- package/es2022/forms/src/modules/errorMessage/components/groupErrors/groupErrors.component.js +14 -9
- package/es2022/forms/src/modules/errorMessage/components/groupErrors/groupErrors.component.js.map +1 -1
- package/es2022/forms/src/modules/errorMessage/directives/errorMessage/errorMessage.directive.js +4 -4
- package/es2022/forms/src/modules/errorMessage/directives/errorMessage/errorMessage.directive.js.map +1 -1
- package/es2022/forms/src/modules/errorMessage/directives/groupErrorsTemplate/groupErrorsTemplate.directive.js +4 -4
- package/es2022/forms/src/modules/errorMessage/directives/groupErrorsTemplate/groupErrorsTemplate.directive.js.map +1 -1
- package/es2022/forms/src/modules/errorMessage/modules/errorMessage.module.js +5 -13
- package/es2022/forms/src/modules/errorMessage/modules/errorMessage.module.js.map +1 -1
- package/es2022/forms/src/modules/errorMessage/pipes/withErrorMessage/withErrorMessage.pipe.js +3 -3
- package/es2022/forms/src/modules/formPipes/modules/formPipes.module.js +5 -5
- package/es2022/forms/src/modules/formPipes/modules/formPipes.module.js.map +1 -1
- package/es2022/forms/src/modules/formPipes/pipes/asFormArray/asFormArray.pipe.js +3 -3
- package/es2022/forms/src/modules/formPipes/pipes/asFormControl/asFormControl.pipe.js +3 -3
- package/es2022/forms/src/modules/formPipes/pipes/asFormGroup/asFormGroup.pipe.js +3 -3
- package/es2022/forms/src/modules/formPipes/pipes/getControl/getControl.pipe.js +3 -3
- package/es2022/forms/src/modules/hasError.module.js +4 -4
- package/es2022/forms/src/modules/numberInput.module.js +7 -7
- package/es2022/forms/src/modules/numberInput.module.js.map +1 -1
- package/es2022/forms/src/services/errorMessagesExtractor/errorMessagesExtractor.service.js +5 -4
- package/es2022/forms/src/services/errorMessagesExtractor/errorMessagesExtractor.service.js.map +1 -1
- package/es2022/forms/src/services/formModelBuilder/formModelBuilder.service.js +3 -3
- package/es2022/forms/src/services/submitted/submitted.service.js +3 -3
- package/es2022/forms/src/services/validationErrorRenderer/validationErrorRenderer.service.js +4 -4
- package/es2022/forms/src/services/validationErrorRenderer/validationErrorRenderer.service.js.map +1 -1
- package/es2022/hotkeys/src/components/cheatSheet/cheatSheet.component.js +4 -4
- package/es2022/hotkeys/src/components/cheatSheet/cheatSheet.component.js.map +1 -1
- package/es2022/hotkeys/src/services/appHotkeys.service.js +3 -3
- package/es2022/material/src/components/confirmationDialog/confirmationDialog.component.js +10 -7
- package/es2022/material/src/components/confirmationDialog/confirmationDialog.component.js.map +1 -1
- package/es2022/material/src/components/movableTitledDialog/movableTitledDialog.component.js +12 -7
- package/es2022/material/src/components/movableTitledDialog/movableTitledDialog.component.js.map +1 -1
- package/es2022/material/src/components/titledDialog/titledDialog.component.js +9 -6
- package/es2022/material/src/components/titledDialog/titledDialog.component.js.map +1 -1
- package/es2022/material/src/directives/confirmationDialog/confirmationDialog.directive.js +3 -4
- package/es2022/material/src/directives/confirmationDialog/confirmationDialog.directive.js.map +1 -1
- package/es2022/material/src/directives/debugDataCopyClick/debugDataCopyClick.directive.js +3 -4
- package/es2022/material/src/directives/debugDataCopyClick/debugDataCopyClick.directive.js.map +1 -1
- package/es2022/material/src/modules/confirmationDialog.module.js +6 -15
- package/es2022/material/src/modules/confirmationDialog.module.js.map +1 -1
- package/es2022/material/src/modules/debugDataCopyClick.module.js +4 -4
- package/es2022/material/src/modules/movableTitledDialog.module.js +7 -8
- package/es2022/material/src/modules/movableTitledDialog.module.js.map +1 -1
- package/es2022/material/src/modules/titledDialog.module.js +5 -16
- package/es2022/material/src/modules/titledDialog.module.js.map +1 -1
- package/es2022/material/src/services/titledDialog/titledDialog.service.js +3 -3
- package/es2022/router/src/services/routing/dataRouter.js +3 -3
- package/es2022/router/src/services/routing/dataRouterData.js +3 -3
- package/es2022/src/components/collapsibleIcon/collapsibleIcon.component.js +6 -6
- package/es2022/src/components/collapsibleIcon/collapsibleIcon.component.js.map +1 -1
- package/es2022/src/components/collapsibleTitle/collapsibleTitle.component.js +4 -4
- package/es2022/src/components/collapsibleTitle/collapsibleTitle.component.js.map +1 -1
- package/es2022/src/decorators/asSignal/asSignal.decorator.js.map +1 -1
- package/es2022/src/decorators/componentDisplay/componentDisplay.decorator.js.map +1 -1
- package/es2022/src/decorators/componentDisplayBlock/componentDisplayBlock.decorator.js.map +1 -1
- package/es2022/src/decorators/componentDisplayFlex/componentDisplayFlex.decorator.js.map +1 -1
- package/es2022/src/decorators/componentHostStyle/componentHostStyle.decorator.js.map +1 -1
- package/es2022/src/decorators/scrollableContent/scrollableContent.decorator.js.map +1 -1
- package/es2022/src/decorators/typeProvider/typeProvider.decorator.js +0 -1
- package/es2022/src/decorators/typeProvider/typeProvider.decorator.js.map +1 -1
- package/es2022/src/decorators/withFullscreenContentCssClass/withFullscreenContentCssClass.decorator.js.map +1 -1
- package/es2022/src/directives/bodyRender/bodyRender.directive.js +3 -4
- package/es2022/src/directives/bodyRender/bodyRender.directive.js.map +1 -1
- package/es2022/src/directives/clickOutside/clickOutside.directive.js +4 -5
- package/es2022/src/directives/clickOutside/clickOutside.directive.js.map +1 -1
- package/es2022/src/directives/ellipsisTooltip/ellipsisTooltip.directive.js +3 -4
- package/es2022/src/directives/ellipsisTooltip/ellipsisTooltip.directive.js.map +1 -1
- package/es2022/src/directives/goBack/goBack.directive.js +3 -4
- package/es2022/src/directives/goBack/goBack.directive.js.map +1 -1
- package/es2022/src/directives/ngComponentOutletEx/ngComponentOutletEx.directive.js +3 -4
- package/es2022/src/directives/ngComponentOutletEx/ngComponentOutletEx.directive.js.map +1 -1
- package/es2022/src/directives/positionTo/positionTo.directive.js +4 -5
- package/es2022/src/directives/positionTo/positionTo.directive.js.map +1 -1
- package/es2022/src/modules/castPipes/modules/castPipes.module.js +5 -5
- package/es2022/src/modules/castPipes/modules/castPipes.module.js.map +1 -1
- package/es2022/src/modules/castPipes/pipes/asHtmlElement/asHtmlElement.pipe.js +3 -3
- package/es2022/src/modules/castPipes/pipes/asNgClassRequired/asNgClassRequired.pipe.js +3 -3
- package/es2022/src/modules/castPipes/pipes/asRequired/asRequired.pipe.js +3 -3
- package/es2022/src/modules/castPipes/pipes/castType/castType.pipe.js +3 -3
- package/es2022/src/modules/commonDynamic.module.js +4 -4
- package/es2022/src/modules/commonLocalize.module.js +7 -7
- package/es2022/src/modules/commonLocalize.module.js.map +1 -1
- package/es2022/src/modules/commonUtils.module.js +9 -9
- package/es2022/src/modules/commonUtils.module.js.map +1 -1
- package/es2022/src/modules/debugData/components/debugData/debugData.component.js +4 -4
- package/es2022/src/modules/debugData/components/debugData/debugData.component.js.map +1 -1
- package/es2022/src/modules/debugData/modules/debugData.module.js +4 -4
- package/es2022/src/modules/debugData/services/debugDataEnabled/debugDataEnabled.service.js +3 -3
- package/es2022/src/modules/file/components/file/file.component.js +4 -4
- package/es2022/src/modules/file/components/file/file.component.js.map +1 -1
- package/es2022/src/modules/file/components/fileInput/fileInput.component.js +7 -7
- package/es2022/src/modules/file/components/fileInput/fileInput.component.js.map +1 -1
- package/es2022/src/modules/file/components/uploadButton/uploadButton.component.js +7 -7
- package/es2022/src/modules/file/components/uploadButton/uploadButton.component.js.map +1 -1
- package/es2022/src/modules/file/directive/fileInput/fileInput.directive.js +3 -4
- package/es2022/src/modules/file/directive/fileInput/fileInput.directive.js.map +1 -1
- package/es2022/src/modules/file/directive/fileTemplate/fileTemplate.directive.js +3 -4
- package/es2022/src/modules/file/directive/fileTemplate/fileTemplate.directive.js.map +1 -1
- package/es2022/src/modules/file/modules/file.module.js +4 -4
- package/es2022/src/modules/logger/components/console/console.component.js +5 -5
- package/es2022/src/modules/logger/components/console/console.component.js.map +1 -1
- package/es2022/src/modules/logger/services/console/consoleComponent.service.js +3 -3
- package/es2022/src/modules/logger/services/console/consoleComponentService.options.js +3 -3
- package/es2022/src/modules/logger/services/logger/logger.service.js +3 -3
- package/es2022/src/modules/logger/services/rest/restSink.options.js +3 -3
- package/es2022/src/modules/logger/types/loggerOptions.js +3 -3
- package/es2022/src/modules/multiButton/components/multiButton/multiButton.component.js +9 -7
- package/es2022/src/modules/multiButton/components/multiButton/multiButton.component.js.map +1 -1
- package/es2022/src/modules/multiButton/modules/multiButton.module.js +5 -9
- package/es2022/src/modules/multiButton/modules/multiButton.module.js.map +1 -1
- package/es2022/src/modules/progressIndicator/components/progressIndicator/progressIndicator.component.js +9 -6
- package/es2022/src/modules/progressIndicator/components/progressIndicator/progressIndicator.component.js.map +1 -1
- package/es2022/src/modules/progressIndicator/directives/progressOverlay/progressOverlay.directive.js +4 -4
- package/es2022/src/modules/progressIndicator/directives/progressOverlay/progressOverlay.directive.js.map +1 -1
- package/es2022/src/modules/progressIndicator/interceptors/progressInterceptor.js +4 -4
- package/es2022/src/modules/progressIndicator/interceptors/progressInterceptor.js.map +1 -1
- package/es2022/src/modules/progressIndicator/modules/progressIndicator.module.js +7 -15
- package/es2022/src/modules/progressIndicator/modules/progressIndicator.module.js.map +1 -1
- package/es2022/src/modules/progressIndicator/services/progressIndicator.service.js +3 -3
- package/es2022/src/modules/progressIndicator/services/progressIndicatorOptions.js.map +1 -1
- package/es2022/src/modules/tooltip/components/tooltip/tooltip.component.js +7 -5
- package/es2022/src/modules/tooltip/components/tooltip/tooltip.component.js.map +1 -1
- package/es2022/src/modules/tooltip/directives/tooltip/tooltip.directive.js +5 -5
- package/es2022/src/modules/tooltip/directives/tooltip/tooltip.directive.js.map +1 -1
- package/es2022/src/modules/tooltip/directives/tooltipTemplate/tooltipTemplate.directive.js +3 -3
- package/es2022/src/modules/tooltip/modules/tooltip.module.js +6 -10
- package/es2022/src/modules/tooltip/modules/tooltip.module.js.map +1 -1
- package/es2022/src/pipes/displayProperties/displayProperties.pipe.js +3 -4
- package/es2022/src/pipes/displayProperties/displayProperties.pipe.js.map +1 -1
- package/es2022/src/pipes/firstUppercase/firstUppercase.pipe.js +4 -5
- package/es2022/src/pipes/firstUppercase/firstUppercase.pipe.js.map +1 -1
- package/es2022/src/pipes/firstUppercaseLocalize/firstUppercaseLocalize.pipe.js +8 -9
- package/es2022/src/pipes/firstUppercaseLocalize/firstUppercaseLocalize.pipe.js.map +1 -1
- package/es2022/src/pipes/isNaN/isNaN.pipe.js +3 -4
- package/es2022/src/pipes/isNaN/isNaN.pipe.js.map +1 -1
- package/es2022/src/pipes/isPresent/isPresent.pipe.js +3 -4
- package/es2022/src/pipes/isPresent/isPresent.pipe.js.map +1 -1
- package/es2022/src/pipes/keys/keys.pipe.js +4 -4
- package/es2022/src/pipes/keys/keys.pipe.js.map +1 -1
- package/es2022/src/pipes/localize/localize.pipe.js +4 -5
- package/es2022/src/pipes/localize/localize.pipe.js.map +1 -1
- package/es2022/src/pipes/mergeCssClasses/mergeCssClasses.pipe.js +5 -5
- package/es2022/src/pipes/mergeCssClasses/mergeCssClasses.pipe.js.map +1 -1
- package/es2022/src/pipes/numeral/numeral.pipe.js +4 -4
- package/es2022/src/pipes/numeral/numeral.pipe.js.map +1 -1
- package/es2022/src/pipes/trimText/trimText.pipe.js +4 -4
- package/es2022/src/pipes/trimText/trimText.pipe.js.map +1 -1
- package/es2022/src/pipes/urlEncode/urlEncode.pipe.js +4 -4
- package/es2022/src/pipes/urlEncode/urlEncode.pipe.js.map +1 -1
- package/es2022/src/services/cookies/cookies.service.js +3 -3
- package/es2022/src/services/notifications/defaultNotifications.service.js +3 -3
- package/es2022/src/services/permanentStorage/cookiePermanentStorage.service.js +3 -3
- package/es2022/src/services/statusCode/statusCode.service.js +3 -3
- package/es2022/src/services/stringLocalization/noStringLocalization.service.js +3 -3
- package/es2022/src/services/temporaryStorage/memoryTemporaryStorage.service.js +3 -3
- package/es2022/store/src/services/permanentStorage/localPermanentStorage.service.js +3 -3
- package/es2022/store/src/services/temporaryStorage/sessionTemporaryStorage.service.js +3 -3
- package/eslint.config.js +6 -0
- package/floating-ui/src/services/floatingUiDomPosition.service.d.ts.map +1 -1
- package/forms/src/components/defaultValidationErrors/defaultValidationErrors.component.d.ts.map +1 -1
- package/forms/src/components/defaultValidationErrorsContainer/defaultValidationErrorsContainer.component.d.ts.map +1 -1
- package/forms/src/components/reservedSpaceValidationErrorsContainer/reservedSpaceValidationErrorsContainer.component.d.ts.map +1 -1
- package/forms/src/components/reservedSpaceValidationErrorsContainer/reservedSpaceValidationErrorsContainer.component.html +1 -1
- package/forms/src/directives/groupHasError/groupHasError.directive.d.ts.map +1 -1
- package/forms/src/directives/groupHasErrorContainer/groupHasErrorContainer.directive.d.ts.map +1 -1
- package/forms/src/directives/hasError/hasError.directive.d.ts.map +1 -1
- package/forms/src/directives/numberInput/maxValueNumberValidator.directive.d.ts +1 -1
- package/forms/src/directives/numberInput/minValueNumberValidator.directive.d.ts +1 -1
- package/forms/src/directives/numberInput/numberInputControlValueAccessor.directive.d.ts +1 -1
- package/forms/src/directives/numberInput/numberInputValidator.directive.d.ts +1 -1
- package/forms/src/directives/requiredClass/requiredClass.directive.d.ts.map +1 -1
- package/forms/src/directives/validationErrorsContainer/validationErrorsContainer.directive.d.ts.map +1 -1
- package/forms/src/misc/utils.d.ts.map +1 -1
- package/forms/src/modules/errorMessage/components/groupErrors/groupErrors.component.d.ts +1 -1
- package/forms/src/modules/errorMessage/components/groupErrors/groupErrors.component.d.ts.map +1 -1
- package/forms/src/modules/errorMessage/components/groupErrors/groupErrors.component.html +4 -3
- package/forms/src/modules/errorMessage/directives/errorMessage/errorMessage.directive.d.ts +1 -1
- package/forms/src/modules/errorMessage/directives/groupErrorsTemplate/groupErrorsTemplate.directive.d.ts +1 -1
- package/forms/src/modules/errorMessage/modules/errorMessage.module.d.ts +1 -3
- package/forms/src/modules/errorMessage/modules/errorMessage.module.d.ts.map +1 -1
- package/forms/src/modules/errorMessage/pipes/withErrorMessage/withErrorMessage.pipe.d.ts +1 -1
- package/forms/src/modules/formPipes/modules/formPipes.module.d.ts +1 -1
- package/forms/src/modules/formPipes/pipes/asFormArray/asFormArray.pipe.d.ts +1 -1
- package/forms/src/modules/formPipes/pipes/asFormControl/asFormControl.pipe.d.ts +1 -1
- package/forms/src/modules/formPipes/pipes/asFormGroup/asFormGroup.pipe.d.ts +1 -1
- package/forms/src/modules/formPipes/pipes/getControl/getControl.pipe.d.ts +1 -1
- package/forms/src/modules/numberInput.module.d.ts +1 -1
- package/forms/src/services/errorMessagesExtractor/errorMessagesExtractor.service.d.ts.map +1 -1
- package/forms/src/services/validationErrorRenderer/validationErrorRenderer.service.d.ts.map +1 -1
- package/hotkeys/src/components/cheatSheet/cheatSheet.component.d.ts.map +1 -1
- package/material/src/components/confirmationDialog/confirmationDialog.component.d.ts +1 -1
- package/material/src/components/confirmationDialog/confirmationDialog.component.d.ts.map +1 -1
- package/material/src/components/movableTitledDialog/movableTitledDialog.component.d.ts +1 -1
- package/material/src/components/movableTitledDialog/movableTitledDialog.component.d.ts.map +1 -1
- package/material/src/components/movableTitledDialog/movableTitledDialog.component.html +1 -1
- package/material/src/components/titledDialog/titledDialog.component.d.ts +1 -1
- package/material/src/components/titledDialog/titledDialog.component.d.ts.map +1 -1
- package/material/src/components/titledDialog/titledDialog.component.html +2 -2
- package/material/src/directives/confirmationDialog/confirmationDialog.directive.d.ts.map +1 -1
- package/material/src/directives/debugDataCopyClick/debugDataCopyClick.directive.d.ts.map +1 -1
- package/material/src/modules/confirmationDialog.module.d.ts +4 -6
- package/material/src/modules/confirmationDialog.module.d.ts.map +1 -1
- package/material/src/modules/movableTitledDialog.module.d.ts +5 -5
- package/material/src/modules/movableTitledDialog.module.d.ts.map +1 -1
- package/material/src/modules/titledDialog.module.d.ts +2 -4
- package/material/src/modules/titledDialog.module.d.ts.map +1 -1
- package/package.json +44 -44
- package/router/src/decorators/moduleRoutes.decorator.d.ts.map +1 -1
- package/src/components/collapsibleIcon/collapsibleIcon.component.d.ts.map +1 -1
- package/src/components/collapsibleTitle/collapsibleTitle.component.d.ts.map +1 -1
- package/src/decorators/typeProvider/typeProvider.decorator.d.ts.map +1 -1
- package/src/directives/bodyRender/bodyRender.directive.d.ts.map +1 -1
- package/src/directives/clickOutside/clickOutside.directive.d.ts +3 -3
- package/src/directives/clickOutside/clickOutside.directive.d.ts.map +1 -1
- package/src/directives/ellipsisTooltip/ellipsisTooltip.directive.d.ts.map +1 -1
- package/src/directives/goBack/goBack.directive.d.ts.map +1 -1
- package/src/directives/ngComponentOutletEx/ngComponentOutletEx.directive.d.ts.map +1 -1
- package/src/directives/positionTo/positionTo.directive.d.ts +3 -3
- package/src/directives/positionTo/positionTo.directive.d.ts.map +1 -1
- package/src/modules/castPipes/modules/castPipes.module.d.ts +1 -1
- package/src/modules/castPipes/pipes/asHtmlElement/asHtmlElement.pipe.d.ts +1 -1
- package/src/modules/castPipes/pipes/asNgClassRequired/asNgClassRequired.pipe.d.ts +1 -1
- package/src/modules/castPipes/pipes/asRequired/asRequired.pipe.d.ts +1 -1
- package/src/modules/castPipes/pipes/castType/castType.pipe.d.ts +1 -1
- package/src/modules/commonLocalize.module.d.ts +1 -1
- package/src/modules/commonUtils.module.d.ts +1 -1
- package/src/modules/debugData/components/debugData/debugData.component.d.ts.map +1 -1
- package/src/modules/file/components/file/file.component.d.ts.map +1 -1
- package/src/modules/file/components/fileInput/fileInput.component.d.ts.map +1 -1
- package/src/modules/file/components/uploadButton/uploadButton.component.d.ts.map +1 -1
- package/src/modules/file/directive/fileInput/fileInput.directive.d.ts.map +1 -1
- package/src/modules/file/directive/fileTemplate/fileTemplate.directive.d.ts.map +1 -1
- package/src/modules/logger/components/console/console.component.d.ts +3 -3
- package/src/modules/logger/components/console/console.component.d.ts.map +1 -1
- package/src/modules/multiButton/components/multiButton/multiButton.component.d.ts +1 -1
- package/src/modules/multiButton/components/multiButton/multiButton.component.d.ts.map +1 -1
- package/src/modules/multiButton/components/multiButton/multiButton.component.html +1 -1
- package/src/modules/multiButton/modules/multiButton.module.d.ts +1 -2
- package/src/modules/multiButton/modules/multiButton.module.d.ts.map +1 -1
- package/src/modules/progressIndicator/components/progressIndicator/progressIndicator.component.d.ts +1 -1
- package/src/modules/progressIndicator/components/progressIndicator/progressIndicator.component.d.ts.map +1 -1
- package/src/modules/progressIndicator/components/progressIndicator/progressIndicator.component.html +4 -1
- package/src/modules/progressIndicator/directives/progressOverlay/progressOverlay.directive.d.ts +1 -1
- package/src/modules/progressIndicator/directives/progressOverlay/progressOverlay.directive.d.ts.map +1 -1
- package/src/modules/progressIndicator/modules/progressIndicator.module.d.ts +1 -3
- package/src/modules/progressIndicator/modules/progressIndicator.module.d.ts.map +1 -1
- package/src/modules/tooltip/components/tooltip/tooltip.component.d.ts +1 -1
- package/src/modules/tooltip/components/tooltip/tooltip.component.d.ts.map +1 -1
- package/src/modules/tooltip/components/tooltip/tooltip.component.html +13 -5
- package/src/modules/tooltip/directives/tooltip/tooltip.directive.d.ts.map +1 -1
- package/src/modules/tooltip/directives/tooltipTemplate/tooltipTemplate.directive.d.ts +1 -1
- package/src/modules/tooltip/modules/tooltip.module.d.ts +4 -5
- package/src/modules/tooltip/modules/tooltip.module.d.ts.map +1 -1
- package/src/pipes/displayProperties/displayProperties.pipe.d.ts.map +1 -1
- package/src/pipes/firstUppercase/firstUppercase.pipe.d.ts +3 -3
- package/src/pipes/firstUppercase/firstUppercase.pipe.d.ts.map +1 -1
- package/src/pipes/firstUppercaseLocalize/firstUppercaseLocalize.pipe.d.ts +7 -7
- package/src/pipes/firstUppercaseLocalize/firstUppercaseLocalize.pipe.d.ts.map +1 -1
- package/src/pipes/isNaN/isNaN.pipe.d.ts.map +1 -1
- package/src/pipes/isPresent/isPresent.pipe.d.ts.map +1 -1
- package/src/pipes/localize/localize.pipe.d.ts +3 -3
- package/src/pipes/localize/localize.pipe.d.ts.map +1 -1
- package/src/pipes/mergeCssClasses/mergeCssClasses.pipe.d.ts +3 -3
- package/src/pipes/mergeCssClasses/mergeCssClasses.pipe.d.ts.map +1 -1
- package/version.bak +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Component, ChangeDetectionStrategy, forwardRef, signal, input, computed } from '@angular/core';
|
|
2
2
|
import { NgClass } from '@angular/common';
|
|
3
|
-
import {
|
|
3
|
+
import { FirstUppercaseLocalizePipe } from '@anglr/common';
|
|
4
4
|
import { FILE_VISUAL } from '../../misc/tokens';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
6
|
/**
|
|
@@ -39,19 +39,19 @@ export class FileInputComponent {
|
|
|
39
39
|
return this.selectedText() ?? context?.fileName;
|
|
40
40
|
});
|
|
41
41
|
}
|
|
42
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
43
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "
|
|
42
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: FileInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
43
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.1.0", type: FileInputComponent, isStandalone: true, selector: "file-input", inputs: { buttonText: { classPropertyName: "buttonText", publicName: "buttonText", isSignal: true, isRequired: false, transformFunction: null }, buttonClass: { classPropertyName: "buttonClass", publicName: "buttonClass", isSignal: true, isRequired: false, transformFunction: null }, textClass: { classPropertyName: "textClass", publicName: "textClass", isSignal: true, isRequired: false, transformFunction: null }, selectedText: { classPropertyName: "selectedText", publicName: "selectedText", isSignal: true, isRequired: false, transformFunction: null } }, providers: [
|
|
44
44
|
{
|
|
45
45
|
provide: FILE_VISUAL,
|
|
46
46
|
useExisting: forwardRef(() => FileInputComponent),
|
|
47
47
|
}
|
|
48
|
-
], ngImport: i0, template: "<div class=\"file-input\">\n <div [ngClass]=\"buttonClass()\">\n <span>{{buttonText() | firstUppercaseLocalize}}</span>\n </div>\n\n <div [ngClass]=\"textClass()\">{{selectedTextValue()}}</div>\n</div>\n", styles: [":host\n{\n display: block;\n}\n\n.file-input\n{\n display: grid;\n\n grid-template-areas: 'button filename';\n grid-template-rows: auto;\n grid-template-columns: auto 1fr;\n\n :nth-child(1),\n :nth-child(1):before\n {\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n }\n\n :nth-child(2),\n :nth-child(2):before\n {\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n }\n}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "pipe", type:
|
|
48
|
+
], ngImport: i0, template: "<div class=\"file-input\">\n <div [ngClass]=\"buttonClass()\">\n <span>{{buttonText() | firstUppercaseLocalize}}</span>\n </div>\n\n <div [ngClass]=\"textClass()\">{{selectedTextValue()}}</div>\n</div>\n", styles: [":host\n{\n display: block;\n}\n\n.file-input\n{\n display: grid;\n\n grid-template-areas: 'button filename';\n grid-template-rows: auto;\n grid-template-columns: auto 1fr;\n\n :nth-child(1),\n :nth-child(1):before\n {\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n }\n\n :nth-child(2),\n :nth-child(2):before\n {\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n }\n}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "pipe", type: FirstUppercaseLocalizePipe, name: "firstUppercaseLocalize" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
49
49
|
}
|
|
50
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
50
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: FileInputComponent, decorators: [{
|
|
51
51
|
type: Component,
|
|
52
|
-
args: [{ selector: 'file-input',
|
|
52
|
+
args: [{ selector: 'file-input', imports: [
|
|
53
53
|
NgClass,
|
|
54
|
-
|
|
54
|
+
FirstUppercaseLocalizePipe,
|
|
55
55
|
], providers: [
|
|
56
56
|
{
|
|
57
57
|
provide: FILE_VISUAL,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fileInput.component.js","sourceRoot":"","sources":["../../../../../../src/modules/file/components/fileInput/fileInput.component.ts","../../../../../../src/modules/file/components/fileInput/fileInput.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,uBAAuB,EAAoB,UAAU,EAAkB,MAAM,EAAE,KAAK,EAAuB,QAAQ,EAAC,MAAM,eAAe,CAAC;AAC7J,OAAO,EAAC,OAAO,EAAC,MAAM,iBAAiB,CAAC;AACxC,OAAO,EAAC,
|
|
1
|
+
{"version":3,"file":"fileInput.component.js","sourceRoot":"","sources":["../../../../../../src/modules/file/components/fileInput/fileInput.component.ts","../../../../../../src/modules/file/components/fileInput/fileInput.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,uBAAuB,EAAoB,UAAU,EAAkB,MAAM,EAAE,KAAK,EAAuB,QAAQ,EAAC,MAAM,eAAe,CAAC;AAC7J,OAAO,EAAC,OAAO,EAAC,MAAM,iBAAiB,CAAC;AACxC,OAAO,EAAC,0BAA0B,EAAC,MAAM,eAAe,CAAC;AAEzD,OAAO,EAAC,WAAW,EAAC,MAAM,mBAAmB,CAAC;;AAI9C;;GAEG;AAqBH,MAAM,OAAO,kBAAkB;IAsC3B,iEAAiE;IACjE;QA9BA,sGAAsG;QAEtG;;WAEG;QACI,wBAAmB,GAAuD,MAAM,CAAqC,IAAI,CAAC,CAAC;QAElI,gFAAgF;QAEhF;;WAEG;QACI,eAAU,GAAwB,KAAK,CAAC,QAAQ,CAAC,CAAC;QAEzD;;WAEG;QACI,gBAAW,GAAwB,KAAK,CAAC,iBAAiB,CAAC,CAAC;QAEnE;;WAEG;QACI,cAAS,GAAwB,KAAK,CAAC,cAAc,CAAC,CAAC;QAE9D;;WAEG;QACI,iBAAY,GAAuC,KAAK,EAAE,CAAC;QAK9D,IAAI,CAAC,iBAAiB,GAAG,QAAQ,CAAC,GAAG,EAAE;YAEnC,MAAM,OAAO,GAAG,IAAI,CAAC,mBAAmB,EAAE,CAAC;YAE3C,IAAG,OAAO,EAAE,QAAQ,EACpB,CAAC;gBACG,OAAO,IAAI,CAAC,YAAY,EAAE,IAAI,OAAO,CAAC,UAAU,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC;YACjE,CAAC;YAED,OAAO,IAAI,CAAC,YAAY,EAAE,IAAI,OAAO,EAAE,QAAQ,CAAC;QACpD,CAAC,CAAC,CAAC;IACP,CAAC;8GApDQ,kBAAkB;kGAAlB,kBAAkB,umBAT3B;YAEI;gBACI,OAAO,EAAE,WAAW;gBACpB,WAAW,EAAE,UAAU,CAAC,GAAG,EAAE,CAAC,kBAAkB,CAAC;aACpD;SACJ,0BC5BL,6NAOA,6gBDWQ,OAAO,+EACP,0BAA0B;;2FAYrB,kBAAkB;kBApB9B,SAAS;+BAEI,YAAY,WAItB;wBACI,OAAO;wBACP,0BAA0B;qBAC7B,aAED;wBAEI;4BACI,OAAO,EAAE,WAAW;4BACpB,WAAW,EAAE,UAAU,CAAC,GAAG,EAAE,mBAAmB,CAAC;yBACpD;qBACJ,mBACgB,uBAAuB,CAAC,MAAM","sourcesContent":["import {Component, ChangeDetectionStrategy, ExistingProvider, forwardRef, WritableSignal, signal, input, InputSignal, Signal, computed} from '@angular/core';\nimport {NgClass} from '@angular/common';\nimport {FirstUppercaseLocalizePipe} from '@anglr/common';\n\nimport {FILE_VISUAL} from '../../misc/tokens';\nimport {FileVisual} from '../../interfaces';\nimport {FileTemplateContext} from '../../directive';\n\n/**\n * Component that represents file input template\n */\n@Component(\n{\n selector: 'file-input',\n templateUrl: 'fileInput.component.html',\n styleUrl: 'fileInput.component.css',\n imports:\n [\n NgClass,\n FirstUppercaseLocalizePipe,\n ],\n providers:\n [\n <ExistingProvider>\n {\n provide: FILE_VISUAL,\n useExisting: forwardRef(() => FileInputComponent),\n }\n ],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class FileInputComponent implements FileVisual\n{\n //######################### protected properties - template bindings #########################\n\n /**\n * Selected text value based on file template context or selected text input\n */\n protected selectedTextValue: Signal<string|undefined|null>;\n \n //######################### public properties - implementation of FileVisual #########################\n\n /**\n * @inheritdoc\n */\n public fileTemplateContext: WritableSignal<FileTemplateContext|undefined|null> = signal<FileTemplateContext|undefined|null>(null);\n\n //######################### public properties - inputs #########################\n\n /**\n * Text to be displayed for file button\n */\n public buttonText: InputSignal<string> = input('browse');\n\n /**\n * Css classes applied to file button\n */\n public buttonClass: InputSignal<string> = input('btn btn-primary');\n\n /**\n * Css classes applied to file text, text displaying selected files\n */\n public textClass: InputSignal<string> = input('form-control');\n\n /**\n * Text to be displayed as selected\n */\n public selectedText: InputSignal<string|undefined|null> = input();\n\n //######################### constructor #########################\n constructor()\n {\n this.selectedTextValue = computed(() =>\n {\n const context = this.fileTemplateContext();\n\n if(context?.multiple)\n {\n return this.selectedText() ?? context.filesNames?.join(', ');\n }\n\n return this.selectedText() ?? context?.fileName;\n });\n }\n}","<div class=\"file-input\">\n <div [ngClass]=\"buttonClass()\">\n <span>{{buttonText() | firstUppercaseLocalize}}</span>\n </div>\n\n <div [ngClass]=\"textClass()\">{{selectedTextValue()}}</div>\n</div>\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Component, ChangeDetectionStrategy, forwardRef, signal, input, numberAttribute } from '@angular/core';
|
|
2
2
|
import { NgClass } from '@angular/common';
|
|
3
|
-
import { IsPresentPipe,
|
|
3
|
+
import { IsPresentPipe, LocalizePipe } from '@anglr/common';
|
|
4
4
|
import { FILE_VISUAL } from '../../misc/tokens';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
6
|
/**
|
|
@@ -35,20 +35,20 @@ export class UploadButtonComponent {
|
|
|
35
35
|
*/
|
|
36
36
|
this.progress = input(null, { transform: numberAttribute });
|
|
37
37
|
}
|
|
38
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
39
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
38
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: UploadButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
39
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.0", type: UploadButtonComponent, isStandalone: true, selector: "upload-button", inputs: { uploadIconClass: { classPropertyName: "uploadIconClass", publicName: "uploadIconClass", isSignal: true, isRequired: false, transformFunction: null }, uploadText: { classPropertyName: "uploadText", publicName: "uploadText", isSignal: true, isRequired: false, transformFunction: null }, uploadTextClass: { classPropertyName: "uploadTextClass", publicName: "uploadTextClass", isSignal: true, isRequired: false, transformFunction: null }, cssClass: { classPropertyName: "cssClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, progress: { classPropertyName: "progress", publicName: "progress", isSignal: true, isRequired: false, transformFunction: null } }, providers: [
|
|
40
40
|
{
|
|
41
41
|
provide: FILE_VISUAL,
|
|
42
42
|
useExisting: forwardRef(() => UploadButtonComponent),
|
|
43
43
|
}
|
|
44
|
-
], ngImport: i0, template: "@if(progress() | isPresent)\n{\n <div class=\"progress\">\n <span class=\"progress-value\">{{progress()}}%</span>\n <div class=\"progress-indicator\"></div>\n </div>\n}\n\n<button [ngClass]=\"cssClass()\" type=\"button\">\n <span [ngClass]=\"uploadIconClass()\"></span>\n \n @if(uploadText())\n {\n <span [ngClass]=\"uploadTextClass()\">{{uploadText() | localize}}</span>\n }\n</button>", styles: [":host\n{\n display: flex;\n flex-direction: row;\n}\n\n.progress\n{\n font-size: 0.75em;\n position: relative;\n width: 33px;\n height: 33px;\n text-align: center;\n margin-right: 4px;\n display: flex;\n justify-content: center;\n}\n\n.progress-value\n{\n align-self: center;\n}\n\n.progress-indicator\n{\n position: absolute;\n width: 33px;\n height: 16.5px;\n top: 0;\n left: 0;\n border: 2px solid #009dd6;\n border-bottom: none;\n border-top-left-radius: 100px;\n border-top-right-radius: 100px;\n animation-name: rotate-progress;\n animation-duration: 550ms;\n animation-iteration-count: infinite;\n animation-timing-function: linear;\n transform-origin: calc(50%) calc(50% + 8.25px);\n}\n\n@keyframes rotate-progress\n{\n from\n {\n transform: rotate(0deg);\n }\n to\n {\n transform: rotate(360deg);\n }\n}"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "pipe", type: IsPresentPipe, name: "isPresent" }, { kind: "pipe", type:
|
|
44
|
+
], ngImport: i0, template: "@if(progress() | isPresent)\n{\n <div class=\"progress\">\n <span class=\"progress-value\">{{progress()}}%</span>\n <div class=\"progress-indicator\"></div>\n </div>\n}\n\n<button [ngClass]=\"cssClass()\" type=\"button\">\n <span [ngClass]=\"uploadIconClass()\"></span>\n \n @if(uploadText())\n {\n <span [ngClass]=\"uploadTextClass()\">{{uploadText() | localize}}</span>\n }\n</button>", styles: [":host\n{\n display: flex;\n flex-direction: row;\n}\n\n.progress\n{\n font-size: 0.75em;\n position: relative;\n width: 33px;\n height: 33px;\n text-align: center;\n margin-right: 4px;\n display: flex;\n justify-content: center;\n}\n\n.progress-value\n{\n align-self: center;\n}\n\n.progress-indicator\n{\n position: absolute;\n width: 33px;\n height: 16.5px;\n top: 0;\n left: 0;\n border: 2px solid #009dd6;\n border-bottom: none;\n border-top-left-radius: 100px;\n border-top-right-radius: 100px;\n animation-name: rotate-progress;\n animation-duration: 550ms;\n animation-iteration-count: infinite;\n animation-timing-function: linear;\n transform-origin: calc(50%) calc(50% + 8.25px);\n}\n\n@keyframes rotate-progress\n{\n from\n {\n transform: rotate(0deg);\n }\n to\n {\n transform: rotate(360deg);\n }\n}"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "pipe", type: IsPresentPipe, name: "isPresent" }, { kind: "pipe", type: LocalizePipe, name: "localize" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
45
45
|
}
|
|
46
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
46
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: UploadButtonComponent, decorators: [{
|
|
47
47
|
type: Component,
|
|
48
|
-
args: [{ selector: 'upload-button',
|
|
48
|
+
args: [{ selector: 'upload-button', imports: [
|
|
49
49
|
NgClass,
|
|
50
50
|
IsPresentPipe,
|
|
51
|
-
|
|
51
|
+
LocalizePipe,
|
|
52
52
|
], providers: [
|
|
53
53
|
{
|
|
54
54
|
provide: FILE_VISUAL,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"uploadButton.component.js","sourceRoot":"","sources":["../../../../../../src/modules/file/components/uploadButton/uploadButton.component.ts","../../../../../../src/modules/file/components/uploadButton/uploadButton.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,uBAAuB,EAAoB,UAAU,EAAkB,MAAM,EAAe,KAAK,EAAE,eAAe,EAA2B,MAAM,eAAe,CAAC;AACtL,OAAO,EAAC,OAAO,EAAC,MAAM,iBAAiB,CAAC;AACxC,OAAO,EAAC,aAAa,EAAE,
|
|
1
|
+
{"version":3,"file":"uploadButton.component.js","sourceRoot":"","sources":["../../../../../../src/modules/file/components/uploadButton/uploadButton.component.ts","../../../../../../src/modules/file/components/uploadButton/uploadButton.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,uBAAuB,EAAoB,UAAU,EAAkB,MAAM,EAAe,KAAK,EAAE,eAAe,EAA2B,MAAM,eAAe,CAAC;AACtL,OAAO,EAAC,OAAO,EAAC,MAAM,iBAAiB,CAAC;AACxC,OAAO,EAAC,aAAa,EAAE,YAAY,EAAC,MAAM,eAAe,CAAC;AAE1D,OAAO,EAAC,WAAW,EAAC,MAAM,mBAAmB,CAAC;;AAI9C;;GAEG;AAsBH,MAAM,OAAO,qBAAqB;IArBlC;QAuBI,sGAAsG;QAEtG;;WAEG;QACI,wBAAmB,GAAuD,MAAM,CAAqC,IAAI,CAAC,CAAC;QAElI,gFAAgF;QAEhF;;WAEG;QACI,oBAAe,GAAwB,KAAK,CAAC,oBAAoB,CAAC,CAAC;QAE1E;;WAEG;QACI,eAAU,GAAwB,KAAK,CAAC,EAAE,CAAC,CAAC;QAEnD;;WAEG;QACI,oBAAe,GAAwB,KAAK,CAAC,wBAAwB,CAAC,CAAC;QAE9E;;WAEG;QACI,aAAQ,GAAwB,KAAK,CAAC,cAAc,EAAE,EAAC,KAAK,EAAE,OAAO,EAAC,CAAC,CAAC;QAE/E;;WAEG;QACI,aAAQ,GAAkF,KAAK,CAAsD,IAAI,EAAE,EAAC,SAAS,EAAE,eAAe,EAAC,CAAC,CAAC;KACnM;8GAnCY,qBAAqB;kGAArB,qBAAqB,0vBAT9B;YAEI;gBACI,OAAO,EAAE,WAAW;gBACpB,WAAW,EAAE,UAAU,CAAC,GAAG,EAAE,CAAC,qBAAqB,CAAC;aACvD;SACJ,0BC7BL,8aAeS,i9BDGD,OAAO,+EACP,aAAa,6CACb,YAAY;;2FAYP,qBAAqB;kBArBjC,SAAS;+BAEI,eAAe,WAIzB;wBACI,OAAO;wBACP,aAAa;wBACb,YAAY;qBACf,aAED;wBAEI;4BACI,OAAO,EAAE,WAAW;4BACpB,WAAW,EAAE,UAAU,CAAC,GAAG,EAAE,sBAAsB,CAAC;yBACvD;qBACJ,mBACgB,uBAAuB,CAAC,MAAM","sourcesContent":["import {Component, ChangeDetectionStrategy, ExistingProvider, forwardRef, WritableSignal, signal, InputSignal, input, numberAttribute, InputSignalWithTransform} from '@angular/core';\nimport {NgClass} from '@angular/common';\nimport {IsPresentPipe, LocalizePipe} from '@anglr/common';\n\nimport {FILE_VISUAL} from '../../misc/tokens';\nimport {FileVisual} from '../../interfaces';\nimport {FileTemplateContext} from '../../directive';\n\n/**\n * Component that represents upload button file template\n */\n@Component(\n{\n selector: 'upload-button',\n templateUrl: 'uploadButton.component.html',\n styleUrl: 'uploadButton.component.css',\n imports:\n [\n NgClass,\n IsPresentPipe,\n LocalizePipe,\n ],\n providers:\n [\n <ExistingProvider>\n {\n provide: FILE_VISUAL,\n useExisting: forwardRef(() => UploadButtonComponent),\n }\n ],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class UploadButtonComponent implements FileVisual\n{\n //######################### public properties - implementation of FileVisual #########################\n\n /**\n * @inheritdoc\n */\n public fileTemplateContext: WritableSignal<FileTemplateContext|undefined|null> = signal<FileTemplateContext|undefined|null>(null);\n\n //######################### public properties - inputs #########################\n\n /**\n * Css classes applied tu button icon\n */\n public uploadIconClass: InputSignal<string> = input('fas fa-file-upload');\n\n /**\n * Text to be displayed as button text\n */\n public uploadText: InputSignal<string> = input('');\n\n /**\n * Css classes for displayed text for button\n */\n public uploadTextClass: InputSignal<string> = input('first-letter-uppercase');\n\n /**\n * Css class applied to button\n */\n public cssClass: InputSignal<string> = input('btn btn-icon', {alias: 'class'});\n\n /**\n * Current progress to be displayed\n */\n public progress: InputSignalWithTransform<number|undefined|null, number|string|undefined|null> = input<number|undefined|null, number|string|undefined|null>(null, {transform: numberAttribute});\n}","@if(progress() | isPresent)\n{\n <div class=\"progress\">\n <span class=\"progress-value\">{{progress()}}%</span>\n <div class=\"progress-indicator\"></div>\n </div>\n}\n\n<button [ngClass]=\"cssClass()\" type=\"button\">\n <span [ngClass]=\"uploadIconClass()\"></span>\n \n @if(uploadText())\n {\n <span [ngClass]=\"uploadTextClass()\">{{uploadText() | localize}}</span>\n }\n</button>"]}
|
|
@@ -128,8 +128,8 @@ export class FileInputDirective {
|
|
|
128
128
|
}
|
|
129
129
|
}
|
|
130
130
|
}
|
|
131
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
132
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
131
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: FileInputDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
132
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.1.0", type: FileInputDirective, isStandalone: true, selector: "input[type=file]", inputs: { multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: true, isRequired: false, transformFunction: null }, readContent: { classPropertyName: "readContent", publicName: "readContent", isSignal: true, isRequired: false, transformFunction: null }, binaryContent: { classPropertyName: "binaryContent", publicName: "binaryContent", isSignal: true, isRequired: false, transformFunction: null }, textEncoding: { classPropertyName: "textEncoding", publicName: "textEncoding", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { stringContentChange: "stringContentChange", arrayBufferContentChange: "arrayBufferContentChange", fileChange: "fileChange", filesChange: "filesChange", fileName: "fileName", filesNames: "filesNames" }, exportAs: ["file"], ngImport: i0 }); }
|
|
133
133
|
}
|
|
134
134
|
__decorate([
|
|
135
135
|
BindThis,
|
|
@@ -143,12 +143,11 @@ __decorate([
|
|
|
143
143
|
__metadata("design:paramtypes", [MouseEvent]),
|
|
144
144
|
__metadata("design:returntype", void 0)
|
|
145
145
|
], FileInputDirective.prototype, "handleFileChange", null);
|
|
146
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
146
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: FileInputDirective, decorators: [{
|
|
147
147
|
type: Directive,
|
|
148
148
|
args: [{
|
|
149
149
|
selector: 'input[type=file]',
|
|
150
150
|
exportAs: 'file',
|
|
151
|
-
standalone: true,
|
|
152
151
|
}]
|
|
153
152
|
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.Renderer2 }], propDecorators: { clearFile: [], handleFileChange: [] } });
|
|
154
153
|
//# sourceMappingURL=fileInput.directive.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fileInput.directive.js","sourceRoot":"","sources":["../../../../../../src/modules/file/directive/fileInput/fileInput.directive.ts"],"names":[],"mappings":";AAAA,OAAO,EAAC,gBAAgB,EAAE,SAAS,EAAE,MAAM,EAAE,UAAU,EAAE,KAAK,EAAoD,MAAM,EAAoB,SAAS,EAAC,MAAM,eAAe,CAAC;AAC5K,OAAO,EAAC,QAAQ,EAAE,QAAQ,EAAa,MAAM,gBAAgB,CAAC;;AAE9D;;GAEG;AAOH,MAAM,OAAO,kBAAkB;IA+D3B,kEAAkE;IAClE,YAAsB,OAAqC,EAC/C,QAAmB;QADT,YAAO,GAAP,OAAO,CAA8B;QAvD3D,gFAAgF;QAEhF;;WAEG;QACI,aAAQ,GAAsD,KAAK,CAA0B,KAAK,EAAE,EAAC,SAAS,EAAE,gBAAgB,EAAC,CAAC,CAAC;QAE1I;;WAEG;QACI,gBAAW,GAAsD,KAAK,CAA0B,KAAK,EAAE,EAAC,SAAS,EAAE,gBAAgB,EAAC,CAAC,CAAC;QAE7I;;WAEG;QACI,kBAAa,GAAsD,KAAK,CAA0B,KAAK,EAAE,EAAC,SAAS,EAAE,gBAAgB,EAAC,CAAC,CAAC;QAE/I;;WAEG;QACI,iBAAY,GAAkC,KAAK,EAAE,CAAC;QAE7D,iFAAiF;QAEjF;;WAEG;QACI,wBAAmB,GAA4C,MAAM,EAAyB,CAAC;QAEtG;;WAEG;QACI,6BAAwB,GAAiD,MAAM,EAA8B,CAAC;QAErH;;WAEG;QACI,eAAU,GAA0C,MAAM,EAAuB,CAAC;QAEzF;;WAEG;QACI,gBAAW,GAA4C,MAAM,EAAyB,CAAC;QAE9F;;WAEG;QACI,aAAQ,GAA4C,MAAM,EAAyB,CAAC;QAE3F;;WAEG;QACI,eAA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AAQ,CAAC,MAAM,CAAC,EACnB,CAAC;oBACG,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;gBAC1C,CAAC;qBAED,CAAC;oBACG,IAAI,CAAC,wBAAwB,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;gBAC/C,CAAC;YACL,CAAC,CAAC;YAEF,IAAG,IAAI,CAAC,aAAa,EAAE,EACvB,CAAC;gBACG,UAAU,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAC;YACvC,CAAC;iBAED,CAAC;gBACG,UAAU,CAAC,UAAU,CAAC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE,CAAC,CAAC;YACrD,CAAC;QACL,CAAC;IACL,CAAC;8GApLQ,kBAAkB;kGAAlB,kBAAkB;;AAwFpB;IADN,QAAQ;;;;mDAUR;AAQS;IADT,QAAQ;;qCACyB,UAAU;;0DA2E3C;2FApLQ,kBAAkB;kBAN9B,SAAS;mBACV;oBACI,QAAQ,EAAE,kBAAkB;oBAC5B,QAAQ,EAAE,MAAM;oBAChB,UAAU,EAAE,IAAI;iBACnB;uGAyFU,SAAS,MAiBN,gBAAgB","sourcesContent":["import {booleanAttribute, Directive, effect, ElementRef, input, InputSignal, InputSignalWithTransform, OnDestroy, output, OutputEmitterRef, Renderer2} from '@angular/core';\nimport {BindThis, isString, NoopAction} from '@jscrpt/common';\n\n/**\n * Directive that allows better communication with input file\n */\n@Directive(\n{\n selector: 'input[type=file]',\n exportAs: 'file',\n standalone: true,\n})\nexport class FileInputDirective implements OnDestroy\n{\n //######################### protected fields #########################\n\n /**\n * Unlistener for input file change event\n */\n protected changeListenerUnlisten: NoopAction;\n\n //######################### public properties - inputs #########################\n\n /**\n * Indication whether is multiple files selection enabled\n */\n public multiple: InputSignalWithTransform<boolean, string|boolean> = input<boolean, boolean|string>(false, {transform: booleanAttribute});\n\n /**\n * Indication whether read file content, working only when `multiple` is not set (for single file)\n */\n public readContent: InputSignalWithTransform<boolean, string|boolean> = input<boolean, boolean|string>(false, {transform: booleanAttribute});\n\n /**\n * Indication whether content of file is binary and it will be read as ArrayBuffer instead of string\n */\n public binaryContent: InputSignalWithTransform<boolean, string|boolean> = input<boolean, boolean|string>(false, {transform: booleanAttribute});\n\n /**\n * Text encoding of read string file content\n */\n public textEncoding: InputSignal<string|undefined> = input();\n\n //######################### public properties - outputs #########################\n\n /**\n * Occurs when file changes and `binaryContent` is not set and `readContent` is set\n */\n public stringContentChange: OutputEmitterRef<string|undefined|null> = output<string|undefined|null>();\n\n /**\n * Occurs when file changes and `binaryContent` is set and `readContent` is set\n */\n public arrayBufferContentChange: OutputEmitterRef<ArrayBuffer|undefined|null> = output<ArrayBuffer|undefined|null>();\n\n /**\n * Occurs when selected file changes, occurs only when `multiple` is not set\n */\n public fileChange: OutputEmitterRef<File|null|undefined> = output<File|undefined|null>();\n\n /**\n * Occurs when selected files changes, occurs only when `multiple` is set\n */\n public filesChange: OutputEmitterRef<File[]|null|undefined> = output<File[]|undefined|null>();\n\n /**\n * Occurs when selected file changes, occurs only when `multiple` is not set, contains name of selected file\n */\n public fileName: OutputEmitterRef<string|null|undefined> = output<string|undefined|null>();\n\n /**\n * Occurs when selected files changes, occurs only when `multiple` is set, contains names of selected files\n */\n public filesNames: OutputEmitterRef<string[]|null|undefined> = output<string[]|undefined|null>();\n\n //######################### constructors #########################\n constructor(protected element: ElementRef<HTMLInputElement>,\n renderer: Renderer2,)\n {\n this.changeListenerUnlisten = renderer.listen(element.nativeElement, 'change', this.handleFileChange);\n\n effect(() => renderer.setProperty(element.nativeElement, 'multiple', this.multiple()));\n }\n\n //######################### public methods - implementation of OnDestroy #########################\n\n /**\n * @inheritdoc\n */\n public ngOnDestroy(): void\n {\n this.changeListenerUnlisten();\n }\n\n //######################### public methods #########################\n\n /**\n * Clears selection of file/files\n */\n @BindThis\n public clearFile(): void\n {\n this.element.nativeElement.value = '';\n this.fileChange.emit(null);\n this.fileName.emit(null);\n this.filesChange.emit(null);\n this.filesNames.emit(null);\n this.arrayBufferContentChange.emit(null);\n this.stringContentChange.emit(null);\n }\n\n //######################### protected methods #########################\n\n /**\n * Handles changes in file input\n */\n @BindThis\n protected handleFileChange(event: MouseEvent): void\n {\n if(!event.target)\n {\n throw new Error('FileOutputDirective: missing input file target!');\n }\n\n if(this.multiple())\n {\n const files = (event.target as HTMLInputElement).files;\n const filesArray: File[] = [];\n\n if(files)\n {\n for(let x = 0; x < files.length; x++)\n {\n filesArray.push(files[x]);\n }\n }\n\n this.filesChange.emit(filesArray);\n this.filesNames.emit(filesArray.map(itm => itm.name));\n }\n else\n {\n const file = (event.target as HTMLInputElement).files?.[0];\n\n this.fileChange.emit(file);\n this.fileName.emit(file?.name);\n }\n\n //read file contents\n if(!this.multiple() && this.readContent())\n {\n const file = (event.target as HTMLInputElement).files?.[0];\n\n //no file selected\n if(!file)\n {\n return;\n }\n\n const fileReader = new FileReader();\n \n fileReader.onloadend = () =>\n {\n const result = fileReader.result;\n\n if(!result)\n {\n this.stringContentChange.emit(null);\n this.arrayBufferContentChange.emit(null);\n\n return;\n }\n\n if(isString(result))\n {\n this.stringContentChange.emit(result);\n }\n else\n {\n this.arrayBufferContentChange.emit(result);\n }\n };\n \n if(this.binaryContent())\n {\n fileReader.readAsArrayBuffer(file);\n }\n else\n {\n fileReader.readAsText(file, this.textEncoding());\n }\n }\n }\n}"]}
|
|
1
|
+
{"version":3,"file":"fileInput.directive.js","sourceRoot":"","sources":["../../../../../../src/modules/file/directive/fileInput/fileInput.directive.ts"],"names":[],"mappings":";AAAA,OAAO,EAAC,gBAAgB,EAAE,SAAS,EAAE,MAAM,EAAE,UAAU,EAAE,KAAK,EAAoD,MAAM,EAAoB,SAAS,EAAC,MAAM,eAAe,CAAC;AAC5K,OAAO,EAAC,QAAQ,EAAE,QAAQ,EAAa,MAAM,gBAAgB,CAAC;;AAE9D;;GAEG;AAMH,MAAM,OAAO,kBAAkB;IA+D3B,kEAAkE;IAClE,YAAsB,OAAqC,EAC/C,QAA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UR;AAQS;IADT,QAAQ;;qCACyB,UAAU;;0DA2E3C;2FApLQ,kBAAkB;kBAL9B,SAAS;mBACV;oBACI,QAAQ,EAAE,kBAAkB;oBAC5B,QAAQ,EAAE,MAAM;iBACnB;uGAyFU,SAAS,MAiBN,gBAAgB","sourcesContent":["import {booleanAttribute, Directive, effect, ElementRef, input, InputSignal, InputSignalWithTransform, OnDestroy, output, OutputEmitterRef, Renderer2} from '@angular/core';\nimport {BindThis, isString, NoopAction} from '@jscrpt/common';\n\n/**\n * Directive that allows better communication with input file\n */\n@Directive(\n{\n selector: 'input[type=file]',\n exportAs: 'file',\n})\nexport class FileInputDirective implements OnDestroy\n{\n //######################### protected fields #########################\n\n /**\n * Unlistener for input file change event\n */\n protected changeListenerUnlisten: NoopAction;\n\n //######################### public properties - inputs #########################\n\n /**\n * Indication whether is multiple files selection enabled\n */\n public multiple: InputSignalWithTransform<boolean, string|boolean> = input<boolean, boolean|string>(false, {transform: booleanAttribute});\n\n /**\n * Indication whether read file content, working only when `multiple` is not set (for single file)\n */\n public readContent: InputSignalWithTransform<boolean, string|boolean> = input<boolean, boolean|string>(false, {transform: booleanAttribute});\n\n /**\n * Indication whether content of file is binary and it will be read as ArrayBuffer instead of string\n */\n public binaryContent: InputSignalWithTransform<boolean, string|boolean> = input<boolean, boolean|string>(false, {transform: booleanAttribute});\n\n /**\n * Text encoding of read string file content\n */\n public textEncoding: InputSignal<string|undefined> = input();\n\n //######################### public properties - outputs #########################\n\n /**\n * Occurs when file changes and `binaryContent` is not set and `readContent` is set\n */\n public stringContentChange: OutputEmitterRef<string|undefined|null> = output<string|undefined|null>();\n\n /**\n * Occurs when file changes and `binaryContent` is set and `readContent` is set\n */\n public arrayBufferContentChange: OutputEmitterRef<ArrayBuffer|undefined|null> = output<ArrayBuffer|undefined|null>();\n\n /**\n * Occurs when selected file changes, occurs only when `multiple` is not set\n */\n public fileChange: OutputEmitterRef<File|null|undefined> = output<File|undefined|null>();\n\n /**\n * Occurs when selected files changes, occurs only when `multiple` is set\n */\n public filesChange: OutputEmitterRef<File[]|null|undefined> = output<File[]|undefined|null>();\n\n /**\n * Occurs when selected file changes, occurs only when `multiple` is not set, contains name of selected file\n */\n public fileName: OutputEmitterRef<string|null|undefined> = output<string|undefined|null>();\n\n /**\n * Occurs when selected files changes, occurs only when `multiple` is set, contains names of selected files\n */\n public filesNames: OutputEmitterRef<string[]|null|undefined> = output<string[]|undefined|null>();\n\n //######################### constructors #########################\n constructor(protected element: ElementRef<HTMLInputElement>,\n renderer: Renderer2,)\n {\n this.changeListenerUnlisten = renderer.listen(element.nativeElement, 'change', this.handleFileChange);\n\n effect(() => renderer.setProperty(element.nativeElement, 'multiple', this.multiple()));\n }\n\n //######################### public methods - implementation of OnDestroy #########################\n\n /**\n * @inheritdoc\n */\n public ngOnDestroy(): void\n {\n this.changeListenerUnlisten();\n }\n\n //######################### public methods #########################\n\n /**\n * Clears selection of file/files\n */\n @BindThis\n public clearFile(): void\n {\n this.element.nativeElement.value = '';\n this.fileChange.emit(null);\n this.fileName.emit(null);\n this.filesChange.emit(null);\n this.filesNames.emit(null);\n this.arrayBufferContentChange.emit(null);\n this.stringContentChange.emit(null);\n }\n\n //######################### protected methods #########################\n\n /**\n * Handles changes in file input\n */\n @BindThis\n protected handleFileChange(event: MouseEvent): void\n {\n if(!event.target)\n {\n throw new Error('FileOutputDirective: missing input file target!');\n }\n\n if(this.multiple())\n {\n const files = (event.target as HTMLInputElement).files;\n const filesArray: File[] = [];\n\n if(files)\n {\n for(let x = 0; x < files.length; x++)\n {\n filesArray.push(files[x]);\n }\n }\n\n this.filesChange.emit(filesArray);\n this.filesNames.emit(filesArray.map(itm => itm.name));\n }\n else\n {\n const file = (event.target as HTMLInputElement).files?.[0];\n\n this.fileChange.emit(file);\n this.fileName.emit(file?.name);\n }\n\n //read file contents\n if(!this.multiple() && this.readContent())\n {\n const file = (event.target as HTMLInputElement).files?.[0];\n\n //no file selected\n if(!file)\n {\n return;\n }\n\n const fileReader = new FileReader();\n \n fileReader.onloadend = () =>\n {\n const result = fileReader.result;\n\n if(!result)\n {\n this.stringContentChange.emit(null);\n this.arrayBufferContentChange.emit(null);\n\n return;\n }\n\n if(isString(result))\n {\n this.stringContentChange.emit(result);\n }\n else\n {\n this.arrayBufferContentChange.emit(result);\n }\n };\n \n if(this.binaryContent())\n {\n fileReader.readAsArrayBuffer(file);\n }\n else\n {\n fileReader.readAsText(file, this.textEncoding());\n }\n }\n }\n}"]}
|
|
@@ -11,14 +11,13 @@ export class FileTemplateDirective {
|
|
|
11
11
|
static ngTemplateContextGuard(_dir, _ctx) {
|
|
12
12
|
return true;
|
|
13
13
|
}
|
|
14
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
15
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
14
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: FileTemplateDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
15
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0", type: FileTemplateDirective, isStandalone: true, selector: "[fileTemplate]", ngImport: i0 }); }
|
|
16
16
|
}
|
|
17
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
17
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: FileTemplateDirective, decorators: [{
|
|
18
18
|
type: Directive,
|
|
19
19
|
args: [{
|
|
20
20
|
selector: '[fileTemplate]',
|
|
21
|
-
standalone: true,
|
|
22
21
|
}]
|
|
23
22
|
}] });
|
|
24
23
|
//# sourceMappingURL=fileTemplate.directive.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fileTemplate.directive.js","sourceRoot":"","sources":["../../../../../../src/modules/file/directive/fileTemplate/fileTemplate.directive.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAC,MAAM,eAAe,CAAC;;AAIxC;;GAEG;
|
|
1
|
+
{"version":3,"file":"fileTemplate.directive.js","sourceRoot":"","sources":["../../../../../../src/modules/file/directive/fileTemplate/fileTemplate.directive.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAC,MAAM,eAAe,CAAC;;AAIxC;;GAEG;AAKH,MAAM,OAAO,qBAAqB;IAE9B,wEAAwE;IAExE;;OAEG;IACH,MAAM,CAAC,sBAAsB,CAAC,IAA2B,EAAE,IAAa;QAEpE,OAAO,IAAI,CAAC;IAChB,CAAC;8GAVQ,qBAAqB;kGAArB,qBAAqB;;2FAArB,qBAAqB;kBAJjC,SAAS;mBACV;oBACI,QAAQ,EAAE,gBAAgB;iBAC7B","sourcesContent":["import {Directive} from '@angular/core';\n\nimport {FileTemplateContext} from './fileTemplate.context';\n\n/**\n * Directive used for obtaining file component visual template\n */\n@Directive(\n{\n selector: '[fileTemplate]',\n})\nexport class FileTemplateDirective\n{\n //######################### ng language server #########################\n \n /**\n * Allows typechecking for template\n */\n static ngTemplateContextGuard(_dir: FileTemplateDirective, _ctx: unknown): _ctx is FileTemplateContext\n {\n return true;\n }\n}"]}
|
|
@@ -6,8 +6,8 @@ import * as i0 from "@angular/core";
|
|
|
6
6
|
* Module for grouping File components and directives
|
|
7
7
|
*/
|
|
8
8
|
export class FileModule {
|
|
9
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
10
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
9
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: FileModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
10
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.1.0", ngImport: i0, type: FileModule, imports: [FileComponent,
|
|
11
11
|
FileInputDirective,
|
|
12
12
|
FileTemplateDirective,
|
|
13
13
|
UploadButtonComponent,
|
|
@@ -16,9 +16,9 @@ export class FileModule {
|
|
|
16
16
|
UploadButtonComponent,
|
|
17
17
|
FileInputDirective,
|
|
18
18
|
FileTemplateDirective] }); }
|
|
19
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
19
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: FileModule }); }
|
|
20
20
|
}
|
|
21
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
21
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: FileModule, decorators: [{
|
|
22
22
|
type: NgModule,
|
|
23
23
|
args: [{
|
|
24
24
|
imports: [
|
|
@@ -7,7 +7,7 @@ import * as i2 from "@angular/common";
|
|
|
7
7
|
/**
|
|
8
8
|
* Component used for displaying console logs
|
|
9
9
|
*/
|
|
10
|
-
export class
|
|
10
|
+
export class ConsoleComponent {
|
|
11
11
|
//######################### constructor #########################
|
|
12
12
|
constructor(consoleSvc, changeDetector) {
|
|
13
13
|
this.consoleSvc = consoleSvc;
|
|
@@ -84,12 +84,12 @@ export class ConsoleSAComponent {
|
|
|
84
84
|
this.currentLogs = this.consoleSvc.logs.filter(log => log.text.toLowerCase().indexOf(this.filterValue.toLowerCase()) >= 0);
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
88
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
87
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: ConsoleComponent, deps: [{ token: i1.ConsoleComponentService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
88
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.1.0", type: ConsoleComponent, isStandalone: true, selector: "console", ngImport: i0, template: "<div class=\"console-data thin-scrollbar\">\n <div class=\"console-log\" [ngClass]=\"log?.logLevel | lowercase\" *ngFor=\"let log of currentLogs\">\n <div class=\"console-log-icon fa\" [class.fa-angle-right]=\"!log?.expanded\" [class.fa-angle-down]=\"log?.expanded\" (click)=\"log.expanded = !log.expanded\"></div>\n <div class=\"console-log-text\" [class.expanded]=\"log?.expanded\" (click)=\"copyMessage(log.text)\">{{log?.text}}</div>\n </div>\n\n <div class=\"clear-icon\" (click)=\"clear()\" title=\"clear log\">\n <div class=\"fa fa-times\"></div>\n </div>\n\n <div class=\"copy-icon\" (click)=\"copy()\" title=\"copy to clipboard\" *ngIf=\"canCopy\">\n <div class=\"fa fa-copy\"></div>\n </div>\n</div>\n\n<div class=\"console-filter\">\n <input type=\"text\" placeholder=\"Filter messages\" (input)=\"filterValue = $any($event.target).value; setMessages()\">\n</div>", styles: [":host\n{\n display: flex;\n flex-direction: column;\n position: absolute;\n width: 100%;\n height: 50%;\n}\n\n.console-data\n{\n background-color: #000000c7;\n border: none;\n border-bottom: 1px solid #AAA;\n border-radius: 0;\n color: #EEE;\n flex: 1;\n min-height: 0;\n min-width: 0;\n overflow-y: auto;\n overflow-x: hidden;\n cursor: pointer;\n}\n\n.console-filter\n{\n align-self: stretch;\n}\n\n.console-filter input\n{\n width: 100%;\n background-color: #000000c7;\n color: #FFF;\n border: none;\n border-bottom: 1px solid #AAA;\n padding: 0 4px;\n}\n\n.copy-icon,\n.clear-icon\n{\n position: absolute;\n top: 0;\n right: 0;\n padding: 4px 14px;\n}\n\n.copy-icon\n{\n margin-right: 20px;\n}\n\n.clear-icon div:hover,\n.copy-icon div:hover\n{\n color: #31A1FF;\n cursor: pointer;\n}\n\n.console-log\n{\n font-family: Menlo, Monaco, Consolas, \"Courier New\", monospace;\n font-size: 12px;\n display: flex;\n flex-direction: row;\n}\n\n.console-log.error,\n.console-log.fatal\n{\n color: #FF3131;\n}\n\n.console-log.warning\n{\n color: #FFC531;\n}\n\n.console-log.debug,\n.console-log.verbose\n{\n color: #31A1FF;\n}\n\n.console-log-icon\n{\n color: #FFF;\n font-weight: bold;\n margin: 2px 4px 0;\n}\n\n.console-log-icon.fa-angle-down\n{\n margin: 3px 3px 0 2px;\n}\n\n.console-log-text\n{\n flex: 1;\n min-width: 0;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n.console-log-text.expanded\n{\n white-space: pre;\n text-overflow: initial;\n}"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i2.LowerCasePipe, name: "lowercase" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
89
89
|
}
|
|
90
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
90
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: ConsoleComponent, decorators: [{
|
|
91
91
|
type: Component,
|
|
92
|
-
args: [{ selector: 'console',
|
|
92
|
+
args: [{ selector: 'console', imports: [
|
|
93
93
|
CommonModule,
|
|
94
94
|
], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"console-data thin-scrollbar\">\n <div class=\"console-log\" [ngClass]=\"log?.logLevel | lowercase\" *ngFor=\"let log of currentLogs\">\n <div class=\"console-log-icon fa\" [class.fa-angle-right]=\"!log?.expanded\" [class.fa-angle-down]=\"log?.expanded\" (click)=\"log.expanded = !log.expanded\"></div>\n <div class=\"console-log-text\" [class.expanded]=\"log?.expanded\" (click)=\"copyMessage(log.text)\">{{log?.text}}</div>\n </div>\n\n <div class=\"clear-icon\" (click)=\"clear()\" title=\"clear log\">\n <div class=\"fa fa-times\"></div>\n </div>\n\n <div class=\"copy-icon\" (click)=\"copy()\" title=\"copy to clipboard\" *ngIf=\"canCopy\">\n <div class=\"fa fa-copy\"></div>\n </div>\n</div>\n\n<div class=\"console-filter\">\n <input type=\"text\" placeholder=\"Filter messages\" (input)=\"filterValue = $any($event.target).value; setMessages()\">\n</div>", styles: [":host\n{\n display: flex;\n flex-direction: column;\n position: absolute;\n width: 100%;\n height: 50%;\n}\n\n.console-data\n{\n background-color: #000000c7;\n border: none;\n border-bottom: 1px solid #AAA;\n border-radius: 0;\n color: #EEE;\n flex: 1;\n min-height: 0;\n min-width: 0;\n overflow-y: auto;\n overflow-x: hidden;\n cursor: pointer;\n}\n\n.console-filter\n{\n align-self: stretch;\n}\n\n.console-filter input\n{\n width: 100%;\n background-color: #000000c7;\n color: #FFF;\n border: none;\n border-bottom: 1px solid #AAA;\n padding: 0 4px;\n}\n\n.copy-icon,\n.clear-icon\n{\n position: absolute;\n top: 0;\n right: 0;\n padding: 4px 14px;\n}\n\n.copy-icon\n{\n margin-right: 20px;\n}\n\n.clear-icon div:hover,\n.copy-icon div:hover\n{\n color: #31A1FF;\n cursor: pointer;\n}\n\n.console-log\n{\n font-family: Menlo, Monaco, Consolas, \"Courier New\", monospace;\n font-size: 12px;\n display: flex;\n flex-direction: row;\n}\n\n.console-log.error,\n.console-log.fatal\n{\n color: #FF3131;\n}\n\n.console-log.warning\n{\n color: #FFC531;\n}\n\n.console-log.debug,\n.console-log.verbose\n{\n color: #31A1FF;\n}\n\n.console-log-icon\n{\n color: #FFF;\n font-weight: bold;\n margin: 2px 4px 0;\n}\n\n.console-log-icon.fa-angle-down\n{\n margin: 3px 3px 0 2px;\n}\n\n.console-log-text\n{\n flex: 1;\n min-width: 0;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n.console-log-text.expanded\n{\n white-space: pre;\n text-overflow: initial;\n}"] }]
|
|
95
95
|
}], ctorParameters: () => [{ type: i1.ConsoleComponentService }, { type: i0.ChangeDetectorRef }] });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"console.component.js","sourceRoot":"","sources":["../../../../../../src/modules/logger/components/console/console.component.ts","../../../../../../src/modules/logger/components/console/console.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,uBAAuB,EAAqB,iBAAiB,EAAC,MAAM,eAAe,CAAC;AACvG,OAAO,EAAC,YAAY,EAAC,MAAM,iBAAiB,CAAC;AAI7C,OAAO,EAAC,uBAAuB,EAAC,MAAM,gBAAgB,CAAC;;;;AAEvD;;GAEG;
|
|
1
|
+
{"version":3,"file":"console.component.js","sourceRoot":"","sources":["../../../../../../src/modules/logger/components/console/console.component.ts","../../../../../../src/modules/logger/components/console/console.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,uBAAuB,EAAqB,iBAAiB,EAAC,MAAM,eAAe,CAAC;AACvG,OAAO,EAAC,YAAY,EAAC,MAAM,iBAAiB,CAAC;AAI7C,OAAO,EAAC,uBAAuB,EAAC,MAAM,gBAAgB,CAAC;;;;AAEvD;;GAEG;AAYH,MAAM,OAAO,gBAAgB;IA0BzB,iEAAiE;IACjE,YAAsB,UAAmC,EACnC,cAAiC;QADjC,eAAU,GAAV,UAAU,CAAyB;QACnC,mBAAc,GAAd,cAAc,CAAmB;QAnBvD,8FAA8F;QAE9F;;WAEG;QACO,gBAAW,GAA0B,EAAE,CAAC;QAElD;;WAEG;QACO,YAAO,GAAG,SAAS,IAAI,SAAS,CAAC,SAAS,CAAC;QAErD;;WAEG;QACO,gBAAW,GAAW,EAAE,CAAC;IAMnC,CAAC;IAED,+FAA+F;IAE/F;;OAEG;IACI,QAAQ;QAEX,IAAI,CAAC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AC,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,WAAW,CAAC,WAAW,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC;QAC/H,CAAC;IACL,CAAC;8GAhHQ,gBAAgB;kGAAhB,gBAAgB,mECrB7B,65BAiBM,8oDDAE,YAAY;;2FAIP,gBAAgB;kBAX5B,SAAS;+BAEI,SAAS,WAInB;wBACI,YAAY;qBACf,mBACgB,uBAAuB,CAAC,MAAM","sourcesContent":["import {Component, ChangeDetectionStrategy, OnInit, OnDestroy, ChangeDetectorRef} from '@angular/core';\nimport {CommonModule} from '@angular/common';\nimport {Subscription} from 'rxjs';\n\nimport {ConsoleComponentLog} from '../../interfaces';\nimport {ConsoleComponentService} from '../../services';\n\n/**\n * Component used for displaying console logs\n */\n@Component(\n{\n selector: 'console',\n templateUrl: 'console.component.html',\n styleUrl: 'console.component.css',\n imports:\n [\n CommonModule,\n ],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class ConsoleComponent implements OnInit, OnDestroy\n{\n //######################### protected fields #########################\n\n /**\n * Subscription for log changes\n */\n protected logsChangeSubscription: Subscription|undefined|null;\n\n //######################### protected properties - template bindings #########################\n\n /**\n * Current state of logger\n */\n protected currentLogs: ConsoleComponentLog[] = [];\n\n /**\n * Indication whether can use copy to clipboard\n */\n protected canCopy = navigator && navigator.clipboard;\n\n /**\n * Current value of filter\n */\n protected filterValue: string = '';\n\n //######################### constructor #########################\n constructor(protected consoleSvc: ConsoleComponentService,\n protected changeDetector: ChangeDetectorRef)\n {\n }\n\n //######################### public methods - implementation of OnInit #########################\n \n /**\n * Initialize component\n */\n public ngOnInit(): void\n {\n this.setMessages();\n \n this.logsChangeSubscription = this.consoleSvc.logsChange.subscribe(() =>\n {\n this.setMessages();\n this.changeDetector.detectChanges();\n });\n }\n\n //######################### public methods - implementation of OnDestroy #########################\n \n /**\n * Called when component is destroyed\n */\n public ngOnDestroy(): void\n {\n if(this.logsChangeSubscription)\n {\n this.logsChangeSubscription.unsubscribe();\n this.logsChangeSubscription = null;\n }\n }\n\n //######################### protected methods - template bindings #########################\n\n /**\n * Copies content of whole console log into clipboard\n */\n protected copy(): void\n {\n if(!navigator || !navigator.clipboard)\n {\n return;\n }\n\n navigator.clipboard.writeText(this.currentLogs.map(log => log.text).join('\\n'));\n }\n\n /**\n * Copies message to clipboard\n * @param message - Message to be copied\n */\n protected copyMessage(message: string): void\n {\n if(!navigator || !navigator.clipboard)\n {\n return;\n }\n\n navigator.clipboard.writeText(message);\n }\n\n /**\n * Clears existing logs\n */\n protected clear(): void\n {\n this.consoleSvc.clear();\n }\n\n /**\n * Sets messages using filter\n */\n protected setMessages(): void\n {\n if(!this.filterValue)\n {\n this.currentLogs = this.consoleSvc.logs;\n }\n else\n {\n this.currentLogs = this.consoleSvc.logs.filter(log => log.text.toLowerCase().indexOf(this.filterValue.toLowerCase()) >= 0);\n }\n }\n}","<div class=\"console-data thin-scrollbar\">\n <div class=\"console-log\" [ngClass]=\"log?.logLevel | lowercase\" *ngFor=\"let log of currentLogs\">\n <div class=\"console-log-icon fa\" [class.fa-angle-right]=\"!log?.expanded\" [class.fa-angle-down]=\"log?.expanded\" (click)=\"log.expanded = !log.expanded\"></div>\n <div class=\"console-log-text\" [class.expanded]=\"log?.expanded\" (click)=\"copyMessage(log.text)\">{{log?.text}}</div>\n </div>\n\n <div class=\"clear-icon\" (click)=\"clear()\" title=\"clear log\">\n <div class=\"fa fa-times\"></div>\n </div>\n\n <div class=\"copy-icon\" (click)=\"copy()\" title=\"copy to clipboard\" *ngIf=\"canCopy\">\n <div class=\"fa fa-copy\"></div>\n </div>\n</div>\n\n<div class=\"console-filter\">\n <input type=\"text\" placeholder=\"Filter messages\" (input)=\"filterValue = $any($event.target).value; setMessages()\">\n</div>"]}
|
|
@@ -55,10 +55,10 @@ export class ConsoleComponentService {
|
|
|
55
55
|
}
|
|
56
56
|
this.logsChangeSubject.next();
|
|
57
57
|
}
|
|
58
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
59
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
58
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: ConsoleComponentService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
59
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: ConsoleComponentService, providedIn: 'root' }); }
|
|
60
60
|
}
|
|
61
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
61
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: ConsoleComponentService, decorators: [{
|
|
62
62
|
type: Injectable,
|
|
63
63
|
args: [{ providedIn: 'root' }]
|
|
64
64
|
}] });
|
|
@@ -20,10 +20,10 @@ export class ConsoleComponentServiceOptions {
|
|
|
20
20
|
this.maxLogsCount = maxLogsCount;
|
|
21
21
|
}
|
|
22
22
|
}
|
|
23
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
24
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
23
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: ConsoleComponentServiceOptions, deps: "invalid", target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
24
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: ConsoleComponentServiceOptions, providedIn: 'root', useFactory: () => new ConsoleComponentServiceOptions() }); }
|
|
25
25
|
}
|
|
26
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
26
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: ConsoleComponentServiceOptions, decorators: [{
|
|
27
27
|
type: Injectable,
|
|
28
28
|
args: [{ providedIn: 'root', useFactory: () => new ConsoleComponentServiceOptions() }]
|
|
29
29
|
}], ctorParameters: () => [{ type: undefined }] });
|
|
@@ -88,10 +88,10 @@ export class DefaultLogger {
|
|
|
88
88
|
}
|
|
89
89
|
}
|
|
90
90
|
}
|
|
91
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
92
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
91
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: DefaultLogger, deps: [{ token: i1.LoggerOptions }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
92
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: DefaultLogger }); }
|
|
93
93
|
}
|
|
94
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
94
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: DefaultLogger, decorators: [{
|
|
95
95
|
type: Injectable
|
|
96
96
|
}], ctorParameters: () => [{ type: i1.LoggerOptions }] });
|
|
97
97
|
//# sourceMappingURL=logger.service.js.map
|
|
@@ -32,10 +32,10 @@ export class RestSinkOptions {
|
|
|
32
32
|
this.immediateFlushMinLevel = immediateFlushMinLevel;
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
36
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
35
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: RestSinkOptions, deps: "invalid", target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
36
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: RestSinkOptions, providedIn: 'root', useFactory: () => new RestSinkOptions() }); }
|
|
37
37
|
}
|
|
38
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
38
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: RestSinkOptions, decorators: [{
|
|
39
39
|
type: Injectable,
|
|
40
40
|
args: [{ providedIn: 'root', useFactory: () => new RestSinkOptions() }]
|
|
41
41
|
}], ctorParameters: () => [{ type: undefined }, { type: undefined }, { type: i1.LogLevel }] });
|
|
@@ -32,10 +32,10 @@ export class LoggerOptions {
|
|
|
32
32
|
*/
|
|
33
33
|
this.loggerSinks = [];
|
|
34
34
|
}
|
|
35
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
36
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
35
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: LoggerOptions, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
36
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: LoggerOptions, providedIn: 'root' }); }
|
|
37
37
|
}
|
|
38
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
38
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: LoggerOptions, decorators: [{
|
|
39
39
|
type: Injectable,
|
|
40
40
|
args: [{ providedIn: 'root' }]
|
|
41
41
|
}] });
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import { Component, ChangeDetectionStrategy, Input, EventEmitter, Output, ContentChild, TemplateRef, Inject, ChangeDetectorRef, Optional, ElementRef } from '@angular/core';
|
|
2
|
-
import { DOCUMENT } from '@angular/common';
|
|
3
|
-
import { extend } from '@jscrpt/common';
|
|
2
|
+
import { DOCUMENT, NgClass, NgTemplateOutlet } from '@angular/common';
|
|
3
|
+
import { extend } from '@jscrpt/common/extend';
|
|
4
4
|
import { MULTI_BUTTON_CSS_CLASSES } from '../../misc/tokens';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
|
-
import * as i1 from "@angular/common";
|
|
7
6
|
const defaultCssClasses = {
|
|
8
7
|
mainButtonDiv: 'flex-row',
|
|
9
8
|
mainButtonContentDiv: 'multi-button-content',
|
|
@@ -92,12 +91,15 @@ export class MultiButtonComponent {
|
|
|
92
91
|
_removeRegistration() {
|
|
93
92
|
this._document.removeEventListener('click', this._handleClickOutside);
|
|
94
93
|
}
|
|
95
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
96
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
94
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: MultiButtonComponent, deps: [{ token: DOCUMENT }, { token: MULTI_BUTTON_CSS_CLASSES, optional: true }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
95
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.1.0", type: MultiButtonComponent, isStandalone: true, selector: "multi-button", inputs: { cssClass: "cssClass", cssClasses: "cssClasses" }, outputs: { click: "click" }, queries: [{ propertyName: "subButtonsContent", first: true, predicate: TemplateRef, descendants: true }], ngImport: i0, template: "<div [ngClass]=\"[cssClass, cssClasses?.mainButtonDiv]\">\r\n <div (click)=\"click.emit($event)\" [ngClass]=\"cssClasses?.mainButtonContentDiv\">\r\n <ng-content></ng-content>\r\n </div>\r\n\r\n <span [ngClass]=\"cssClasses?.mainButtonSeparatorDiv\"></span>\r\n\r\n <div [ngClass]=\"cssClasses?.mainButtonClickAreaDiv\" (click)=\"showSubButtons($event)\">\r\n <div [ngClass]=\"cssClasses?.mainButtonMultiOptionDiv\"></div>\r\n </div>\r\n</div>\r\n\r\n<div [ngClass]=\"cssClasses?.subButtonsDiv\" *ngIf=\"subButtonsVisible\" [style.top.px]=\"subButtonsOffset\">\r\n <ng-container *ngTemplateOutlet=\"subButtonsContent\"/>\r\n</div>", styles: [":host\r\n{\r\n display: flex;\r\n position: relative;\r\n}\r\n\r\n.multi-option\r\n{\r\n align-self: center;\r\n text-align: center;\r\n flex: 1;\r\n min-width: 0;\r\n}\r\n\r\n.multi-button-content\r\n{\r\n display: flex;\r\n flex-direction: row;\r\n align-items: center;\r\n padding: 3px 8px;\r\n}\r\n\r\n.multi-option-separator\r\n{\r\n border-left-style: solid;\r\n border-left-width: 1px;\r\n margin-top: -1px;\r\n margin-bottom: -1px;\r\n}\r\n\r\n.multi-option-click\r\n{\r\n width: 1.6em;\r\n display: flex;\r\n flex-direction: row;\r\n}\r\n\r\n.sub-buttons\r\n{\r\n display: flex;\r\n flex-direction: column;\r\n position: absolute;\r\n min-width: 100%;\r\n padding: 4px 0;\r\n border-radius: 4px;\r\n}"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
97
96
|
}
|
|
98
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
97
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: MultiButtonComponent, decorators: [{
|
|
99
98
|
type: Component,
|
|
100
|
-
args: [{ selector: 'multi-button',
|
|
99
|
+
args: [{ selector: 'multi-button', imports: [
|
|
100
|
+
NgClass,
|
|
101
|
+
NgTemplateOutlet,
|
|
102
|
+
], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div [ngClass]=\"[cssClass, cssClasses?.mainButtonDiv]\">\r\n <div (click)=\"click.emit($event)\" [ngClass]=\"cssClasses?.mainButtonContentDiv\">\r\n <ng-content></ng-content>\r\n </div>\r\n\r\n <span [ngClass]=\"cssClasses?.mainButtonSeparatorDiv\"></span>\r\n\r\n <div [ngClass]=\"cssClasses?.mainButtonClickAreaDiv\" (click)=\"showSubButtons($event)\">\r\n <div [ngClass]=\"cssClasses?.mainButtonMultiOptionDiv\"></div>\r\n </div>\r\n</div>\r\n\r\n<div [ngClass]=\"cssClasses?.subButtonsDiv\" *ngIf=\"subButtonsVisible\" [style.top.px]=\"subButtonsOffset\">\r\n <ng-container *ngTemplateOutlet=\"subButtonsContent\"/>\r\n</div>", styles: [":host\r\n{\r\n display: flex;\r\n position: relative;\r\n}\r\n\r\n.multi-option\r\n{\r\n align-self: center;\r\n text-align: center;\r\n flex: 1;\r\n min-width: 0;\r\n}\r\n\r\n.multi-button-content\r\n{\r\n display: flex;\r\n flex-direction: row;\r\n align-items: center;\r\n padding: 3px 8px;\r\n}\r\n\r\n.multi-option-separator\r\n{\r\n border-left-style: solid;\r\n border-left-width: 1px;\r\n margin-top: -1px;\r\n margin-bottom: -1px;\r\n}\r\n\r\n.multi-option-click\r\n{\r\n width: 1.6em;\r\n display: flex;\r\n flex-direction: row;\r\n}\r\n\r\n.sub-buttons\r\n{\r\n display: flex;\r\n flex-direction: column;\r\n position: absolute;\r\n min-width: 100%;\r\n padding: 4px 0;\r\n border-radius: 4px;\r\n}"] }]
|
|
101
103
|
}], ctorParameters: () => [{ type: Document, decorators: [{
|
|
102
104
|
type: Inject,
|
|
103
105
|
args: [DOCUMENT]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"multiButton.component.js","sourceRoot":"","sources":["../../../../../../src/modules/multiButton/components/multiButton/multiButton.component.ts","../../../../../../src/modules/multiButton/components/multiButton/multiButton.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,uBAAuB,EAAE,KAAK,EAAE,YAAY,EAAE,MAAM,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,EAAa,iBAAiB,EAAE,QAAQ,EAAE,UAAU,EAAC,MAAM,eAAe,CAAC;AACrL,OAAO,EAAC,QAAQ,EAAC,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"multiButton.component.js","sourceRoot":"","sources":["../../../../../../src/modules/multiButton/components/multiButton/multiButton.component.ts","../../../../../../src/modules/multiButton/components/multiButton/multiButton.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,uBAAuB,EAAE,KAAK,EAAE,YAAY,EAAE,MAAM,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,EAAa,iBAAiB,EAAE,QAAQ,EAAE,UAAU,EAAC,MAAM,eAAe,CAAC;AACrL,OAAO,EAAC,QAAQ,EAAE,OAAO,EAAE,gBAAgB,EAAC,MAAM,iBAAiB,CAAC;AACpE,OAAO,EAAC,MAAM,EAAC,MAAM,uBAAuB,CAAC;AAG7C,OAAO,EAAC,wBAAwB,EAAC,MAAM,mBAAmB,CAAC;;AAE3D,MAAM,iBAAiB,GACvB;IACI,aAAa,EAAE,UAAU;IACzB,oBAAoB,EAAE,sBAAsB;IAC5C,sBAAsB,EAAE,2BAA2B;IACnD,sBAAsB,EAAE,oBAAoB;IAC5C,wBAAwB,EAAE,+BAA+B;IACzD,aAAa,EAAE,aAAa;CAC/B,CAAC;AAEF;;GAEG;AAaH,MAAM,OAAO,oBAAoB;IA+B7B;;OAEG;IACH,IACW,UAAU;QAEjB,OAAO,IAAI,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CAAC,aAAa,CAAC,YAAY,GAAG,CAAC,CAAC;QAErE,IAAG,IAAI,CAAC,iBAAiB,EACzB,CAAC;YACG,IAAI,CAAC,SAAS,CAAC,gBAAgB,CAAC,OAAO,EAAE,IAAI,CAAC,mBAAmB,CAAC,CAAC;QACvE,CAAC;QACD,iCAAiC;aAEjC,CAAC;YACG,IAAI,CAAC,mBAAmB,EAAE,CAAC;QAC/B,CAAC;IACL,CAAC;IAcD;;OAEG;IACO,mBAAmB;QAEzB,IAAI,CAAC,SAAS,CAAC,mBAAmB,CAAC,OAAO,EAAE,IAAI,CAAC,mBAAmB,CAAC,CAAC;IAC1E,CAAC;8GAzHQ,oBAAoB,kBA6DT,QAAQ,aACR,wBAAwB;kGA9DnC,oBAAoB,gNAyDf,WAAW,gDCzF7B,wpBAcM,o0BDaE,OAAO,oFACP,gBAAgB;;2FAIX,oBAAoB;kBAZhC,SAAS;+BAEI,cAAc,WAIxB;wBACI,OAAO;wBACP,gBAAgB;qBACnB,mBACgB,uBAAuB,CAAC,MAAM;;0BA+DlC,MAAM;2BAAC,QAAQ;;0BACf,MAAM;2BAAC,wBAAwB;;0BAAG,QAAQ;kGAjChD,QAAQ;sBADd,KAAK;gBAOK,UAAU;sBADpB,KAAK;gBAgBC,KAAK;sBADX,MAAM;gBASA,iBAAiB;sBADvB,YAAY;uBAAC,WAAW","sourcesContent":["import {Component, ChangeDetectionStrategy, Input, EventEmitter, Output, ContentChild, TemplateRef, Inject, OnDestroy, ChangeDetectorRef, Optional, ElementRef} from '@angular/core';\nimport {DOCUMENT, NgClass, NgTemplateOutlet} from '@angular/common';\nimport {extend} from '@jscrpt/common/extend';\n\nimport {MultiButtonCssClasses} from './multiButton.interface';\nimport {MULTI_BUTTON_CSS_CLASSES} from '../../misc/tokens';\n\nconst defaultCssClasses: MultiButtonCssClasses =\n{\n mainButtonDiv: 'flex-row',\n mainButtonContentDiv: 'multi-button-content',\n mainButtonSeparatorDiv: 'fa multi-option-separator',\n mainButtonClickAreaDiv: 'multi-option-click',\n mainButtonMultiOptionDiv: 'multi-option fa fa-angle-down',\n subButtonsDiv: 'sub-buttons'\n};\n\n/**\n * Component used for displaying multibutton\n */\n@Component(\n{\n selector: 'multi-button',\n templateUrl: 'multiButton.component.html',\n styleUrl: 'multiButton.component.css',\n imports:\n [\n NgClass,\n NgTemplateOutlet,\n ],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class MultiButtonComponent implements OnDestroy\n{\n //######################### protected fields #########################\n\n /**\n * Used css classes within component\n */\n protected _usedCssClasses: MultiButtonCssClasses;\n\n //######################### public properties - template bindings #########################\n\n /**\n * Indication whether are sub buttons visible\n * @internal\n */\n public subButtonsVisible: boolean = false;\n\n /**\n * Sub buttons div top offset\n * @internal\n */\n public subButtonsOffset: number = 0;\n\n //######################### public properties - inputs #########################\n\n /**\n * Css class applied to main displayed element\n */\n @Input()\n public cssClass: string = '';\n\n /**\n * Css classes used within component, allows to change specific class\n */\n @Input()\n public get cssClasses(): MultiButtonCssClasses\n {\n return this._usedCssClasses;\n }\n public set cssClasses(classes: MultiButtonCssClasses)\n {\n this._usedCssClasses = extend({}, this._usedCssClasses, classes);\n }\n\n //######################### public properties - outputs #########################\n\n /**\n * Occurs when user clicks on button\n */\n @Output()\n public click: EventEmitter<MouseEvent> = new EventEmitter<MouseEvent>();\n\n //######################### public properties - children #########################\n\n /**\n * Template that is used for rendering sub buttons content\n */\n @ContentChild(TemplateRef)\n public subButtonsContent: TemplateRef<void>;\n\n //######################### constructor #########################\n constructor(@Inject(DOCUMENT) protected _document: Document,\n @Inject(MULTI_BUTTON_CSS_CLASSES) @Optional() _cssClasess: MultiButtonCssClasses,\n protected _element: ElementRef<HTMLElement>,\n protected _changeDetector: ChangeDetectorRef)\n {\n this._usedCssClasses = extend({}, defaultCssClasses, _cssClasess);\n }\n\n //######################### public methods - implementation of OnDestroy #########################\n \n /**\n * Called when component is destroyed\n */\n public ngOnDestroy(): void\n {\n this._removeRegistration();\n }\n\n //######################### public methods - template bindings #########################\n\n /**\n * Method called when sub buttons should be shown\n */\n public showSubButtons(event: MouseEvent): void\n {\n event.preventDefault();\n event.stopPropagation();\n\n this.subButtonsVisible = !this.subButtonsVisible;\n this.subButtonsOffset = this._element.nativeElement.clientHeight + 2;\n\n if(this.subButtonsVisible)\n {\n this._document.addEventListener('click', this._handleClickOutside);\n }\n //unregister handle click outside\n else\n {\n this._removeRegistration();\n }\n }\n\n //######################### protected methods #########################\n\n /**\n * Handles click outside of multi button element\n */\n protected _handleClickOutside = () =>\n {\n this.subButtonsVisible = false;\n this._removeRegistration();\n this._changeDetector.detectChanges();\n }\n\n /**\n * Removes event registration\n */\n protected _removeRegistration(): void\n {\n this._document.removeEventListener('click', this._handleClickOutside);\n }\n}","<div [ngClass]=\"[cssClass, cssClasses?.mainButtonDiv]\">\r\n <div (click)=\"click.emit($event)\" [ngClass]=\"cssClasses?.mainButtonContentDiv\">\r\n <ng-content></ng-content>\r\n </div>\r\n\r\n <span [ngClass]=\"cssClasses?.mainButtonSeparatorDiv\"></span>\r\n\r\n <div [ngClass]=\"cssClasses?.mainButtonClickAreaDiv\" (click)=\"showSubButtons($event)\">\r\n <div [ngClass]=\"cssClasses?.mainButtonMultiOptionDiv\"></div>\r\n </div>\r\n</div>\r\n\r\n<div [ngClass]=\"cssClasses?.subButtonsDiv\" *ngIf=\"subButtonsVisible\" [style.top.px]=\"subButtonsOffset\">\r\n <ng-container *ngTemplateOutlet=\"subButtonsContent\"/>\r\n</div>"]}
|
|
@@ -1,23 +1,19 @@
|
|
|
1
1
|
import { NgModule } from '@angular/core';
|
|
2
|
-
import { CommonModule } from '@angular/common';
|
|
3
2
|
import { MultiButtonComponent } from '../components/multiButton/multiButton.component';
|
|
4
3
|
import * as i0 from "@angular/core";
|
|
5
4
|
/**
|
|
6
5
|
* Module containing components for displaying multi button
|
|
7
6
|
*/
|
|
8
7
|
export class MultiButtonModule {
|
|
9
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
10
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
11
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
8
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: MultiButtonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
9
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.1.0", ngImport: i0, type: MultiButtonModule, imports: [MultiButtonComponent], exports: [MultiButtonComponent] }); }
|
|
10
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: MultiButtonModule }); }
|
|
12
11
|
}
|
|
13
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
12
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0", ngImport: i0, type: MultiButtonModule, decorators: [{
|
|
14
13
|
type: NgModule,
|
|
15
14
|
args: [{
|
|
16
15
|
imports: [
|
|
17
|
-
|
|
18
|
-
],
|
|
19
|
-
declarations: [
|
|
20
|
-
MultiButtonComponent
|
|
16
|
+
MultiButtonComponent,
|
|
21
17
|
],
|
|
22
18
|
exports: [
|
|
23
19
|
MultiButtonComponent
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"multiButton.module.js","sourceRoot":"","sources":["../../../../../src/modules/multiButton/modules/multiButton.module.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,QAAQ,EAAC,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"multiButton.module.js","sourceRoot":"","sources":["../../../../../src/modules/multiButton/modules/multiButton.module.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,QAAQ,EAAC,MAAM,eAAe,CAAC;AAEvC,OAAO,EAAC,oBAAoB,EAAC,MAAM,iDAAiD,CAAC;;AAErF;;GAEG;AAYH,MAAM,OAAO,iBAAiB;8GAAjB,iBAAiB;+GAAjB,iBAAiB,YAPtB,oBAAoB,aAIpB,oBAAoB;+GAGf,iBAAiB;;2FAAjB,iBAAiB;kBAX7B,QAAQ;mBACT;oBACI,OAAO,EACP;wBACI,oBAAoB;qBACvB;oBACD,OAAO,EACP;wBACI,oBAAoB;qBACvB;iBACJ","sourcesContent":["import {NgModule} from '@angular/core';\n\nimport {MultiButtonComponent} from '../components/multiButton/multiButton.component';\n\n/**\n * Module containing components for displaying multi button\n */\n@NgModule(\n{\n imports:\n [\n MultiButtonComponent,\n ],\n exports:\n [\n MultiButtonComponent\n ]\n})\nexport class MultiButtonModule\n{\n}"]}
|