Skip to content

Commit

Permalink
Fix dashboard tags margin
Browse files Browse the repository at this point in the history
It was using a class only defined in `Insight.scss`, so the class didn't actually work in dashboards.
  • Loading branch information
Twixes committed Nov 20, 2023
1 parent 7f15824 commit f9a0945
Showing 4 changed files with 7 additions and 15 deletions.
4 changes: 2 additions & 2 deletions frontend/src/scenes/dashboard/DashboardHeader.tsx
Original file line number Diff line number Diff line change
@@ -364,14 +364,14 @@ export function DashboardHeader(): JSX.Element | null {
onChange={(_, tags) => triggerDashboardUpdate({ tags })}
saving={dashboardLoading}
tagsAvailable={tags.filter((tag) => !dashboard.tags?.includes(tag))}
className="insight-metadata-tags"
className="mt-2"
/>
) : dashboard.tags.length ? (
<ObjectTags
tags={dashboard.tags}
saving={dashboardLoading}
staticOnly
className="insight-metadata-tags"
className="mt-2"
/>
) : null}
</>
6 changes: 3 additions & 3 deletions frontend/src/scenes/feature-flags/FeatureFlag.tsx
Original file line number Diff line number Diff line change
@@ -332,7 +332,7 @@ export function FeatureFlag({ id }: { id?: string } = {}): JSX.Element {
tagsAvailable={tags.filter(
(tag) => !featureFlag.tags?.includes(tag)
)}
className="insight-metadata-tags"
className="mt-2"
/>
)
}}
@@ -510,14 +510,14 @@ export function FeatureFlag({ id }: { id?: string } = {}): JSX.Element {
tagsAvailable={tags.filter(
(tag) => !featureFlag.tags?.includes(tag)
)}
className="insight-metadata-tags"
className="mt-2"
/>
) : featureFlag.tags.length ? (
<ObjectTags
tags={featureFlag.tags}
saving={featureFlagLoading}
staticOnly
className="insight-metadata-tags"
className="mt-2"
/>
) : null}
</>
8 changes: 0 additions & 8 deletions frontend/src/scenes/insights/Insight.scss
Original file line number Diff line number Diff line change
@@ -10,11 +10,3 @@
}
}
}

.insight-metadata-tags {
margin-top: 0.75rem;

.ant-tag {
margin-top: 0;
}
}
4 changes: 2 additions & 2 deletions frontend/src/scenes/insights/InsightPageHeader.tsx
Original file line number Diff line number Diff line change
@@ -345,14 +345,14 @@ export function InsightPageHeader({ insightLogicProps }: { insightLogicProps: In
saving={insightSaving}
onChange={(_, tags) => setInsightMetadata({ tags: tags ?? [] })}
tagsAvailable={tags}
className="insight-metadata-tags"
className="mt-2"
data-attr="insight-tags"
/>
) : insight.tags?.length ? (
<ObjectTags
tags={insight.tags}
saving={insightSaving}
className="insight-metadata-tags"
className="mt-2"
data-attr="insight-tags"
staticOnly
/>

0 comments on commit f9a0945

Please sign in to comment.