fix(sidebar): prevent version dropdown clipping
This commit is contained in:
@@ -6,6 +6,8 @@ import { describe, expect, it } from 'vitest'
|
|||||||
|
|
||||||
const componentPath = resolve(dirname(fileURLToPath(import.meta.url)), '../AppSidebar.vue')
|
const componentPath = resolve(dirname(fileURLToPath(import.meta.url)), '../AppSidebar.vue')
|
||||||
const componentSource = readFileSync(componentPath, 'utf8')
|
const componentSource = readFileSync(componentPath, 'utf8')
|
||||||
|
const stylePath = resolve(dirname(fileURLToPath(import.meta.url)), '../../../style.css')
|
||||||
|
const styleSource = readFileSync(stylePath, 'utf8')
|
||||||
|
|
||||||
describe('AppSidebar custom SVG styles', () => {
|
describe('AppSidebar custom SVG styles', () => {
|
||||||
it('does not override uploaded SVG fill or stroke colors', () => {
|
it('does not override uploaded SVG fill or stroke colors', () => {
|
||||||
@@ -16,3 +18,12 @@ describe('AppSidebar custom SVG styles', () => {
|
|||||||
expect(componentSource).not.toContain('fill: none;')
|
expect(componentSource).not.toContain('fill: none;')
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
|
describe('AppSidebar header styles', () => {
|
||||||
|
it('does not clip the version badge dropdown', () => {
|
||||||
|
const sidebarHeaderBlockMatch = styleSource.match(/\.sidebar-header\s*\{[\s\S]*?\n \}/)
|
||||||
|
|
||||||
|
expect(sidebarHeaderBlockMatch).not.toBeNull()
|
||||||
|
expect(sidebarHeaderBlockMatch?.[0]).not.toContain('@apply overflow-hidden;')
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|||||||
@@ -529,7 +529,6 @@
|
|||||||
.sidebar-header {
|
.sidebar-header {
|
||||||
@apply h-16 px-6;
|
@apply h-16 px-6;
|
||||||
@apply flex items-center gap-3;
|
@apply flex items-center gap-3;
|
||||||
@apply overflow-hidden;
|
|
||||||
@apply border-b border-gray-100 dark:border-dark-800;
|
@apply border-b border-gray-100 dark:border-dark-800;
|
||||||
transition:
|
transition:
|
||||||
padding 0.2s ease,
|
padding 0.2s ease,
|
||||||
|
|||||||
Reference in New Issue
Block a user