enhance(client): 投稿フォームをちょっといい感じに (#10442)
* .formラッパーを削除 * fix type of MkPostFormAttaches * 🚀 * 🎨 * 🎨 * 🎨 * 🎨 * specifiedの時は連合なしをdisabledに * ✌️ * set select default * gap: 2px (max-width: 500px) / 4px * wip * ✌️ * 🎨 * fix maxTextLength * 今後表示しない * 🎨 * cache channel * 🎨 * 連合なしにする * use i18n.ts.neverShow * ✌️ * refactor * fix indent * tweak --------- Co-authored-by: syuilo <Syuilotan@yahoo.co.jp>
This commit is contained in:
parent
d739aeee32
commit
6798effbab
16 changed files with 338 additions and 211 deletions
|
@ -2,14 +2,31 @@ import { describe, test, assert, afterEach } from 'vitest';
|
|||
import { render, cleanup, type RenderResult } from '@testing-library/vue';
|
||||
import './init';
|
||||
import type { DriveFile } from 'misskey-js/built/entities';
|
||||
import { components } from '@/components';
|
||||
import { directives } from '@/directives';
|
||||
import MkMediaImage from '@/components/MkMediaImage.vue';
|
||||
|
||||
describe('MkMediaImage', () => {
|
||||
const renderMediaImage = (image: Partial<DriveFile>): RenderResult => {
|
||||
return render(MkMediaImage, {
|
||||
props: { image },
|
||||
global: { directives },
|
||||
props: {
|
||||
image: {
|
||||
id: 'xxxxxxxx',
|
||||
createdAt: (new Date()).toJSON(),
|
||||
isSensitive: false,
|
||||
name: 'example.png',
|
||||
thumbnailUrl: null,
|
||||
url: '',
|
||||
type: 'application/octet-stream',
|
||||
size: 1,
|
||||
md5: '15eca7fba0480996e2245f5185bf39f2',
|
||||
blurhash: null,
|
||||
comment: null,
|
||||
properties: {},
|
||||
...image,
|
||||
} as DriveFile,
|
||||
},
|
||||
global: { directives, components },
|
||||
});
|
||||
};
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@ import { describe, test, assert, afterEach } from 'vitest';
|
|||
import { render, cleanup, type RenderResult } from '@testing-library/vue';
|
||||
import './init';
|
||||
import type { summaly } from 'summaly';
|
||||
import { components } from '@/components';
|
||||
import { directives } from '@/directives';
|
||||
import MkUrlPreview from '@/components/MkUrlPreview.vue';
|
||||
|
||||
|
@ -27,7 +28,7 @@ describe('MkMediaImage', () => {
|
|||
|
||||
const result = render(MkUrlPreview, {
|
||||
props: { url: summary.url },
|
||||
global: { directives },
|
||||
global: { directives, components },
|
||||
});
|
||||
|
||||
await new Promise<void>(resolve => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue