feat: #1125 tree select component#1158
Open
gokhanakn wants to merge 8 commits into
Open
Conversation
Enes5519
requested changes
Feb 13, 2026
Enes5519
requested changes
Feb 23, 2026
| kind="neutral" | ||
| size="small" | ||
| icon="close" | ||
| label="Temizle" |
Contributor
There was a problem hiding this comment.
Bunu da lit localize dahil edebilir miyiz
Comment on lines
+478
to
+515
| const injectedStyle = document.createElement("style"); | ||
|
|
||
| injectedStyle.textContent = [ | ||
| ".popover-no-result { display: none !important; }", | ||
| ".popover { max-height: 400px !important; padding: 0 !important; }", | ||
| ":host([has-tree-value]) .select-wrapper { --placeholder-color: var(--bl-color-neutral-darker); }", | ||
| ].join("\n"); | ||
| this._selectEl.shadowRoot?.appendChild(injectedStyle); | ||
|
|
||
| const origOpen = this._selectEl.open.bind(this._selectEl); | ||
| const origClose = this._selectEl.close.bind(this._selectEl); | ||
|
|
||
| this._selectEl.open = () => { | ||
| if (this.disabled) return; | ||
| origOpen(); | ||
| this._open = true; | ||
| }; | ||
|
|
||
| this._selectEl.close = () => { | ||
| origClose(); | ||
| this._open = false; | ||
| this._searchText = ""; | ||
| this._focusedIndex = 0; | ||
| }; | ||
|
|
||
| this._selectEl.addEventListener( | ||
| "keydown", | ||
| (e: KeyboardEvent) => { | ||
| if (!this._open) return; | ||
| if (["ArrowDown", "ArrowUp", "ArrowLeft", "ArrowRight", " ", "Enter"].includes(e.key)) { | ||
| e.preventDefault(); | ||
| e.stopPropagation(); | ||
| this._onPanelKeydown(e); | ||
| } | ||
| }, | ||
| true | ||
| ); | ||
| } |
Contributor
There was a problem hiding this comment.
bl-select elementini hacky kullanmışız.
- bl-select t anında güncellendiğinde bu kod kırılabilir.
- monkey patching yapıyoruz belki event dinleyebilirdik debug edilmesi zor hale getirebilir.
- style inject etmemizde encapsulation'ı bozmuş
Buradaki ilk yaptığımız yaklaşım buraya göre daha temizdi aslında kendi popover'ı ve input'u olabilir.
Enes5519
reviewed
Feb 23, 2026
| | `view-select-all` | `boolean` | Show "Select All" row (only when `is-multiple`) | `false` | | ||
| | `select-all-text` | `string` | Text for Select All row | `"Select All"` | | ||
| | `search-placeholder` | `string` | Placeholder for search inside dropdown | `""` | | ||
| | `empty-result-text` | `string` | Message when search has no results | `"Sonuç Bulunamadı."` | |
Contributor
There was a problem hiding this comment.
Bu default value elementte uygulanmamış lit-localize kapsamında ekleyebilriiz
Contributor
|
Selection works perfect but inputs are way different than our styles. We can use the exact features of select inputs here, too. Thank you @gokhanakn 🙏🏻 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.