-
Notifications
You must be signed in to change notification settings - Fork 103
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
feat(ObjectPage): Add 'Pin-Header' button #354
Merged
Merged
Changes from 32 commits
Commits
Show all changes
38 commits
Select commit
Hold shift + click to select a range
49ed1ca
feat(ObjectPage): Add Sticky Header
MarcusNotheis 95a73d6
further refactoring
MarcusNotheis 994f135
Extract AnchorBarStyles to dedicated componnet
MarcusNotheis dc3b91c
Clean up old classes
MarcusNotheis a2b49d6
Cleanup
MarcusNotheis 7148938
Update Tests
MarcusNotheis 779ba9d
Merge remote-tracking branch 'origin/master' into feat/object-page-st…
MarcusNotheis 2b2a199
Merge remote-tracking branch 'origin/master' into feat/object-page-st…
MarcusNotheis cbc6971
Merge remote-tracking branch 'origin/master' into feat/object-page-st…
MarcusNotheis 63939e3
Merge remote-tracking branch 'origin/master' into feat/object-page-st…
MarcusNotheis 94c3563
Fix post merge issue
MarcusNotheis 4374650
WIP: ObjectPageScrolling
MarcusNotheis f496bc9
Fix selected section detection
MarcusNotheis 41b8c1c
Use IconTabBar in Object Page
MarcusNotheis 449eb68
Merge remote-tracking branch 'origin/master' into feat/object-page-st…
MarcusNotheis 44a2391
Fix scrolling
MarcusNotheis 2c80d0c
WIP: Make Tests runnable
MarcusNotheis 592a8dc
Add Intersection Observer polyfill
MarcusNotheis a6bf8de
Fix Scrolling
MarcusNotheis 01e2a14
Add polyfills
MarcusNotheis 792ef9b
Merge branch 'master' into feat/object-page-sticky-header-button
MarcusNotheis a688a52
fix tests
MarcusNotheis d01116c
Update code coverage settings
MarcusNotheis db0a74c
Merge remote-tracking branch 'origin/master' into feat/object-page-st…
MarcusNotheis 3194aa4
Update snapshots
MarcusNotheis 6123a2c
Fix showTitleInHeaderContent scrolling
MarcusNotheis b836425
Fix Display of Expand Collapse Button
MarcusNotheis fb0c24b
Fix ScrollTo Section when subsection was already selected
MarcusNotheis 0a0f506
Improve scrolling
MarcusNotheis 19a864d
Update ObjectPage.test.tsx.snap
MarcusNotheis de710e3
Merge branch 'master' into feat/object-page-sticky-header-button
MarcusNotheis 59eba16
Merge branch 'master' into feat/object-page-sticky-header-button
vbersch 437b884
Improve Styling of AnchorBar
MarcusNotheis 0be724e
Minor improvements
MarcusNotheis 2765d73
Enable scrollTo Subsection
MarcusNotheis fa1aa79
PR Comments: Add deprecation notice
MarcusNotheis d1e93dd
Remove unused code
MarcusNotheis f5e3fa1
ThemingParameters for scroll bar
MarcusNotheis File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 |
---|---|---|
@@ -1,4 +1,9 @@ | ||
import ResizeObserver from 'resize-observer-polyfill'; | ||
import 'intersection-observer'; | ||
import smoothscroll from 'smoothscroll-polyfill'; | ||
|
||
// @ts-ignore | ||
window.ResizeObserver = ResizeObserver; | ||
|
||
// required for scrollTo methods | ||
smoothscroll.polyfill(); |
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 |
---|---|---|
|
@@ -5,76 +5,65 @@ const styles = { | |
width: '100%', | ||
height: '100%', | ||
position: 'relative', | ||
display: 'flex', | ||
flexDirection: 'column', | ||
isolation: 'isolate', | ||
whiteSpace: 'normal', | ||
fontFamily: ThemingParameters.sapFontFamily, | ||
backgroundColor: ThemingParameters.sapBackgroundColor | ||
}, | ||
contentContainer: { | ||
backgroundColor: ThemingParameters.sapBackgroundColor, | ||
overflowX: 'hidden', | ||
overflowY: 'auto', | ||
position: 'relative', | ||
flexGrow: 1 | ||
}, | ||
outerContentContainer: { | ||
width: '100%', | ||
height: '100%', | ||
overflow: 'hidden' | ||
}, | ||
contentScrollContainer: { | ||
position: 'relative' | ||
'&::-webkit-scrollbar': { | ||
backgroundColor: '#ffffff', | ||
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. Theming Parameters? Pretty sure we didn´t have them in place before, but shouldn´t we actually? 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. done |
||
width: '12px' | ||
}, | ||
'&::-webkit-scrollbar-thumb': { | ||
backgroundColor: '#949494', | ||
'&:hover': { | ||
backgroundColor: '#8c8c8c' | ||
} | ||
}, | ||
'&::-webkit-scrollbar-corner': { | ||
backgroundColor: '#ffffff' | ||
}, | ||
'& section[id="ObjectPageSection-1"] > div[role="heading"]': { | ||
display: 'none' | ||
} | ||
}, | ||
anchorBar: { | ||
paddingLeft: '2rem', | ||
backgroundColor: ThemingParameters.sapObjectHeader_Background, | ||
boxShadow: `inset 0 -0.0625rem ${ThemingParameters.sapObjectHeader_BorderColor}, inset 0 0.0625rem ${ThemingParameters.sapObjectHeader_BorderColor}`, | ||
display: 'flex', | ||
height: '2.75rem', | ||
minHeight: '2.75rem', | ||
position: 'relative' | ||
iconTabBarMode: { | ||
'& section[data-component-name="ObjectPageSection"] > div[role="heading"]': { | ||
display: 'none' | ||
} | ||
}, | ||
sectionsContainer: { | ||
'&:before': { | ||
display: 'table', | ||
content: '""' | ||
}, | ||
'& :first-child > div[role="heading"]': { | ||
noHeader: { | ||
'& $header': { | ||
display: 'none' | ||
}, | ||
position: 'relative', | ||
height: '100%', | ||
// overflowX: 'hidden', | ||
// overflowY: 'auto', | ||
overflow: 'hidden', | ||
backgroundColor: ThemingParameters.sapBackgroundColor, | ||
'&:after': { | ||
clear: 'both', | ||
display: 'table', | ||
content: '""' | ||
'& $contentHeader': { | ||
display: 'none' | ||
} | ||
}, | ||
fillerDiv: { | ||
backgroundColor: ThemingParameters.sapBackgroundColor | ||
headerCollapsed: { | ||
'& $contentHeader': { | ||
display: 'none' | ||
} | ||
}, | ||
// header | ||
header: { | ||
flexShrink: 0, | ||
position: 'relative', | ||
backgroundColor: ThemingParameters.sapObjectHeader_Background, | ||
'&$stickied': { | ||
'& $image': { | ||
opacity: '1', | ||
height: '3rem', | ||
width: '3rem', | ||
margin: '0.25rem 1rem 0.25rem 0' | ||
} | ||
} | ||
position: 'sticky', | ||
top: 0, | ||
zIndex: 2 | ||
}, | ||
contentHeader: { | ||
backgroundColor: ThemingParameters.sapObjectHeader_Background, | ||
position: 'relative' | ||
position: 'sticky', | ||
paddingBottom: '0.25rem', | ||
maxHeight: '500px', | ||
overflow: 'hidden', | ||
paddingLeft: '2rem' | ||
}, | ||
anchorBar: { | ||
position: 'sticky', | ||
zIndex: 2 | ||
}, | ||
titleBar: { | ||
padding: '0.5rem 2rem', | ||
|
@@ -122,18 +111,8 @@ const styles = { | |
padding: 0 | ||
} | ||
}, | ||
stickied: {}, | ||
headerContent: { | ||
//paddingTop: '1.5rem', | ||
paddingBottom: '0.25rem', | ||
transition: 'max-height 0.5s', | ||
maxHeight: '500px', | ||
overflow: 'hidden', | ||
paddingLeft: '2rem', | ||
position: 'relative' | ||
}, | ||
titleInHeaderContent: { | ||
'& $headerContent': { | ||
'& contentHeader': { | ||
paddingTop: 0, | ||
'& > *': { | ||
display: 'flex', | ||
|
@@ -148,17 +127,6 @@ const styles = { | |
// paddingTop: 0 | ||
} | ||
}, | ||
alwaysVisibleHeader: { | ||
'& $headerContent': { | ||
paddingLeft: 0 | ||
}, | ||
'& $contentHeader': { | ||
marginTop: '0.5rem' | ||
}, | ||
'& $titleBar': { | ||
paddingBottom: 0 | ||
} | ||
}, | ||
headerCustomContent: { | ||
display: 'inline-block', | ||
verticalAlign: 'top', | ||
|
@@ -196,13 +164,6 @@ const styles = { | |
}, | ||
avatar: { | ||
marginRight: '1rem' | ||
}, | ||
toggleHeaderButton: { | ||
position: 'absolute', | ||
'--_ui5_button_compact_height': '1.25rem', | ||
'--_ui5_button_base_height': '1.25rem', | ||
top: `-0.625rem`, | ||
left: 'calc(50% - 1rem)' | ||
} | ||
}; | ||
|
||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
The Scroller is basically deprecated. No need to introduce breaking changes here.
Lets add a deprecation notice to the Scroller.
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.
done