| 
									
										
										
										
											2024-01-21 01:12:57 +01:00
										 |  |  | import * as colors from './00colors.js'; | 
					
						
							| 
									
										
										
										
											2025-06-19 09:41:00 +00:00
										 |  |  | import { DeesInputBase } from './dees-input-base.js'; | 
					
						
							| 
									
										
										
										
											2025-06-19 11:39:16 +00:00
										 |  |  | import { demoFunc } from './dees-input-text.demo.js'; | 
					
						
							| 
									
										
										
										
											2025-06-27 17:32:01 +00:00
										 |  |  | import { cssGeistFontFamily, cssMonoFontFamily } from './00fonts.js'; | 
					
						
							| 
									
										
										
										
											2024-01-21 01:12:57 +01:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  | import { | 
					
						
							|  |  |  |   customElement, | 
					
						
							|  |  |  |   type TemplateResult, | 
					
						
							|  |  |  |   property, | 
					
						
							|  |  |  |   html, | 
					
						
							|  |  |  |   cssManager, | 
					
						
							|  |  |  |   css, | 
					
						
							|  |  |  | } from '@design.estate/dees-element'; | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-03-06 15:48:02 +00:00
										 |  |  | declare global { | 
					
						
							|  |  |  |   interface HTMLElementTagNameMap { | 
					
						
							|  |  |  |     'dees-input-text': DeesInputText; | 
					
						
							|  |  |  |   } | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  | @customElement('dees-input-text') | 
					
						
							| 
									
										
										
										
											2025-06-19 09:41:00 +00:00
										 |  |  | export class DeesInputText extends DeesInputBase { | 
					
						
							| 
									
										
										
										
											2025-06-19 11:39:16 +00:00
										 |  |  |   public static demo = demoFunc; | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-08-20 00:25:14 +02:00
										 |  |  |   // INSTANCE
 | 
					
						
							| 
									
										
										
										
											2021-08-26 21:30:35 +02:00
										 |  |  |   @property({ | 
					
						
							| 
									
										
										
										
											2023-04-06 17:32:49 +02:00
										 |  |  |     type: String, | 
					
						
							|  |  |  |     reflect: true, | 
					
						
							| 
									
										
										
										
											2021-08-26 21:30:35 +02:00
										 |  |  |   }) | 
					
						
							| 
									
										
										
										
											2021-09-01 21:48:22 +02:00
										 |  |  |   public value: string = ''; | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-01-16 11:51:21 +01:00
										 |  |  |   @property({ | 
					
						
							|  |  |  |     type: Boolean, | 
					
						
							|  |  |  |     reflect: true, | 
					
						
							|  |  |  |   }) | 
					
						
							|  |  |  |   public isPasswordBool = false; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   @property({ | 
					
						
							|  |  |  |     type: Boolean, | 
					
						
							|  |  |  |     reflect: true, | 
					
						
							|  |  |  |   }) | 
					
						
							|  |  |  |   public showPasswordBool = false; | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |   @property({ | 
					
						
							|  |  |  |     type: Boolean, | 
					
						
							|  |  |  |     reflect: true, | 
					
						
							|  |  |  |   }) | 
					
						
							|  |  |  |   public validationState: 'valid' | 'warn' | 'invalid'; | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |   @property({ | 
					
						
							|  |  |  |     reflect: true, | 
					
						
							|  |  |  |   }) | 
					
						
							|  |  |  |   public validationText: string = ''; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   @property({}) | 
					
						
							|  |  |  |   validationFunction: (value: string) => boolean; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   public static styles = [ | 
					
						
							| 
									
										
										
										
											2025-06-19 09:41:00 +00:00
										 |  |  |     ...DeesInputBase.baseStyles, | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |     cssManager.defaultStyles, | 
					
						
							|  |  |  |     css`
 | 
					
						
							|  |  |  |       * { | 
					
						
							|  |  |  |         box-sizing: border-box; | 
					
						
							|  |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       :host { | 
					
						
							|  |  |  |         position: relative; | 
					
						
							|  |  |  |         z-index: auto; | 
					
						
							| 
									
										
										
										
											2025-06-27 17:32:01 +00:00
										 |  |  |         font-family: ${cssGeistFontFamily}; | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       .maincontainer { | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         position: relative; | 
					
						
							|  |  |  |         color: ${cssManager.bdTheme('hsl(0 0% 15%)', 'hsl(0 0% 90%)')}; | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       input { | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         display: flex; | 
					
						
							|  |  |  |         height: 40px; | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |         width: 100%; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         padding: 0 12px; | 
					
						
							|  |  |  |         font-size: 14px; | 
					
						
							|  |  |  |         line-height: 40px; | 
					
						
							| 
									
										
										
										
											2025-06-27 18:03:42 +00:00
										 |  |  |         background: ${cssManager.bdTheme('hsl(0 0% 100%)', 'hsl(0 0% 9%)')}; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         border: 1px solid ${cssManager.bdTheme('hsl(0 0% 89.8%)', 'hsl(0 0% 14.9%)')}; | 
					
						
							|  |  |  |         border-radius: 6px; | 
					
						
							| 
									
										
										
										
											2025-06-27 18:03:42 +00:00
										 |  |  |         transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1); | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |         outline: none; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         cursor: text; | 
					
						
							|  |  |  |         font-family: inherit; | 
					
						
							| 
									
										
										
										
											2025-06-27 18:03:42 +00:00
										 |  |  |         color: ${cssManager.bdTheme('hsl(0 0% 3.9%)', 'hsl(0 0% 98%)')}; | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |       input::placeholder { | 
					
						
							| 
									
										
										
										
											2025-06-27 18:03:42 +00:00
										 |  |  |         color: ${cssManager.bdTheme('hsl(0 0% 45.1%)', 'hsl(0 0% 63.9%)')}; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       input:hover:not(:disabled):not(:focus) { | 
					
						
							|  |  |  |         border-color: ${cssManager.bdTheme('hsl(0 0% 79.8%)', 'hsl(0 0% 20.9%)')}; | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       input:focus { | 
					
						
							|  |  |  |         outline: none; | 
					
						
							| 
									
										
										
										
											2025-06-27 18:03:42 +00:00
										 |  |  |         border-color: ${cssManager.bdTheme('hsl(0 0% 9%)', 'hsl(0 0% 98%)')}; | 
					
						
							|  |  |  |         box-shadow: 0 0 0 2px ${cssManager.bdTheme('hsl(0 0% 9% / 0.05)', 'hsl(0 0% 98% / 0.05)')}; | 
					
						
							| 
									
										
										
										
											2023-12-26 21:21:18 +01:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |       input:disabled { | 
					
						
							|  |  |  |         background: ${cssManager.bdTheme('hsl(0 0% 95.1%)', 'hsl(0 0% 14.9%)')}; | 
					
						
							|  |  |  |         border-color: ${cssManager.bdTheme('hsl(0 0% 89.8%)', 'hsl(0 0% 14.9%)')}; | 
					
						
							| 
									
										
										
										
											2025-06-27 18:03:42 +00:00
										 |  |  |         color: ${cssManager.bdTheme('hsl(0 0% 45.1%)', 'hsl(0 0% 63.9%)')}; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         cursor: not-allowed; | 
					
						
							|  |  |  |         opacity: 0.5; | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |       /* Password toggle button */ | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |       .showPassword { | 
					
						
							|  |  |  |         position: absolute; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         right: 1px; | 
					
						
							|  |  |  |         top: 50%; | 
					
						
							|  |  |  |         transform: translateY(-50%); | 
					
						
							|  |  |  |         display: flex; | 
					
						
							|  |  |  |         align-items: center; | 
					
						
							|  |  |  |         justify-content: center; | 
					
						
							|  |  |  |         width: 38px; | 
					
						
							|  |  |  |         height: 38px; | 
					
						
							|  |  |  |         cursor: pointer; | 
					
						
							|  |  |  |         color: ${cssManager.bdTheme('hsl(0 0% 45.1%)', 'hsl(0 0% 63.9%)')}; | 
					
						
							|  |  |  |         transition: all 0.15s ease; | 
					
						
							|  |  |  |         border-radius: 0 5px 5px 0; | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       .showPassword:hover { | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         background: ${cssManager.bdTheme('hsl(0 0% 95.1%)', 'hsl(0 0% 14.9%)')}; | 
					
						
							|  |  |  |         color: ${cssManager.bdTheme('hsl(0 0% 15%)', 'hsl(0 0% 93.9%)')}; | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |       /* Validation styles */ | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |       .validationContainer { | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         margin-top: 4px; | 
					
						
							|  |  |  |         padding: 4px 8px; | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |         font-size: 12px; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         font-weight: 500; | 
					
						
							|  |  |  |         border-radius: 4px; | 
					
						
							|  |  |  |         transition: all 0.2s ease; | 
					
						
							|  |  |  |         overflow: hidden; | 
					
						
							|  |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       .validationContainer.error { | 
					
						
							|  |  |  |         background: ${cssManager.bdTheme('hsl(0 84.2% 60.2% / 0.1)', 'hsl(0 72.2% 50.6% / 0.1)')}; | 
					
						
							|  |  |  |         color: ${cssManager.bdTheme('hsl(0 84.2% 60.2%)', 'hsl(0 72.2% 50.6%)')}; | 
					
						
							|  |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       .validationContainer.warn { | 
					
						
							|  |  |  |         background: ${cssManager.bdTheme('hsl(25 95% 53% / 0.1)', 'hsl(25 95% 63% / 0.1)')}; | 
					
						
							|  |  |  |         color: ${cssManager.bdTheme('hsl(25 95% 53%)', 'hsl(25 95% 63%)')}; | 
					
						
							|  |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       .validationContainer.valid { | 
					
						
							|  |  |  |         background: ${cssManager.bdTheme('hsl(142.1 76.2% 36.3% / 0.1)', 'hsl(142.1 70.6% 45.3% / 0.1)')}; | 
					
						
							|  |  |  |         color: ${cssManager.bdTheme('hsl(142.1 76.2% 36.3%)', 'hsl(142.1 70.6% 45.3%)')}; | 
					
						
							|  |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       /* Error state for input */ | 
					
						
							|  |  |  |       :host([validation-state="invalid"]) input { | 
					
						
							|  |  |  |         border-color: ${cssManager.bdTheme('hsl(0 84.2% 60.2%)', 'hsl(0 72.2% 50.6%)')}; | 
					
						
							|  |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       :host([validation-state="invalid"]) input:focus { | 
					
						
							| 
									
										
										
										
											2025-06-27 18:03:42 +00:00
										 |  |  |         border-color: ${cssManager.bdTheme('hsl(0 84.2% 60.2%)', 'hsl(0 72.2% 50.6%)')}; | 
					
						
							|  |  |  |         box-shadow: 0 0 0 2px ${cssManager.bdTheme('hsl(0 84.2% 60.2% / 0.05)', 'hsl(0 72.2% 50.6% / 0.05)')}; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       /* Warning state for input */ | 
					
						
							|  |  |  |       :host([validation-state="warn"]) input { | 
					
						
							|  |  |  |         border-color: ${cssManager.bdTheme('hsl(25 95% 53%)', 'hsl(25 95% 63%)')}; | 
					
						
							|  |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       :host([validation-state="warn"]) input:focus { | 
					
						
							| 
									
										
										
										
											2025-06-27 18:03:42 +00:00
										 |  |  |         border-color: ${cssManager.bdTheme('hsl(25 95% 53%)', 'hsl(25 95% 63%)')}; | 
					
						
							|  |  |  |         box-shadow: 0 0 0 2px ${cssManager.bdTheme('hsl(25 95% 53% / 0.05)', 'hsl(25 95% 63% / 0.05)')}; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       /* Valid state for input */ | 
					
						
							|  |  |  |       :host([validation-state="valid"]) input { | 
					
						
							|  |  |  |         border-color: ${cssManager.bdTheme('hsl(142.1 76.2% 36.3%)', 'hsl(142.1 70.6% 45.3%)')}; | 
					
						
							|  |  |  |       } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       :host([validation-state="valid"]) input:focus { | 
					
						
							| 
									
										
										
										
											2025-06-27 18:03:42 +00:00
										 |  |  |         border-color: ${cssManager.bdTheme('hsl(142.1 76.2% 36.3%)', 'hsl(142.1 70.6% 45.3%)')}; | 
					
						
							|  |  |  |         box-shadow: 0 0 0 2px ${cssManager.bdTheme('hsl(142.1 76.2% 36.3% / 0.05)', 'hsl(142.1 70.6% 45.3% / 0.05)')}; | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |       } | 
					
						
							|  |  |  |     `,
 | 
					
						
							|  |  |  |   ]; | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |   public render(): TemplateResult { | 
					
						
							|  |  |  |     return html`
 | 
					
						
							|  |  |  |       <style> | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  |         input { | 
					
						
							| 
									
										
										
										
											2025-06-27 17:32:01 +00:00
										 |  |  |           font-family: ${this.isPasswordBool ? cssMonoFontFamily : 'inherit'}; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |           letter-spacing: ${this.isPasswordBool ? '0.5px' : 'normal'}; | 
					
						
							|  |  |  |           padding-right: ${this.isPasswordBool ? '48px' : '12px'}; | 
					
						
							| 
									
										
										
										
											2021-08-26 21:30:35 +02:00
										 |  |  |         } | 
					
						
							| 
									
										
										
										
											2025-06-22 20:32:59 +00:00
										 |  |  |         ${this.validationText | 
					
						
							|  |  |  |           ? css`
 | 
					
						
							|  |  |  |               .validationContainer { | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |                 height: auto; | 
					
						
							| 
									
										
										
										
											2025-06-22 20:32:59 +00:00
										 |  |  |                 opacity: 1; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |                 transform: translateY(0); | 
					
						
							| 
									
										
										
										
											2025-06-22 20:32:59 +00:00
										 |  |  |               } | 
					
						
							|  |  |  |             `
 | 
					
						
							|  |  |  |           : css`
 | 
					
						
							|  |  |  |               .validationContainer { | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |                 height: 0; | 
					
						
							|  |  |  |                 padding: 0 !important; | 
					
						
							| 
									
										
										
										
											2025-06-22 20:32:59 +00:00
										 |  |  |                 opacity: 0; | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |                 transform: translateY(-4px); | 
					
						
							| 
									
										
										
										
											2025-06-22 20:32:59 +00:00
										 |  |  |               } | 
					
						
							|  |  |  |             `}
 | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  |       </style> | 
					
						
							| 
									
										
										
										
											2025-06-19 09:41:00 +00:00
										 |  |  |       <div class="input-wrapper"> | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |         <dees-label .label=${this.label} .description=${this.description} .required=${this.required}></dees-label> | 
					
						
							| 
									
										
										
										
											2025-06-19 09:41:00 +00:00
										 |  |  |         <div class="maincontainer"> | 
					
						
							|  |  |  |           <input | 
					
						
							|  |  |  |             type="${this.isPasswordBool && !this.showPasswordBool ? 'password' : 'text'}" | 
					
						
							|  |  |  |             .value=${this.value} | 
					
						
							|  |  |  |             @input="${this.updateValue}" | 
					
						
							|  |  |  |             .disabled=${this.disabled} | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |             placeholder="${this.label ? '' : 'Enter text...'}" | 
					
						
							| 
									
										
										
										
											2025-06-19 09:41:00 +00:00
										 |  |  |           /> | 
					
						
							|  |  |  |           ${this.isPasswordBool | 
					
						
							|  |  |  |             ? html`
 | 
					
						
							|  |  |  |                 <div class="showPassword" @click=${this.togglePasswordView}> | 
					
						
							| 
									
										
										
										
											2025-09-06 13:29:38 +00:00
										 |  |  |                   <dees-icon .icon=${this.showPasswordBool ? 'lucide:Eye' : 'lucide:EyeOff'}></dees-icon> | 
					
						
							| 
									
										
										
										
											2025-06-19 09:41:00 +00:00
										 |  |  |                 </div> | 
					
						
							|  |  |  |               `
 | 
					
						
							|  |  |  |             : html``} | 
					
						
							| 
									
										
										
										
											2025-06-27 16:20:06 +00:00
										 |  |  |           ${this.validationText | 
					
						
							|  |  |  |             ? html`
 | 
					
						
							|  |  |  |                 <div class="validationContainer ${this.validationState || 'error'}"> | 
					
						
							|  |  |  |                   ${this.validationText} | 
					
						
							|  |  |  |                 </div> | 
					
						
							|  |  |  |               `
 | 
					
						
							|  |  |  |             : html`<div class="validationContainer"></div>`} | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |         </div> | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  |       </div> | 
					
						
							|  |  |  |     `;
 | 
					
						
							|  |  |  |   } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |   firstUpdated() { | 
					
						
							| 
									
										
										
										
											2025-06-19 09:41:00 +00:00
										 |  |  |     // Input event handling is already done in updateValue method
 | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |   } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  |   public async updateValue(eventArg: Event) { | 
					
						
							|  |  |  |     const target: any = eventArg.target; | 
					
						
							|  |  |  |     this.value = target.value; | 
					
						
							| 
									
										
										
										
											2021-08-20 00:25:14 +02:00
										 |  |  |     this.changeSubject.next(this); | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  |   } | 
					
						
							| 
									
										
										
										
											2021-08-26 21:30:35 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-06-19 09:41:00 +00:00
										 |  |  |   public getValue(): string { | 
					
						
							|  |  |  |     return this.value; | 
					
						
							| 
									
										
										
										
											2021-08-26 21:30:35 +02:00
										 |  |  |   } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-06-19 09:41:00 +00:00
										 |  |  |   public setValue(value: string): void { | 
					
						
							|  |  |  |     this.value = value; | 
					
						
							| 
									
										
										
										
											2021-08-26 21:30:35 +02:00
										 |  |  |   } | 
					
						
							| 
									
										
										
										
											2023-01-16 11:51:21 +01:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-10-23 16:13:02 +02:00
										 |  |  |   public async togglePasswordView() { | 
					
						
							| 
									
										
										
										
											2023-01-16 11:51:21 +01:00
										 |  |  |     this.showPasswordBool = !this.showPasswordBool; | 
					
						
							|  |  |  |   } | 
					
						
							| 
									
										
										
										
											2023-03-27 01:22:15 +02:00
										 |  |  | 
 | 
					
						
							|  |  |  |   public async focus() { | 
					
						
							|  |  |  |     const textInput = this.shadowRoot.querySelector('input'); | 
					
						
							|  |  |  |     textInput.focus(); | 
					
						
							|  |  |  |   } | 
					
						
							| 
									
										
										
										
											2023-04-12 02:47:45 +02:00
										 |  |  | 
 | 
					
						
							|  |  |  |   public async blur() { | 
					
						
							|  |  |  |     const textInput = this.shadowRoot.querySelector('input'); | 
					
						
							|  |  |  |     textInput.blur(); | 
					
						
							|  |  |  |   } | 
					
						
							| 
									
										
										
										
											2020-09-13 16:24:48 +00:00
										 |  |  | } |