-
-
Notifications
You must be signed in to change notification settings - Fork 167
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: ButterscotchV <[email protected]>
- Loading branch information
1 parent
30adeb2
commit 0ad3b9f
Showing
17 changed files
with
432 additions
and
190 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
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
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,45 @@ | ||
import classNames from 'classnames'; | ||
import { Control, Controller } from 'react-hook-form'; | ||
|
||
export function ThemeSelector({ | ||
control, | ||
name, | ||
value, | ||
// input props | ||
disabled, | ||
colors, | ||
...props | ||
}: { | ||
control: Control<any>; | ||
name: string; | ||
colors: string | undefined; | ||
value: string | number; | ||
} & React.HTMLProps<HTMLInputElement>) { | ||
return ( | ||
<Controller | ||
control={control} | ||
name={name} | ||
render={({ field: { onChange, ref, name, value: checked } }) => ( | ||
<input | ||
type="radio" | ||
className={classNames( | ||
colors, | ||
'focus:ring-transparent focus:ring-offset-transparent', | ||
'focus:outline-transparent appearance-none border-4 border-solid', | ||
'border-transparent checked:!border-accent-background-30 w-16 h-16' | ||
)} | ||
style={{ | ||
WebkitTextFillColor: 'transparent', | ||
}} | ||
name={name} | ||
ref={ref} | ||
onChange={onChange} | ||
value={value} | ||
checked={value == checked} | ||
disabled={disabled} | ||
{...props} | ||
/> | ||
)} | ||
/> | ||
); | ||
} |
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,17 +1,16 @@ | ||
import classNames from 'classnames'; | ||
|
||
export function MaximiseIcon({ className }: { className?: string }) { | ||
return ( | ||
<svg | ||
width="35" | ||
height="35" | ||
className={className} | ||
className={classNames('stroke-window-icon', className)} | ||
viewBox="0 0 31 29" | ||
fill="none" | ||
xmlns="http://www.w3.org/2000/svg" | ||
> | ||
<path | ||
d="M18 11.5H14C13.1716 11.5 12.5 12.1716 12.5 13V17C12.5 17.8284 13.1716 18.5 14 18.5H18C18.8284 18.5 19.5 17.8284 19.5 17V13C19.5 12.1716 18.8284 11.5 18 11.5Z" | ||
stroke="#C0A1D8" | ||
/> | ||
<path d="M18 11.5H14C13.1716 11.5 12.5 12.1716 12.5 13V17C12.5 17.8284 13.1716 18.5 14 18.5H18C18.8284 18.5 19.5 17.8284 19.5 17V13C19.5 12.1716 18.8284 11.5 18 11.5Z" /> | ||
</svg> | ||
); | ||
} |
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,13 +1,15 @@ | ||
import classNames from 'classnames'; | ||
|
||
export function MinimiseIcon({ className }: { className?: string }) { | ||
return ( | ||
<svg | ||
width="35" | ||
height="35" | ||
className={className} | ||
className={classNames('stroke-window-icon', className)} | ||
viewBox="0 0 31 29" | ||
xmlns="http://www.w3.org/2000/svg" | ||
> | ||
<path d="M20.5 15.5H10.5" stroke="#C0A1D8" strokeLinecap="round" /> | ||
<path d="M20.5 15.5H10.5" strokeLinecap="round" /> | ||
</svg> | ||
); | ||
} |
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
Oops, something went wrong.