0
0
Fork 0

Change design of lists in web UI (#32881)

This commit is contained in:
Eugen Rochko 2024-11-21 17:10:04 +01:00 committed by GitHub
parent 7385016837
commit 62603508c7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
39 changed files with 1395 additions and 1350 deletions

View file

@ -0,0 +1,18 @@
import type { RecordOf } from 'immutable';
import { Record } from 'immutable';
import type { ApiListJSON } from 'mastodon/api_types/lists';
type ListShape = Required<ApiListJSON>; // no changes from server shape
export type List = RecordOf<ListShape>;
const ListFactory = Record<ListShape>({
id: '',
title: '',
exclusive: false,
replies_policy: 'list',
});
export function createList(attributes: Partial<ListShape>) {
return ListFactory(attributes);
}