-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
wip: added toggle buttons for yes, no, and neutral responses, working…
… on props proper passing
- Loading branch information
Showing
8 changed files
with
79 additions
and
8 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
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
17 changes: 17 additions & 0 deletions
17
packages/design-system/src/ui/button/neutralToggleButton.tsx
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 |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { ToggleButton } from "@repo/design-system/ui"; | ||
import { NeutralIcon } from "@repo/design-system/icons"; | ||
export function NeutralToggleButton() { | ||
return ( | ||
<ToggleButton | ||
kind="inverse" | ||
color="neutral" | ||
icon={NeutralIcon} | ||
iconPosition="left" | ||
compactable | ||
fitContent | ||
wider | ||
> | ||
Nevím | ||
</ToggleButton> | ||
); | ||
} |
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 |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { ToggleButton } from "@repo/design-system/ui"; | ||
import { NoIcon } from "@repo/design-system/icons"; | ||
type Props = { | ||
pressed?: boolean | null; | ||
}; | ||
export function NoToggleButton({ pressed }: Props) { | ||
return ( | ||
<ToggleButton | ||
kind="inverse" | ||
color="secondary" | ||
icon={NoIcon} | ||
iconPosition="left" | ||
compactable | ||
fitContent | ||
wider | ||
data-pressed={pressed ? true : undefined} | ||
> | ||
Ne | ||
</ToggleButton> | ||
); | ||
} |
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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import { ToggleButton } from "@repo/design-system/ui"; | ||
import { YesIcon } from "@repo/design-system/icons"; | ||
|
||
type Props = { | ||
pressed?: boolean | null; | ||
}; | ||
export function YesToggleButton({ pressed }: Props) { | ||
return ( | ||
<ToggleButton | ||
kind="inverse" | ||
color="primary" | ||
icon={YesIcon} | ||
iconPosition="left" | ||
compactable | ||
fitContent | ||
wider | ||
data-pressed={pressed ? true : undefined} | ||
> | ||
Ano | ||
</ToggleButton> | ||
); | ||
} |
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