-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
34 changed files
with
167 additions
and
261 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export { default as RawNav } from './RawNav'; |
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 @@ | ||
export { default as RawUL } from './RawUL'; |
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 { styled } from 'styled-components'; | ||
import { getColorsForComponent } from '@/design/designFunctions/colorCalculatorForComponent'; | ||
|
||
import { TLayer } from '@/interface/TLayer'; | ||
import { TTheme } from '@/interface/TTheme'; | ||
import { TThemeTypes } from '@/interface/TThemeTypes'; | ||
import { animated } from '@react-spring/web'; | ||
|
||
// Define the styled component for the dialog | ||
export const StyledDialog = styled(animated.div)<{ theme: TTheme; $themeType?: TThemeTypes; $layer?: TLayer }>` | ||
position: fixed; | ||
top: 50%; | ||
left: 50%; | ||
transform: translate(-50%, -50%); | ||
padding: ${({ theme }) => theme.spacing.xl}; | ||
border-radius: ${({ theme }) => theme.borderRadius.lg}; | ||
border: none; | ||
width: 70%; | ||
max-height: 85%; | ||
${({ theme, $themeType = 'primary', $layer = 1 }) => getColorsForComponent({ theme, $themeType, $layer })} | ||
z-index: 1000; | ||
`; |
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,31 @@ | ||
import { styled } from 'styled-components'; | ||
|
||
import { TLayer } from '@/interface/TLayer'; | ||
import { TThemeTypes } from '@/interface/TThemeTypes'; | ||
import { getBackgroundColor } from '@/design/designFunctions/colorCalculatorForComponent'; | ||
import { TTheme } from '@/interface/TTheme'; | ||
import { fontSize } from '@/design/theme/designSizes'; | ||
|
||
// the style for a single input | ||
interface StyledSingleInputProps { | ||
$hasValue: boolean; | ||
$isFocused: boolean; | ||
$themeType?: TThemeTypes; | ||
$layer?: TLayer; | ||
} | ||
export const StyledSingleInput = styled.input<StyledSingleInputProps & { theme: TTheme }>` | ||
aspect-ratio: 4/5; | ||
width: 1.5ch; | ||
font-size: ${fontSize.xxl}; | ||
text-align: center; | ||
color: ${({ theme }) => theme.colors.secondary[0]}; | ||
border: 1.5px solid | ||
${({ $hasValue, theme, $themeType = 'secondary', $layer }) => | ||
$hasValue ? theme.colors.accent[0] : getBackgroundColor({ theme, $themeType, $layer })}; | ||
border-radius: 5px; | ||
padding: ${({ theme }) => theme.spacing.xs}; | ||
background-color: transparent; | ||
appearance: none; | ||
outline: none; | ||
box-shadow: ${({ $isFocused, theme }) => ($isFocused ? `0 0 2px 1px${theme.colors.accent[1]}` : 'none')}; | ||
`; |
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,41 @@ | ||
import React, { forwardRef, useState } from 'react'; | ||
|
||
import { TThemeTypes } from '@/interface/TThemeTypes'; | ||
import { TLayer } from '@/interface/TLayer'; | ||
import { StyledSingleInput } from './SingleInput.style'; | ||
|
||
// --------------------------------------------------------------------------- // | ||
// --------- A Single Letter/NumberInput for a Verification process ---------- // | ||
// --------------------------------------------------------------------------- // | ||
interface ISingleInputAtomProps { | ||
value: string; | ||
ariaLabel?: string; | ||
onKeyDown?: (e: React.KeyboardEvent<HTMLInputElement>) => void; | ||
themeType?: TThemeTypes; | ||
layer?: TLayer; | ||
} | ||
const SingleInputAtom = forwardRef<HTMLInputElement, ISingleInputAtomProps>((props, ref) => { | ||
const { value, ariaLabel, onKeyDown, themeType, layer } = props; | ||
const [isFocused, setIsFocused] = useState(false); | ||
|
||
return ( | ||
<StyledSingleInput | ||
type="text" | ||
$themeType={themeType} | ||
$layer={layer} | ||
maxLength={1} | ||
value={value} | ||
onKeyDown={onKeyDown} | ||
ref={ref} | ||
aria-label={ariaLabel} | ||
// eslint-disable-next-line @typescript-eslint/no-empty-function | ||
onChange={() => {}} | ||
onFocus={() => setIsFocused(true)} | ||
onBlur={() => setIsFocused(false)} | ||
$hasValue={value.length > 0} | ||
$isFocused={isFocused} | ||
/> | ||
); | ||
}); | ||
|
||
export default SingleInputAtom; |
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 @@ | ||
export { default as SingleInput } from './SingleInput'; |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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 was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
4 changes: 2 additions & 2 deletions
4
src/components/atoms/SpeedDialMenueItem/SpeedDailMenueItem.style.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
Oops, something went wrong.