-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: change signal input modifier to accept whole value signal instea…
…d of set function (#19)
- Loading branch information
1 parent
a3dead7
commit 8687663
Showing
3 changed files
with
9 additions
and
14 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
import {InjectionToken} from "@angular/core"; | ||
import {InjectionToken, WritableSignal} from "@angular/core"; | ||
|
||
export interface SignalInputModifier { | ||
onModelChange(value: unknown): void | ||
|
||
registerOnSet(set: (value: unknown) => void): void; | ||
registerValueSignal(signal: WritableSignal<unknown>): void; | ||
} | ||
|
||
export const SIGNAL_INPUT_MODIFIER = new InjectionToken<SignalInputModifier>('Custom signal input modifier'); |
This file contains 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