-
Notifications
You must be signed in to change notification settings - Fork 134
Tshepo/f/drawer #3139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tshepo/f/drawer #3139
Changes from all commits
53183ce
d44a33a
2a54655
8d8aa0d
357d433
0e4fbdf
5aecc5f
ebb1c9c
3189558
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -26,6 +26,7 @@ | |||||||||
| footerStyle?: CSSProperties; | ||||||||||
| placement?: 'top' | 'right' | 'bottom' | 'left'; | ||||||||||
| width?: string | number; | ||||||||||
| height?: string | number; | ||||||||||
| readOnly?: boolean; | ||||||||||
| background?: CSSProperties; | ||||||||||
| } | ||||||||||
|
|
@@ -38,7 +39,6 @@ | |||||||||
| const { | ||||||||||
| id, | ||||||||||
| placement, | ||||||||||
| width, | ||||||||||
| componentName: name, | ||||||||||
| readOnly, | ||||||||||
| label, | ||||||||||
|
|
@@ -140,18 +140,26 @@ | |||||||||
| </Fragment> | ||||||||||
| ); | ||||||||||
| } | ||||||||||
| console.log('width', style?.width); | ||||||||||
|
Check failure on line 143 in shesha-reactjs/src/designer-components/drawer/drawer.tsx
|
||||||||||
| console.log('height', style?.height); | ||||||||||
|
Check failure on line 144 in shesha-reactjs/src/designer-components/drawer/drawer.tsx
|
||||||||||
| console.log('style', props); | ||||||||||
|
Check failure on line 145 in shesha-reactjs/src/designer-components/drawer/drawer.tsx
|
||||||||||
|
|
||||||||||
| return ( | ||||||||||
| <Drawer | ||||||||||
| open={state?.open} | ||||||||||
| placement={placement} | ||||||||||
| width={width} | ||||||||||
| // width='100%' | ||||||||||
| // height='100%' | ||||||||||
|
Comment on lines
+151
to
+152
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Remove commented-out code. Commented-out code should be removed rather than committed. If these properties are meant to be replaced with a different approach for handling dimensions, consider implementing the new approach directly. -// width='100%'
-// height='100%'📝 Committable suggestion
Suggested change
|
||||||||||
| onClose={closeDrawer} | ||||||||||
| styles={{ | ||||||||||
| header: { display: showHeader ? 'block' : 'none', ...headerStyle }, | ||||||||||
| footer: { display: showFooter ? 'block' : 'none', ...footerStyle }, | ||||||||||
| body: background, | ||||||||||
| content: style, | ||||||||||
| // wrapper: { | ||||||||||
| // width: style?.width, | ||||||||||
| // height: style?.height, | ||||||||||
| // }, | ||||||||||
|
Comment on lines
+159
to
+162
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Remove commented-out styles wrapper. Commented-out code creates confusion and clutters the codebase. Based on the AI summary, it appears you're refactoring how styles are managed. Either implement the new approach directly or remove the commented section entirely. -// wrapper: {
-// width: style?.width,
-// height: style?.height,
-// },If the dimensions are now being handled through a different mechanism (like the customStyle property mentioned in the AI summary), please ensure that's properly implemented and documented. 📝 Committable suggestion
Suggested change
|
||||||||||
| }} | ||||||||||
| title={label} | ||||||||||
| size="large" | ||||||||||
|
|
||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove console.log statements causing build failures.
These console.log statements are causing pipeline failures. According to the static analysis tool, only specific console methods are allowed: warn, dir, timeLog, assert, clear, count, countReset, group, groupEnd, table, dirxml, error, groupCollapsed, Console, profile, profileEnd, timeStamp, context.
Replace with either:
Or remove them entirely if they were only for debugging purposes.
📝 Committable suggestion
🧰 Tools
🪛 GitHub Check: build-attempt
[failure] 143-143:
Unexpected console statement. Only these console methods are allowed: warn, dir, timeLog, assert, clear, count, countReset, group, groupEnd, table, dirxml, error, groupCollapsed, Console, profile, profileEnd, timeStamp, context
[failure] 144-144:
Unexpected console statement. Only these console methods are allowed: warn, dir, timeLog, assert, clear, count, countReset, group, groupEnd, table, dirxml, error, groupCollapsed, Console, profile, profileEnd, timeStamp, context
[failure] 145-145:
Unexpected console statement. Only these console methods are allowed: warn, dir, timeLog, assert, clear, count, countReset, group, groupEnd, table, dirxml, error, groupCollapsed, Console, profile, profileEnd, timeStamp, context
🪛 GitHub Actions: shesha-reactjs-build
[error] 143-143: Unexpected console statement. Only these console methods are allowed: warn, dir, timeLog, assert, clear, count, countReset, group, groupEnd, table, dirxml, error, groupCollapsed, Console, profile, profileEnd, timeStamp, context (no-console)