Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/select component #23

Merged
merged 11 commits into from
Apr 30, 2024
Merged

Feature/select component #23

merged 11 commits into from
Apr 30, 2024

Conversation

patrickjahr
Copy link
Collaborator

No description provided.

@patrickjahr patrickjahr linked an issue Apr 17, 2024 that may be closed by this pull request
@patrickjahr patrickjahr force-pushed the feature/select-component branch 9 times, most recently from f57be20 to a006cc4 Compare April 19, 2024 09:16
@patrickjahr patrickjahr marked this pull request as ready for review April 19, 2024 09:31
Comment on lines +1 to +9
<sk-select [(ngModel)]="selectedValue">
<span skSelectPlaceholder>Select option</span>
<span skSelectLabel>{{ selectedValue?.label }}</span>
@for (option of options; track option.value) {
<sk-select-option [value]="option">
{{ option.label }}
</sk-select-option>
}
</sk-select>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Beautiful <3

private readonly window = inject(DOCUMENT)?.defaultView;

private readonly windowResize = this.window
? toSignal(fromEvent(this.window, 'resize'))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wie wärs mit throttle / debounce?

styleUrl: './select.component.css',
encapsulation: ViewEncapsulation.ShadowDom,
})
export class SelectComponent<T> implements ControlValueAccessor {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sehr cool

@patrickjahr patrickjahr force-pushed the feature/select-component branch from a006cc4 to e8c0e51 Compare April 22, 2024 06:43
@patrickjahr patrickjahr force-pushed the feature/select-component branch from e8c0e51 to af92c80 Compare April 30, 2024 05:33
@patrickjahr patrickjahr merged commit a6cc301 into main Apr 30, 2024
1 check passed
@patrickjahr patrickjahr deleted the feature/select-component branch April 30, 2024 05:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Components / Features / Select
2 participants