Skip to content

Commit b10a643

Browse files
EnxDevLisaHusband
authored andcommitted
fix(theming): Fix visual regressions from theming P6 (apache#33898)
1 parent e428400 commit b10a643

File tree

7 files changed

+15
-13
lines changed

7 files changed

+15
-13
lines changed

superset-frontend/cypress-base/cypress/e2e/dashboard/actions.test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,6 @@ describe('Dashboard actions', () => {
6262
// Verify the color of the outlined star (gray)
6363
cy.get('@starIconOutlinedAfter')
6464
.should('have.css', 'color')
65-
.and('eq', 'rgb(133, 133, 133)');
65+
.and('eq', 'rgba(0, 0, 0, 0.45)');
6666
});
6767
});

superset-frontend/packages/superset-ui-core/src/components/FaveStar/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ export const FaveStar = ({
7171
<Icons.StarOutlined
7272
aria-label="unstarred"
7373
iconSize="l"
74-
iconColor={theme.colors.grayscale.light1}
74+
iconColor={theme.colorTextTertiary}
7575
name="favorite-unselected"
7676
/>
7777
)}

superset-frontend/packages/superset-ui-core/src/components/MetadataBar/MetadataBar.test.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,8 +165,10 @@ test('renders clickable items with blue icons when the bar is collapsed', async
165165
const images = screen.getAllByRole('img');
166166
const clickableColor = window.getComputedStyle(images[0]).color;
167167
const nonClickableColor = window.getComputedStyle(images[1]).color;
168-
expect(clickableColor).toBe(hexToRgb(supersetTheme.colors.primary.base));
169-
expect(nonClickableColor).toBe(hexToRgb(supersetTheme.colorText));
168+
expect(clickableColor).toBe(hexToRgb(supersetTheme.colorPrimary));
169+
expect(nonClickableColor.replace(/\s+/g, '')).toBe(
170+
supersetTheme.colorTextTertiary.replace(/\s+/g, ''),
171+
);
170172
});
171173
});
172174

superset-frontend/packages/superset-ui-core/src/components/MetadataBar/MetadataBar.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ const StyledItem = styled.div<{
8080
padding-right: ${last ? 0 : SPACE_BETWEEN_ITEMS}px;
8181
cursor: ${onClick ? 'pointer' : 'default'};
8282
& .metadata-icon {
83-
color: ${onClick && collapsed ? theme.colorPrimary : theme.colorTextBase};
83+
color: ${onClick && collapsed ? theme.colorPrimary : theme.colorTextTertiary};
8484
padding-right: ${collapsed ? 0 : ICON_PADDING}px;
8585
& .anticon {
8686
line-height: 0;

superset-frontend/src/dashboard/components/Header/index.jsx

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ import {
2626
FeatureFlag,
2727
t,
2828
getExtensionsRegistry,
29-
useTheme,
3029
} from '@superset-ui/core';
3130
import { Global } from '@emotion/react';
3231
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
@@ -159,7 +158,6 @@ const discardChanges = () => {
159158
};
160159

161160
const Header = () => {
162-
const theme = useTheme();
163161
const dispatch = useDispatch();
164162
const [didNotifyMaxUndoHistoryToast, setDidNotifyMaxUndoHistoryToast] =
165163
useState(false);
@@ -650,10 +648,7 @@ const Header = () => {
650648
data-test="header-save-button"
651649
aria-label={t('Save')}
652650
>
653-
<Icons.SaveOutlined
654-
iconColor={hasUnsavedChanges && theme.colors.primary.light5}
655-
iconSize="m"
656-
/>
651+
<Icons.SaveOutlined iconSize="m" />
657652
{t('Save')}
658653
</Button>
659654
</div>

superset-frontend/src/explore/components/controls/TextAreaControl.jsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ import {
2525
TextAreaEditor,
2626
ModalTrigger,
2727
} from '@superset-ui/core/components';
28-
import { t, withTheme } from '@superset-ui/core';
28+
import { t, withTheme, css } from '@superset-ui/core';
2929

3030
import ControlHeader from 'src/explore/components/ControlHeader';
3131

@@ -112,6 +112,11 @@ class TextAreaControl extends Component {
112112
const codeEditor = (
113113
<div>
114114
<TextAreaEditor
115+
css={css`
116+
.ace_gutter-active-line {
117+
background-color: inherit;
118+
}
119+
`}
115120
mode={this.props.language}
116121
style={style}
117122
minLines={minLines}

superset-frontend/src/pages/DatasetList/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,7 @@ const DatasetList: FunctionComponent<DatasetListProps> = ({
468468
'You must be a dataset owner in order to edit. Please reach out to a dataset owner to request modifications or edit access.',
469469
)
470470
}
471-
placement="bottomRight"
471+
placement="bottom"
472472
>
473473
<span
474474
role="button"

0 commit comments

Comments
 (0)