kgabryje commented on code in PR #22474:
URL: https://github.com/apache/superset/pull/22474#discussion_r1080932846
##########
superset-frontend/src/dashboard/components/DashboardBuilder/DashboardBuilder.tsx:
##########
@@ -164,75 +185,247 @@ const StyledContent = styled.div<{
${({ fullSizeChartId }) => fullSizeChartId && `z-index: 101;`}
`;
+const DashboardContentWrapper = styled.div`
+ ${({ theme }) => css`
+ &.dashboard {
+ position: relative;
+ flex-grow: 1;
+ display: flex;
+ flex-direction: column;
+ height: 100%;
+
+ /* drop shadow for top-level tabs only */
+ & .dashboard-component-tabs {
+ box-shadow: 0 ${theme.gridUnit}px ${theme.gridUnit}px 0
+ ${addAlpha(
+ theme.colors.grayscale.dark2,
+ parseFloat(theme.opacity.light) / 100,
+ )};
+ padding-left: ${theme.gridUnit *
+ 2}px; /* note this is added to tab-level padding, to match header */
+ }
+
+ .dropdown-toggle.btn.btn-primary .caret {
+ color: ${theme.colors.grayscale.light5};
+ }
+
+ .background--transparent {
+ background-color: transparent;
+ }
+
+ .background--white {
+ background-color: ${theme.colors.grayscale.light5};
+ }
+ }
+ &.dashboard--editing {
+ .grid-row:after,
+ .dashboard-component-tabs > .hover-menu:hover + div:after {
+ border: 1px dashed transparent;
+ content: '';
+ position: absolute;
+ width: 100%;
+ height: 100%;
+ top: 0;
+ left: 0;
+ z-index: 1;
+ pointer-events: none;
+ }
+
+ .resizable-container {
+ & .dashboard-component-chart-holder {
+ .dashboard-chart {
+ .chart-container {
+ cursor: move;
+ opacity: 0.2;
+ }
+
+ .slice_container {
+ /* disable chart interactions in edit mode */
+ pointer-events: none;
+ }
+ }
+
+ &:hover .dashboard-chart .chart-container {
+ opacity: 0.7;
+ }
+ }
+
+ &:hover,
+ &.resizable-container--resizing:hover {
+ & > .dashboard-component-chart-holder:after {
+ border: 1px dashed ${theme.colors.primary.base};
+ }
+ }
+ }
+
+ .resizable-container--resizing:hover > .grid-row:after,
+ .hover-menu:hover + .grid-row:after,
+ .dashboard-component-tabs > .hover-menu:hover + div:after {
+ border: 1px dashed ${theme.colors.primary.base};
+ z-index: 2;
+ }
+
+ .grid-row:after,
+ .dashboard-component-tabs > .hover-menu + div:after {
+ border: 1px dashed ${theme.colors.grayscale.light2};
+ }
+
+ /* provide hit area in case row contents is edge to edge */
+ .dashboard-component-tabs-content {
+ .dragdroppable-row {
+ padding-top: ${theme.gridUnit * 4}px;
+ }
+
+ & > div:not(:last-child):not(.empty-droptarget) {
+ margin-bottom: ${theme.gridUnit * 4}px;
+ }
+ }
+
+ .dashboard-component-chart-holder {
+ &:after {
+ content: '';
+ position: absolute;
+ width: 100%;
+ height: 100%;
+ top: 0;
+ left: 0;
+ z-index: 1;
Review Comment:
👍
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]