Skip to content

Commit 95a754c

Browse files
aurellebFredrikMWold
authored andcommitted
fix: install firefox manifest in xdg location as well
1 parent cc878c4 commit 95a754c

2 files changed

Lines changed: 48 additions & 0 deletions

File tree

src/typescript/api/src/api/components/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@ export * from "./action-pannel.js";
55
export * from "./actions.js";
66
export * from "./form.js";
77
export * from "./menu-bar.js";
8+
export * from "./message.js";
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
import type { ReactNode } from "react";
2+
import { Color } from "../color";
3+
import { Icon } from "../icon";
4+
import type { ImageLike } from "../image";
5+
import { List } from "./list";
6+
7+
/**
8+
* A full-page message for states that block the command's regular content.
9+
*
10+
* @category UI Components
11+
* @public
12+
*/
13+
export namespace Message {
14+
export type Status = "info" | "error";
15+
16+
export type Props = {
17+
title: string;
18+
description?: string;
19+
navigationTitle?: string;
20+
status?: Status;
21+
icon?: ImageLike;
22+
actions?: ReactNode;
23+
};
24+
}
25+
26+
export const Message: React.FC<Message.Props> = ({
27+
actions,
28+
icon,
29+
status = "info",
30+
navigationTitle,
31+
...emptyViewProps
32+
}) => {
33+
const defaultIcon: ImageLike = {
34+
source: status === "error" ? Icon.XMarkCircle : Icon.Info01,
35+
tintColor: status === "error" ? Color.Red : Color.PrimaryText,
36+
};
37+
38+
return (
39+
<List navigationTitle={navigationTitle} filtering={false}>
40+
<List.EmptyView
41+
{...emptyViewProps}
42+
icon={icon ?? defaultIcon}
43+
actions={actions}
44+
/>
45+
</List>
46+
);
47+
};

0 commit comments

Comments
 (0)