-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Left Padding removed in Settings Page Tabs
- Loading branch information
1 parent
f3fe3ab
commit beb285d
Showing
5 changed files
with
48 additions
and
9 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
1 change: 1 addition & 0 deletions
1
packages/twenty-front/src/modules/ui/layout/tab/components/Constant.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 @@ | ||
export const DEFAULT_PADDING = 0; |
26 changes: 26 additions & 0 deletions
26
packages/twenty-front/src/modules/ui/layout/tab/components/CustomPaddings.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,26 @@ | ||
import React from 'react'; | ||
|
||
interface CustomPaddingsProps { | ||
padding?: string | number; | ||
children: React.ReactNode; | ||
} | ||
|
||
export const CustomPaddings: React.FC<CustomPaddingsProps> = ({ | ||
padding, | ||
children, | ||
}) => { | ||
const paddingValue = typeof padding === 'number' ? `${padding}px` : padding; | ||
|
||
return ( | ||
<div | ||
className={`custom-padding`} | ||
style={ | ||
{ | ||
'--custom-padding': paddingValue, | ||
} as React.CSSProperties | ||
} | ||
> | ||
{children} | ||
</div> | ||
); | ||
}; |
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