Skip to content

Commit

Permalink
ar(fix) nits.
Browse files Browse the repository at this point in the history
  • Loading branch information
angeloreale committed Jul 12, 2024
1 parent 21d9778 commit 9bdff0d
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 18 deletions.
11 changes: 7 additions & 4 deletions src/atoms/01_Button/Button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ export interface IButton {
rel?: string;
icon?: ESystemIcon;
iconPosition?: EButtonIconPosition;
type?: string;
id?: string;
}

Expand All @@ -56,6 +57,7 @@ export const HButton = function ({
icon,
iconPosition = EButtonIconPosition.START,
id = 'atom__button',
type,
onClick = () => {},
}: IButton) {
const external = {
Expand All @@ -79,13 +81,13 @@ export const HButton = function ({
class1
text-body-dark
dark:text-body-dark
dark:text-body-light
bg-primary-light
hover:bg-primary-contrast
dark:bg-primary-contrast
dark:hover:bg-primary-dark
dark:bg-primary-white
dark:hover:bg-primary-soft
`]: variant === ButtonVariant.FILLED,
[`
Expand Down Expand Up @@ -217,7 +219,7 @@ export const HButton = function ({
[EButtonTheme.PASSION_SELECTED]: EIconColor.PASSION_SELECTED,
},
[ButtonVariant.FILLED]: {
[EButtonTheme.PRIMARY]: EIconColor.WHITE,
[EButtonTheme.PRIMARY]: EIconColor.PRIMARY,
[EButtonTheme.SECONDARY]: EIconColor.WHITE,
[EButtonTheme.PASSION]: EIconColor.PASSION,
[EButtonTheme.PASSION_SELECTED]: EIconColor.PASSION_SELECTED,
Expand All @@ -236,6 +238,7 @@ export const HButton = function ({
className={styles}
variant={variant}
onClick={onClick}
type={type}
>
{icon && iconPosition === EButtonIconPosition.START ? (
<Icon
Expand Down
3 changes: 3 additions & 0 deletions src/atoms/07_Dropdown/Dropdown.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ export interface IDropdown {
icon?: ESystemIcon;
onSelect?: (e?: string | number) => void;
variant?: EDropdownVariant;
name?: string;
id?: string;
}

Expand Down Expand Up @@ -94,6 +95,7 @@ export const HDropdown = function ({
icon,
variant = EDropdownVariant.OUTLINED,
onSelect = () => {},
name = '',
id = 'atom__dropdown',
}: IDropdown) {
const [value, setValue] = useState('');
Expand Down Expand Up @@ -214,6 +216,7 @@ export const HDropdown = function ({
/>
<Select
id={id}
name={name}
className={selectStyles}
value={value}
onChange={(e) => {
Expand Down
6 changes: 6 additions & 0 deletions src/atoms/09_TextInput/TextInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ export interface ITextInput extends ITextInputExtraProps {
onChange?: (e?: any) => void;
theme?: string;
variant?: ETextInputVariant;
name?: string;
type?: string;
id?: string;
}

Expand Down Expand Up @@ -107,6 +109,8 @@ export const HTextInput = function (props: ITextInput) {
onChange = () => {},
id = 'atom__textinput',
theme = 'light',
name = '',
type = 'text',
...extraProps
} = props;

Expand Down Expand Up @@ -232,6 +236,8 @@ export const HTextInput = function (props: ITextInput) {
/>
<OutlinedInput
id={id}
name={name}
type={type}
className={selectStyles}
value={value}
startAdornment={placeholder ? StartAdornment : undefined}
Expand Down
3 changes: 3 additions & 0 deletions src/atoms/12_DateRange/DateRange.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ export interface IDateRange {
theme?: 'light' | 'dark';
disablePast?: boolean;
onSelect?: (e?: any) => void;
name?: string;
id?: string;
}

Expand All @@ -45,6 +46,7 @@ export const HDateRange = function ({
disablePast = true,
label = 'Pick your dates',
onSelect = () => {},
name = '',
id = 'atom__daterange',
}: IDateRange) {
// eslint-disable-next-line @typescript-eslint/no-unused-vars
Expand Down Expand Up @@ -207,6 +209,7 @@ export const HDateRange = function ({
callbackRef: textRef,
onClick: handleOpen,
theme,
name,
} as any,
actionBar: {
actions: ['clear', 'today', 'accept'],
Expand Down
8 changes: 5 additions & 3 deletions src/molecules/00_Card/Card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -118,20 +118,22 @@ export const HCard = function ({
{title}
</Typography>
<Typography
inherit
variant={TypographyVariant.SMALL}
className="w-full pt-a1 pb-0 text-neutral-light dark:text-neutral-dark col-span-full col-start-0 md:col-span-full md:col-start-0"
className="w-full pt-a1 pb-0 text-neutral-light dark:text-body-dark col-span-full col-start-0 md:col-span-full md:col-start-0"
>
{where}
</Typography>
<Typography
inherit
variant={TypographyVariant.SMALL}
className="w-full pt-0 text-neutral-light dark:text-neutral-dark col-span-full col-start-0 md:col-span-full md:col-start-0"
className="w-full pt-0 text-neutral-light dark:text-body-dark col-span-full col-start-0 md:col-span-full md:col-start-0"
>
{when}
</Typography>
<PriceTag
variant={EPriceTagVariant.NORMAL}
className="w-full pt-a2 pb-a0 text-neutral-light dark:text-neutral-dark col-span-4 col-start-0 md:col-span-4 md:col-start-0"
className="w-full pt-a2 pb-a0 col-span-4 col-start-0 md:col-span-4 md:col-start-0"
>
{price}
</PriceTag>
Expand Down
23 changes: 12 additions & 11 deletions tailwind.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ const inc06b = base * 6.5; // 52
const n100 = '#191919';
const n200 = '#1b1b1b';
const n300 = '#aaaaaa';
const n400 = '#440000';
const n500 = '#550000';
const n600 = '#660000';
const n400 = '#ffffff';
// const n500 = '#550000';
// const n600 = '#660000';

const st0 = '#F69240';
const st1 = '#F8D49A';
Expand Down Expand Up @@ -59,9 +59,6 @@ const secondary = dp200;
const primary = dp800;
const tertiary = dp800;

const light1 = dp300;
const light2 = dp200;

const dark1 = n100;
const dark2 = n200;

Expand All @@ -71,6 +68,9 @@ const passionSoft = '#880000';

const white = '#ffffff';

const light1 = dp300;
const light2 = dp200;

export const DreamPipColors = {
transparent,
logo: {
Expand Down Expand Up @@ -118,17 +118,18 @@ export const DreamPipColors = {
primary: {
light: primary,
contrast: secondary,
dark: light1,
dark: light2,
passion,
passionLight,
passionSoft,
soft: bg2,
green: dp700,
white,
},
secondary: {
light: secondary,
constrast: light1,
dark: light1,
dark: light2,
passion,
passionLight,
passionSoft,
Expand All @@ -147,7 +148,7 @@ export const DreamPipColors = {
},
},
soft: {
light: light1,
light: white,
constrast: light2,
bg: bg2,
dark: '#C9FFC4',
Expand All @@ -167,8 +168,8 @@ export const DreamPipColors = {
dark: '#353535',
},
neutral: {
light: n400,
dark: n200,
light: n200,
dark: n400,
},
};

Expand Down

0 comments on commit 9bdff0d

Please sign in to comment.