From 8bfa8e6038316ab6d705e9f3affa4fc128cd4eb9 Mon Sep 17 00:00:00 2001 From: mdlufy Date: Mon, 12 Aug 2024 13:53:54 +0300 Subject: [PATCH] fix(kit): icon hover on readonly --- projects/core/styles/theme/wrapper/icon.less | 4 ++++ .../input-date-multi/input-date-multi.template.html | 1 + .../input-date-range/input-date-range.template.html | 1 + .../components/input-date-time/input-date-time.template.html | 1 + projects/kit/components/input-date/input-date.template.html | 1 + 5 files changed, 8 insertions(+) diff --git a/projects/core/styles/theme/wrapper/icon.less b/projects/core/styles/theme/wrapper/icon.less index ef792b4f5d2f..6cfb4a43086a 100644 --- a/projects/core/styles/theme/wrapper/icon.less +++ b/projects/core/styles/theme/wrapper/icon.less @@ -38,4 +38,8 @@ .wrapper-disabled({ opacity: calc(0.5 * var(--tui-disabled-opacity)); }); + + .wrapper-readonly({ + pointer-events: none; + }); } diff --git a/projects/kit/components/input-date-multi/input-date-multi.template.html b/projects/kit/components/input-date-multi/input-date-multi.template.html index 9a270e425248..4e38df142a35 100644 --- a/projects/kit/components/input-date-multi/input-date-multi.template.html +++ b/projects/kit/components/input-date-multi/input-date-multi.template.html @@ -42,6 +42,7 @@ appearance="icon" tuiWrapper [class.t-icon]="!computedDisabled" + [readOnly]="readOnly" [src]="src" (click)="onIconClick()" > diff --git a/projects/kit/components/input-date-range/input-date-range.template.html b/projects/kit/components/input-date-range/input-date-range.template.html index 3ea74797d5a7..31426a95ec5b 100644 --- a/projects/kit/components/input-date-range/input-date-range.template.html +++ b/projects/kit/components/input-date-range/input-date-range.template.html @@ -48,6 +48,7 @@ automation-id="tui-input-date-range__icon" tuiWrapper [class.t-icon]="!computedDisabled" + [readOnly]="readOnly" [src]="src" (click)="onIconClick()" > diff --git a/projects/kit/components/input-date-time/input-date-time.template.html b/projects/kit/components/input-date-time/input-date-time.template.html index 656ebdc2de10..586ee436bc5c 100644 --- a/projects/kit/components/input-date-time/input-date-time.template.html +++ b/projects/kit/components/input-date-time/input-date-time.template.html @@ -35,6 +35,7 @@ appearance="icon" tuiWrapper [class.t-icon]="!computedDisabled" + [readOnly]="readOnly" [src]="src" >