Fix missing icons and subtitle in mobile boost/quote menu (#36038)
This commit is contained in:
parent
65b4a0a6f1
commit
a5fbe2f5c1
11 changed files with 498 additions and 470 deletions
16
app/javascript/mastodon/utils/types.ts
Normal file
16
app/javascript/mastodon/utils/types.ts
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
/**
|
||||
* Extend an existing type and make some of its properties required or optional.
|
||||
* @example
|
||||
* interface Person {
|
||||
* name: string;
|
||||
* age?: number;
|
||||
* likesIceCream?: boolean;
|
||||
* }
|
||||
*
|
||||
* type PersonWithSomeRequired = SomeRequired<Person, 'age' | 'likesIceCream' >;
|
||||
* type PersonWithSomeOptional = SomeOptional<Person, 'name' >;
|
||||
*/
|
||||
|
||||
export type SomeRequired<T, K extends keyof T> = T & Required<Pick<T, K>>;
|
||||
export type SomeOptional<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>> &
|
||||
Partial<Pick<T, K>>;
|
||||
Loading…
Add table
Add a link
Reference in a new issue