style: 优化剧集阅读吸顶标题
This commit is contained in:
@@ -21,7 +21,6 @@ import {
|
||||
} from '@/features/storyboard/testing/fixtures'
|
||||
import { getStoryboardSession } from '@/features/storyboard/model'
|
||||
import { getOperation } from '@/features/workflows/operations'
|
||||
import { readAllStyles } from '@/testing/styles'
|
||||
import SubjectImagesPage from '@/features/subject-images/SubjectImagesPage.vue'
|
||||
import { formFixture, imageFixture } from '@/features/subject-images/testing/fixtures'
|
||||
import { getImageSession } from '@/features/subject-images/model'
|
||||
@@ -1452,9 +1451,6 @@ describe('工作台页面交互', () => {
|
||||
wrapper = mount(CreateProjectDialog, { attachTo: document.body })
|
||||
button('新建剧本').click()
|
||||
await flushPromises()
|
||||
const title = document.querySelector<HTMLInputElement>('#title')!
|
||||
title.value = ' 记忆当铺 '
|
||||
title.dispatchEvent(new Event('input', { bubbles: true }))
|
||||
const topic = document.querySelector<HTMLTextAreaElement>('#topic')!
|
||||
topic.value = ' 雨夜来信 '
|
||||
topic.dispatchEvent(new Event('input', { bubbles: true }))
|
||||
@@ -1465,7 +1461,6 @@ describe('工作台页面交互', () => {
|
||||
await flushPromises()
|
||||
expect(wrapper.emitted('created')).toEqual([['created']])
|
||||
expect(JSON.parse(fetcher.mock.calls[0]![1]!.body as string)).toEqual({
|
||||
title: '记忆当铺',
|
||||
topic: '雨夜来信',
|
||||
style: '',
|
||||
episodeCount: 6
|
||||
@@ -1504,13 +1499,6 @@ describe('工作台页面交互', () => {
|
||||
expect(provided.refresh).toHaveBeenCalledOnce()
|
||||
})
|
||||
|
||||
it('窄屏隐藏进入拆解,选择器需压过工具栏文字按钮', () => {
|
||||
const css = readAllStyles()
|
||||
expect(css).toMatch(
|
||||
/@media \(max-width: 800px\)[\s\S]*?\.tabs-toolbar-actions \.script-next-link\s*\{[^}]*display:\s*none/
|
||||
)
|
||||
})
|
||||
|
||||
it('切换剧本标签保留阅读容器和位置,执行记录按需展开', async () => {
|
||||
wrapper = mount(CreateDramaPage, {
|
||||
attachTo: document.body,
|
||||
@@ -1518,7 +1506,8 @@ describe('工作台页面交互', () => {
|
||||
})
|
||||
const suffix = wrapper.get('.script-section .n-tabs-nav__suffix')
|
||||
expect(suffix.findAll('button').map(item => item.attributes('aria-label'))).toEqual(['剧本更多操作'])
|
||||
expect(suffix.get('router-link-stub').attributes('to')).toBe(`/projects/${fixture.id}/breakdown`)
|
||||
expect(suffix.find('router-link-stub').exists()).toBe(false)
|
||||
expect(suffix.text()).not.toContain('进入拆解')
|
||||
const reader = wrapper.get<HTMLElement>('.reader-scroll .n-scrollbar-container').element
|
||||
reader.scrollTop = 120
|
||||
expect(wrapper.find('.history-panel').exists()).toBe(false)
|
||||
|
||||
Reference in New Issue
Block a user