@dressed/react 1.8.5-canary.1 → 1.8.5-rc.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/action-row.d.ts +2 -4
- package/dist/components/action-row.js.map +1 -1
- package/dist/components/button.d.ts +4 -4
- package/dist/components/button.js +3 -3
- package/dist/components/button.js.map +1 -1
- package/dist/components/checkbox.d.ts +7 -0
- package/dist/components/checkbox.js +14 -0
- package/dist/components/checkbox.js.map +1 -0
- package/dist/components/container.d.ts +2 -6
- package/dist/components/container.js.map +1 -1
- package/dist/components/file-upload.d.ts +1 -1
- package/dist/components/file-upload.js +3 -3
- package/dist/components/file-upload.js.map +1 -1
- package/dist/components/label.d.ts +2 -6
- package/dist/components/label.js.map +1 -1
- package/dist/components/media-gallery.d.ts +2 -5
- package/dist/components/media-gallery.js.map +1 -1
- package/dist/components/radio-group.d.ts +6 -0
- package/dist/components/radio-group.js +14 -0
- package/dist/components/radio-group.js.map +1 -0
- package/dist/components/section.d.ts +2 -3
- package/dist/components/section.js.map +1 -1
- package/dist/components/select-menu.d.ts +5 -7
- package/dist/components/select-menu.js +7 -7
- package/dist/components/select-menu.js.map +1 -1
- package/dist/components/separator.d.ts +1 -1
- package/dist/components/separator.js +3 -3
- package/dist/components/separator.js.map +1 -1
- package/dist/components/text-display.d.ts +2 -6
- package/dist/components/text-display.js.map +1 -1
- package/dist/components/text-input.d.ts +1 -1
- package/dist/components/text-input.js +3 -3
- package/dist/components/text-input.js.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -1
- package/dist/react/renderer.js +16 -18
- package/dist/react/renderer.js.map +1 -1
- package/dist/rendering/interaction.d.ts +1 -1
- package/dist/rendering/message.d.ts +2 -2
- package/dist/rendering/message.js.map +1 -1
- package/package.json +4 -4
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import type { APIActionRowComponent, APIComponentInActionRow } from "discord-api-types/v10";
|
|
2
|
-
import { type
|
|
2
|
+
import { type PropsWithChildren, type ReactElement } from "react";
|
|
3
3
|
import { type ComponentNode } from "../react/renderer.ts";
|
|
4
|
-
export declare function ActionRow({ children, }:
|
|
5
|
-
children: ReactNode;
|
|
6
|
-
}): ReactElement<APIActionRowComponent<APIComponentInActionRow>>;
|
|
4
|
+
export declare function ActionRow({ children, }: PropsWithChildren): ReactElement<APIActionRowComponent<APIComponentInActionRow>>;
|
|
7
5
|
export declare function parseActionRow<T extends APIActionRowComponent<APIComponentInActionRow>>(props: T, children: ComponentNode[]): Promise<T>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"action-row.js","sourceRoot":"","sources":["../../src/components/action-row.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACxD,OAAO,EAAE,aAAa,
|
|
1
|
+
{"version":3,"file":"action-row.js","sourceRoot":"","sources":["../../src/components/action-row.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACxD,OAAO,EAAE,aAAa,EAA6C,MAAM,OAAO,CAAC;AACjF,OAAO,EAAsB,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAErE,MAAM,UAAU,SAAS,CAAC,EACxB,QAAQ,GACU;IAClB,MAAM,KAAK,GAAG,gBAAgB,EAAE,CAAC;IACjC,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC;AACxD,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,cAAc,CAClC,KAAQ,EACR,QAAyB;IAEzB,OAAO,EAAE,GAAG,KAAK,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,EAAE,CAAC;AAC9E,CAAC"}
|
|
@@ -13,9 +13,9 @@ interface ButtonWithOnClick extends Omit<ButtonWithCustomId, "custom_id"> {
|
|
|
13
13
|
/** An additional handler identity defined in the callback setup which will run if the `onClick` is no longer registered */
|
|
14
14
|
fallback?: string;
|
|
15
15
|
}
|
|
16
|
-
export declare function Button(
|
|
17
|
-
export declare function Button(
|
|
18
|
-
export declare function Button(
|
|
19
|
-
export declare function Button(
|
|
16
|
+
export declare function Button(config: ButtonWithCustomId): ReactElement<APIButtonComponentWithCustomId>;
|
|
17
|
+
export declare function Button(config: ButtonWithOnClick): ReactElement<APIButtonComponentWithCustomId>;
|
|
18
|
+
export declare function Button(config: Omit<APIButtonComponentWithSKUId, "type" | "style">): ReactElement<APIButtonComponentWithSKUId>;
|
|
19
|
+
export declare function Button(config: Omit<APIButtonComponentWithURL, "type" | "style">): ReactElement<APIButtonComponentWithURL>;
|
|
20
20
|
export declare function parseButton<T extends APIButtonComponent & (Pick<ButtonWithOnClick, "onClick" | "fallback"> | object)>(nodeId: string, props: T): Promise<T>;
|
|
21
21
|
export {};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Button as DressedComponent } from "dressed";
|
|
2
2
|
import { createElement } from "react";
|
|
3
3
|
import { registerHandler } from "../rendering/callbacks.js";
|
|
4
|
-
export function Button(
|
|
5
|
-
const
|
|
6
|
-
return createElement("dressed-node",
|
|
4
|
+
export function Button(config) {
|
|
5
|
+
const props = DressedComponent(config);
|
|
6
|
+
return createElement("dressed-node", props);
|
|
7
7
|
}
|
|
8
8
|
export async function parseButton(nodeId, props) {
|
|
9
9
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button.js","sourceRoot":"","sources":["../../src/components/button.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,MAAM,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACrD,OAAO,EAAE,aAAa,EAAqB,MAAM,OAAO,CAAC;AACzD,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AA0B5D,MAAM,UAAU,MAAM,CACpB,
|
|
1
|
+
{"version":3,"file":"button.js","sourceRoot":"","sources":["../../src/components/button.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,MAAM,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACrD,OAAO,EAAE,aAAa,EAAqB,MAAM,OAAO,CAAC;AACzD,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AA0B5D,MAAM,UAAU,MAAM,CACpB,MAIqD;IAErD,MAAM,KAAK,GAAG,gBAAgB,CAAC,MAAe,CAAC,CAAC;IAChD,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;AAC9C,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,WAAW,CAE/B,MAAc,EAAE,KAAQ;IACxB,OAAO;QACL,GAAG,KAAK;QACR,GAAG,CAAC,SAAS,IAAI,KAAK,CAAC,CAAC,CAAC,eAAe,CAAC,MAAM,EAAE,KAAK,CAAC,OAAgB,EAAE,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;KACtG,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { APICheckboxComponent, APICheckboxGroupComponent, APICheckboxGroupOption } from "discord-api-types/v10";
|
|
2
|
+
import { type PropsWithChildren, type ReactElement } from "react";
|
|
3
|
+
import type { ComponentNode } from "../react/renderer.ts";
|
|
4
|
+
export declare function Checkbox(config: Omit<APICheckboxComponent, "type">): ReactElement<APICheckboxComponent>;
|
|
5
|
+
export declare function Checkbox(config: APICheckboxGroupOption): ReactElement<APICheckboxGroupOption>;
|
|
6
|
+
export declare function CheckboxGroup({ children, ...rest }: PropsWithChildren<Omit<APICheckboxGroupComponent, "options" | "type">>): ReactElement<APICheckboxGroupComponent>;
|
|
7
|
+
export declare function parseCheckboxGroup<T extends APICheckboxGroupComponent>(props: T, children: ComponentNode[]): Promise<T>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Checkbox as DressedComponent, CheckboxGroup as DressedGroupComponent } from "dressed";
|
|
2
|
+
import { createElement } from "react";
|
|
3
|
+
export function Checkbox(config) {
|
|
4
|
+
const props = "label" in config ? DressedComponent(config.label, config.value, config) : DressedComponent(config);
|
|
5
|
+
return createElement("dressed-node", props);
|
|
6
|
+
}
|
|
7
|
+
export function CheckboxGroup({ children, ...rest }) {
|
|
8
|
+
const props = DressedGroupComponent(rest);
|
|
9
|
+
return createElement("dressed-node", props, children);
|
|
10
|
+
}
|
|
11
|
+
export async function parseCheckboxGroup(props, children) {
|
|
12
|
+
return { ...props, options: children.map((c) => c.props) };
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=checkbox.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"checkbox.js","sourceRoot":"","sources":["../../src/components/checkbox.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,IAAI,gBAAgB,EAAE,aAAa,IAAI,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAC/F,OAAO,EAAE,aAAa,EAA6C,MAAM,OAAO,CAAC;AAOjF,MAAM,UAAU,QAAQ,CACtB,MAAmE;IAEnE,MAAM,KAAK,GAAG,OAAO,IAAI,MAAM,CAAC,CAAC,CAAC,gBAAgB,CAAC,MAAM,CAAC,KAAK,EAAE,MAAM,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,gBAAgB,CAAC,MAAM,CAAC,CAAC;IAClH,OAAO,aAAa,CAAC,cAAc,EAAE,KAAc,CAAC,CAAC;AACvD,CAAC;AAED,MAAM,UAAU,aAAa,CAAC,EAC5B,QAAQ,EACR,GAAG,IAAI,EACgE;IACvE,MAAM,KAAK,GAAG,qBAAqB,CAAC,IAAa,CAAC,CAAC;IACnD,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC;AACxD,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,kBAAkB,CACtC,KAAQ,EACR,QAAyB;IAEzB,OAAO,EAAE,GAAG,KAAK,EAAE,OAAO,EAAE,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,EAAE,CAAC;AAC7D,CAAC"}
|
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
import type { APIContainerComponent } from "discord-api-types/v10";
|
|
2
|
-
import { type
|
|
2
|
+
import { type PropsWithChildren, type ReactElement } from "react";
|
|
3
3
|
import { type ComponentNode } from "../react/renderer.ts";
|
|
4
|
-
|
|
5
|
-
children: ReactNode;
|
|
6
|
-
}
|
|
7
|
-
export declare function Container({ children, ...rest }: ContainerProps): ReactElement<APIContainerComponent>;
|
|
4
|
+
export declare function Container({ children, ...rest }: PropsWithChildren<Omit<APIContainerComponent, "components" | "type">>): ReactElement<APIContainerComponent>;
|
|
8
5
|
export declare function parseContainer<T extends APIContainerComponent>(props: T, children: ComponentNode[]): Promise<T>;
|
|
9
|
-
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"container.js","sourceRoot":"","sources":["../../src/components/container.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACxD,OAAO,EAAE,aAAa,
|
|
1
|
+
{"version":3,"file":"container.js","sourceRoot":"","sources":["../../src/components/container.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACxD,OAAO,EAAE,aAAa,EAA6C,MAAM,OAAO,CAAC;AACjF,OAAO,EAAsB,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAErE,MAAM,UAAU,SAAS,CAAC,EACxB,QAAQ,EACR,GAAG,IAAI,EAC+D;IACtE,MAAM,KAAK,GAAG,gBAAgB,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC;IACzC,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC;AACxD,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,cAAc,CAAkC,KAAQ,EAAE,QAAyB;IACvG,OAAO,EAAE,GAAG,KAAK,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,EAAE,CAAC;AAC9E,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { APIFileUploadComponent } from "discord-api-types/v10";
|
|
2
2
|
import { type ReactElement } from "react";
|
|
3
|
-
export declare function FileUpload(
|
|
3
|
+
export declare function FileUpload(config: Omit<APIFileUploadComponent, "type">): ReactElement<APIFileUploadComponent>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { FileUpload as DressedComponent } from "dressed";
|
|
2
2
|
import { createElement } from "react";
|
|
3
|
-
export function FileUpload(
|
|
4
|
-
const
|
|
5
|
-
return createElement("dressed-node",
|
|
3
|
+
export function FileUpload(config) {
|
|
4
|
+
const props = DressedComponent(config);
|
|
5
|
+
return createElement("dressed-node", props);
|
|
6
6
|
}
|
|
7
7
|
//# sourceMappingURL=file-upload.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"file-upload.js","sourceRoot":"","sources":["../../src/components/file-upload.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACzD,OAAO,EAAE,aAAa,EAAqB,MAAM,OAAO,CAAC;AAEzD,MAAM,UAAU,UAAU,CAAC,
|
|
1
|
+
{"version":3,"file":"file-upload.js","sourceRoot":"","sources":["../../src/components/file-upload.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACzD,OAAO,EAAE,aAAa,EAAqB,MAAM,OAAO,CAAC;AAEzD,MAAM,UAAU,UAAU,CAAC,MAA4C;IACrE,MAAM,KAAK,GAAG,gBAAgB,CAAC,MAAM,CAAC,CAAC;IACvC,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;AAC9C,CAAC"}
|
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
import type { APILabelComponent } from "discord-api-types/v10";
|
|
2
|
-
import { type
|
|
2
|
+
import { type PropsWithChildren, type ReactElement } from "react";
|
|
3
3
|
import { type ComponentNode } from "../react/renderer.ts";
|
|
4
|
-
|
|
5
|
-
children: ReactNode;
|
|
6
|
-
}
|
|
7
|
-
export declare function Label({ label, description, children, ...rest }: LabelProps): ReactElement<APILabelComponent>;
|
|
4
|
+
export declare function Label({ label, description, children, ...rest }: PropsWithChildren<Omit<APILabelComponent, "component" | "type">>): ReactElement<APILabelComponent>;
|
|
8
5
|
export declare function parseLabel<T extends APILabelComponent>(props: T, children: ComponentNode[]): Promise<T>;
|
|
9
|
-
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"label.js","sourceRoot":"","sources":["../../src/components/label.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACpD,OAAO,EAAE,aAAa,
|
|
1
|
+
{"version":3,"file":"label.js","sourceRoot":"","sources":["../../src/components/label.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACpD,OAAO,EAAE,aAAa,EAA6C,MAAM,OAAO,CAAC;AACjF,OAAO,EAAsB,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAErE,MAAM,UAAU,KAAK,CAAC,EACpB,KAAK,EACL,WAAW,EACX,QAAQ,EACR,GAAG,IAAI,EAC0D;IACjE,MAAM,KAAK,GAAG,gBAAgB,CAAC,KAAK,EAAE,IAAa,EAAE,WAAW,EAAE,IAAI,CAAC,CAAC;IACxE,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC;AACxD,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,UAAU,CAA8B,KAAQ,EAAE,QAAyB;IAC/F,OAAO;QACL,GAAG,KAAK;QACR,SAAS,EAAE,CAAC,MAAM,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;KAC3D,CAAC;AACJ,CAAC"}
|
|
@@ -1,10 +1,7 @@
|
|
|
1
1
|
import type { APIMediaGalleryComponent, APIMediaGalleryItem } from "discord-api-types/v10";
|
|
2
|
-
import { type
|
|
2
|
+
import { type PropsWithChildren } from "react";
|
|
3
3
|
import type { Node } from "../react/node.ts";
|
|
4
|
-
|
|
5
|
-
children: ReactNode;
|
|
6
|
-
}
|
|
7
|
-
export declare function MediaGallery({ children, ...rest }: MediaGalleryProps): import("react").ReactElement<APIMediaGalleryComponent, string | import("react").JSXElementConstructor<any>>;
|
|
4
|
+
export declare function MediaGallery({ children, ...rest }: PropsWithChildren<Omit<APIMediaGalleryComponent, "items" | "type">>): import("react").ReactElement<APIMediaGalleryComponent, string | import("react").JSXElementConstructor<any>>;
|
|
8
5
|
interface ItemProps extends Omit<APIMediaGalleryItem, "media" | "type"> {
|
|
9
6
|
media: APIMediaGalleryItem["media"] | string;
|
|
10
7
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"media-gallery.js","sourceRoot":"","sources":["../../src/components/media-gallery.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,IAAI,gBAAgB,EAAE,gBAAgB,IAAI,WAAW,EAAE,MAAM,SAAS,CAAC;AAC5F,OAAO,EAAE,aAAa,
|
|
1
|
+
{"version":3,"file":"media-gallery.js","sourceRoot":"","sources":["../../src/components/media-gallery.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,IAAI,gBAAgB,EAAE,gBAAgB,IAAI,WAAW,EAAE,MAAM,SAAS,CAAC;AAC5F,OAAO,EAAE,aAAa,EAA0B,MAAM,OAAO,CAAC;AAG9D,MAAM,UAAU,YAAY,CAAC,EAC3B,QAAQ,EACR,GAAG,IAAI,EAC6D;IACpE,MAAM,KAAK,GAAG,gBAAgB,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC;IACzC,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC;AACxD,CAAC;AAMD,MAAM,UAAU,gBAAgB,CAAC,EAAE,KAAK,EAAE,GAAG,IAAI,EAAa;IAC5D,MAAM,KAAK,GAAG,WAAW,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;IACvC,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;AAC9C,CAAC;AAED,MAAM,UAAU,iBAAiB,CAC/B,KAAQ,EACR,QAAqC;IAErC,OAAO,EAAE,GAAG,KAAK,EAAE,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,EAAE,CAAC;AAC3D,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { APIRadioGroupComponent, APIRadioGroupOption } from "discord-api-types/v10";
|
|
2
|
+
import { type PropsWithChildren, type ReactElement } from "react";
|
|
3
|
+
import type { ComponentNode } from "../react/renderer.ts";
|
|
4
|
+
export declare function RadioGroup({ children, ...rest }: PropsWithChildren<Omit<APIRadioGroupComponent, "options" | "type">>): ReactElement<APIRadioGroupComponent>;
|
|
5
|
+
export declare function RadioGroupOption({ label, value, ...rest }: APIRadioGroupOption): ReactElement<APIRadioGroupOption>;
|
|
6
|
+
export declare function parseRadioGroup<T extends APIRadioGroupComponent>(props: T, children: ComponentNode[]): Promise<T>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { RadioGroup as DressedComponent, RadioGroupOption as DressedOption } from "dressed";
|
|
2
|
+
import { createElement } from "react";
|
|
3
|
+
export function RadioGroup({ children, ...rest }) {
|
|
4
|
+
const props = DressedComponent(rest);
|
|
5
|
+
return createElement("dressed-node", props, children);
|
|
6
|
+
}
|
|
7
|
+
export function RadioGroupOption({ label, value, ...rest }) {
|
|
8
|
+
const props = DressedOption(label, value, rest);
|
|
9
|
+
return createElement("dressed-node", props);
|
|
10
|
+
}
|
|
11
|
+
export async function parseRadioGroup(props, children) {
|
|
12
|
+
return { ...props, options: children.map((c) => c.props) };
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=radio-group.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"radio-group.js","sourceRoot":"","sources":["../../src/components/radio-group.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,IAAI,gBAAgB,EAAE,gBAAgB,IAAI,aAAa,EAAE,MAAM,SAAS,CAAC;AAC5F,OAAO,EAAE,aAAa,EAA6C,MAAM,OAAO,CAAC;AAGjF,MAAM,UAAU,UAAU,CAAC,EACzB,QAAQ,EACR,GAAG,IAAI,EAC6D;IACpE,MAAM,KAAK,GAAG,gBAAgB,CAAC,IAAa,CAAC,CAAC;IAC9C,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC;AACxD,CAAC;AAED,MAAM,UAAU,gBAAgB,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,GAAG,IAAI,EAAuB;IAC7E,MAAM,KAAK,GAAG,aAAa,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,CAAC,CAAC;IAChD,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;AAC9C,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,eAAe,CACnC,KAAQ,EACR,QAAyB;IAEzB,OAAO,EAAE,GAAG,KAAK,EAAE,OAAO,EAAE,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,EAAE,CAAC;AAC7D,CAAC"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import type { APISectionComponent } from "discord-api-types/v10";
|
|
2
|
-
import { type ReactElement, type ReactNode } from "react";
|
|
2
|
+
import { type PropsWithChildren, type ReactElement, type ReactNode } from "react";
|
|
3
3
|
import { type ComponentNode } from "../react/renderer.ts";
|
|
4
4
|
interface SectionProps extends Omit<APISectionComponent, "accessory" | "components" | "type"> {
|
|
5
|
-
children: ReactNode;
|
|
6
5
|
accessory: ReactNode;
|
|
7
6
|
}
|
|
8
|
-
export declare function Section({ children, accessory, ...rest }: SectionProps): ReactElement<APISectionComponent>;
|
|
7
|
+
export declare function Section({ children, accessory, ...rest }: PropsWithChildren<SectionProps>): ReactElement<APISectionComponent>;
|
|
9
8
|
export declare function parseSection<T extends APISectionComponent>(props: T, children: ComponentNode[]): Promise<T>;
|
|
10
9
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"section.js","sourceRoot":"","sources":["../../src/components/section.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACtD,OAAO,EAAE,aAAa,
|
|
1
|
+
{"version":3,"file":"section.js","sourceRoot":"","sources":["../../src/components/section.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACtD,OAAO,EAAE,aAAa,EAA6D,MAAM,OAAO,CAAC;AACjG,OAAO,EAAsB,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAMrE,MAAM,UAAU,OAAO,CAAC,EACtB,QAAQ,EACR,SAAS,EACT,GAAG,IAAI,EACyB;IAChC,MAAM,KAAK,GAAG,gBAAgB,CAAC,EAAE,EAAE,IAAa,EAAE,IAAI,CAAC,CAAC;IACxD,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,EAAE,SAAS,EAAE,QAAQ,CAAC,CAAC;AACnE,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,YAAY,CAAgC,KAAQ,EAAE,QAAyB;IACnG,MAAM,CAAC,SAAS,EAAE,GAAG,UAAU,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,CAAC;IAC9E,OAAO,EAAE,GAAG,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,CAAC;AAC7C,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type APISelectMenuComponent, type APISelectMenuOption, ComponentType } from "discord-api-types/v10";
|
|
2
|
-
import { type
|
|
2
|
+
import { type PropsWithChildren, type ReactElement } from "react";
|
|
3
3
|
import type { Node } from "../react/node.ts";
|
|
4
4
|
import type { MessageComponentInteraction } from "../rendering/interaction.ts";
|
|
5
5
|
type SelectType = "Channel" | "Mentionable" | "Role" | "String" | "User";
|
|
@@ -10,9 +10,7 @@ type SelectMap = {
|
|
|
10
10
|
};
|
|
11
11
|
type SelectMenuWithCustomId<K extends SelectType> = Omit<SelectMap[`${K}Select`], "type" | "options"> & {
|
|
12
12
|
type: K;
|
|
13
|
-
} & (K extends "String" ?
|
|
14
|
-
children: ReactNode;
|
|
15
|
-
} : object);
|
|
13
|
+
} & (K extends "String" ? PropsWithChildren : object);
|
|
16
14
|
type SelectMenuWithOnClick<K extends SelectType> = Omit<SelectMenuWithCustomId<K>, "custom_id"> & {
|
|
17
15
|
/**
|
|
18
16
|
* Create a temporary handler callback, will not work in a serverless environment
|
|
@@ -22,12 +20,12 @@ type SelectMenuWithOnClick<K extends SelectType> = Omit<SelectMenuWithCustomId<K
|
|
|
22
20
|
/** An additional handler identity defined in the callback setup which will run if the `onSubmit` is no longer registered */
|
|
23
21
|
fallback?: string;
|
|
24
22
|
};
|
|
25
|
-
export declare function SelectMenu<K extends SelectType>(
|
|
23
|
+
export declare function SelectMenu<K extends SelectType>(config: SelectMenuWithCustomId<K> & {
|
|
26
24
|
type: K;
|
|
27
25
|
}): ReactElement<SelectMap[`${K}Select`]>;
|
|
28
|
-
export declare function SelectMenu<K extends SelectType>(
|
|
26
|
+
export declare function SelectMenu<K extends SelectType>(config: SelectMenuWithOnClick<K> & {
|
|
29
27
|
type: K;
|
|
30
28
|
}): ReactElement<SelectMap[`${K}Select`]>;
|
|
31
|
-
export declare function SelectMenuOption(
|
|
29
|
+
export declare function SelectMenuOption({ label, value, ...rest }: APISelectMenuOption): ReactElement<APISelectMenuOption>;
|
|
32
30
|
export declare function parseSelectMenu<T extends APISelectMenuComponent & (Pick<SelectMenuWithOnClick<SelectType>, "onSubmit" | "fallback"> | object)>(nodeId: string, props: T, children: Node<APISelectMenuOption>[]): T;
|
|
33
31
|
export {};
|
|
@@ -2,14 +2,14 @@ import { ComponentType } from "discord-api-types/v10";
|
|
|
2
2
|
import { SelectMenu as DressedComponent, SelectMenuOption as DressedOption } from "dressed";
|
|
3
3
|
import { createElement } from "react";
|
|
4
4
|
import { registerHandler } from "../rendering/callbacks.js";
|
|
5
|
-
export function SelectMenu(
|
|
6
|
-
const { children, ...rest } =
|
|
7
|
-
const
|
|
8
|
-
return createElement("dressed-node",
|
|
5
|
+
export function SelectMenu(config) {
|
|
6
|
+
const { children, ...rest } = config;
|
|
7
|
+
const props = DressedComponent(rest);
|
|
8
|
+
return createElement("dressed-node", props, children);
|
|
9
9
|
}
|
|
10
|
-
export function SelectMenuOption(
|
|
11
|
-
const
|
|
12
|
-
return createElement("dressed-node",
|
|
10
|
+
export function SelectMenuOption({ label, value, ...rest }) {
|
|
11
|
+
const props = DressedOption(label, value, rest);
|
|
12
|
+
return createElement("dressed-node", props);
|
|
13
13
|
}
|
|
14
14
|
export function parseSelectMenu(nodeId, props, children) {
|
|
15
15
|
if (props.type === ComponentType.StringSelect) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"select-menu.js","sourceRoot":"","sources":["../../src/components/select-menu.ts"],"names":[],"mappings":"AAAA,OAAO,EAAyD,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAC7G,OAAO,EAAE,UAAU,IAAI,gBAAgB,EAAE,gBAAgB,IAAI,aAAa,EAAE,MAAM,SAAS,CAAC;AAC5F,OAAO,EAAE,aAAa,
|
|
1
|
+
{"version":3,"file":"select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ACJ,CAAC"}
|
|
@@ -3,5 +3,5 @@ import { type ReactElement } from "react";
|
|
|
3
3
|
interface SeparatorProps extends Omit<APISeparatorComponent, "type" | "spacing"> {
|
|
4
4
|
spacing?: keyof typeof SeparatorSpacingSize;
|
|
5
5
|
}
|
|
6
|
-
export declare function Separator(
|
|
6
|
+
export declare function Separator(config: SeparatorProps): ReactElement<APISeparatorComponent>;
|
|
7
7
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Separator as DressedComponent } from "dressed";
|
|
2
2
|
import { createElement } from "react";
|
|
3
|
-
export function Separator(
|
|
4
|
-
const
|
|
5
|
-
return createElement("dressed-node",
|
|
3
|
+
export function Separator(config) {
|
|
4
|
+
const props = DressedComponent(config);
|
|
5
|
+
return createElement("dressed-node", props);
|
|
6
6
|
}
|
|
7
7
|
//# sourceMappingURL=separator.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"separator.js","sourceRoot":"","sources":["../../src/components/separator.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACxD,OAAO,EAAE,aAAa,EAAqB,MAAM,OAAO,CAAC;AAMzD,MAAM,UAAU,SAAS,CAAC,
|
|
1
|
+
{"version":3,"file":"separator.js","sourceRoot":"","sources":["../../src/components/separator.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACxD,OAAO,EAAE,aAAa,EAAqB,MAAM,OAAO,CAAC;AAMzD,MAAM,UAAU,SAAS,CAAC,MAAsB;IAC9C,MAAM,KAAK,GAAG,gBAAgB,CAAC,MAAM,CAAC,CAAC;IACvC,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;AAC9C,CAAC"}
|
|
@@ -1,8 +1,4 @@
|
|
|
1
1
|
import type { APITextDisplayComponent } from "discord-api-types/v10";
|
|
2
|
-
import { type
|
|
3
|
-
|
|
4
|
-
children: ReactNode;
|
|
5
|
-
}
|
|
6
|
-
export declare function TextDisplay({ children, ...rest }: TextDisplayProps): ReactElement<APITextDisplayComponent>;
|
|
2
|
+
import { type PropsWithChildren, type ReactElement } from "react";
|
|
3
|
+
export declare function TextDisplay({ children, ...rest }: PropsWithChildren<Omit<APITextDisplayComponent, "content" | "type">>): ReactElement<APITextDisplayComponent>;
|
|
7
4
|
export declare function parseTextDisplay<T extends APITextDisplayComponent>(props: T, children: string): T;
|
|
8
|
-
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-display.js","sourceRoot":"","sources":["../../src/components/text-display.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAC1D,OAAO,EAAE,aAAa,
|
|
1
|
+
{"version":3,"file":"text-display.js","sourceRoot":"","sources":["../../src/components/text-display.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAC1D,OAAO,EAAE,aAAa,EAA6C,MAAM,OAAO,CAAC;AAEjF,MAAM,UAAU,WAAW,CAAC,EAC1B,QAAQ,EACR,GAAG,IAAI,EAC8D;IACrE,MAAM,KAAK,GAAG,gBAAgB,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC;IACzC,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC;AACxD,CAAC;AAED,MAAM,UAAU,gBAAgB,CAAoC,KAAQ,EAAE,QAAgB;IAC5F,OAAO,EAAE,GAAG,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC;AACzC,CAAC"}
|
|
@@ -3,5 +3,5 @@ import { type ReactElement } from "react";
|
|
|
3
3
|
interface TextInputProps extends Omit<APITextInputComponent, "type" | "style"> {
|
|
4
4
|
style?: keyof typeof TextInputStyle;
|
|
5
5
|
}
|
|
6
|
-
export declare function TextInput(
|
|
6
|
+
export declare function TextInput(config: TextInputProps): ReactElement<APITextInputComponent>;
|
|
7
7
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { TextInput as DressedComponent } from "dressed";
|
|
2
2
|
import { createElement } from "react";
|
|
3
|
-
export function TextInput(
|
|
4
|
-
const
|
|
5
|
-
return createElement("dressed-node",
|
|
3
|
+
export function TextInput(config) {
|
|
4
|
+
const props = DressedComponent(config);
|
|
5
|
+
return createElement("dressed-node", props);
|
|
6
6
|
}
|
|
7
7
|
//# sourceMappingURL=text-input.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-input.js","sourceRoot":"","sources":["../../src/components/text-input.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACxD,OAAO,EAAE,aAAa,EAAqB,MAAM,OAAO,CAAC;AAMzD,MAAM,UAAU,SAAS,CAAC,
|
|
1
|
+
{"version":3,"file":"text-input.js","sourceRoot":"","sources":["../../src/components/text-input.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,IAAI,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACxD,OAAO,EAAE,aAAa,EAAqB,MAAM,OAAO,CAAC;AAMzD,MAAM,UAAU,SAAS,CAAC,MAAsB;IAC9C,MAAM,KAAK,GAAG,gBAAgB,CAAC,MAAM,CAAC,CAAC;IACvC,OAAO,aAAa,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;AAC9C,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
export { ActionRow } from "./components/action-row.ts";
|
|
2
2
|
export { Button } from "./components/button.ts";
|
|
3
|
+
export { Checkbox, CheckboxGroup } from "./components/checkbox.ts";
|
|
3
4
|
export { Container } from "./components/container.ts";
|
|
4
5
|
export { File } from "./components/file.ts";
|
|
5
6
|
export { Label } from "./components/label.ts";
|
|
6
7
|
export { MediaGallery, MediaGalleryItem } from "./components/media-gallery.ts";
|
|
8
|
+
export { RadioGroup, RadioGroupOption } from "./components/radio-group.ts";
|
|
7
9
|
export { Section } from "./components/section.ts";
|
|
8
10
|
export { SelectMenu, SelectMenuOption } from "./components/select-menu.ts";
|
|
9
11
|
export { Separator } from "./components/separator.ts";
|
package/dist/index.js
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
// Components
|
|
2
2
|
export { ActionRow } from "./components/action-row.js";
|
|
3
3
|
export { Button } from "./components/button.js";
|
|
4
|
+
export { Checkbox, CheckboxGroup } from "./components/checkbox.js";
|
|
4
5
|
export { Container } from "./components/container.js";
|
|
5
6
|
export { File } from "./components/file.js";
|
|
6
7
|
export { Label } from "./components/label.js";
|
|
7
8
|
export { MediaGallery, MediaGalleryItem } from "./components/media-gallery.js";
|
|
9
|
+
export { RadioGroup, RadioGroupOption } from "./components/radio-group.js";
|
|
8
10
|
export { Section } from "./components/section.js";
|
|
9
11
|
export { SelectMenu, SelectMenuOption } from "./components/select-menu.js";
|
|
10
12
|
export { Separator } from "./components/separator.js";
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,aAAa;AACb,OAAO,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AACvD,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAChD,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AACtD,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAC5C,OAAO,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAC9C,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAC/E,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAC3E,OAAO,E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rC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,wBAAwB,CAAC"}
|
package/dist/react/renderer.js
CHANGED
|
@@ -3,9 +3,11 @@ import { ComponentType, } from "discord-api-types/v10";
|
|
|
3
3
|
import { TextDisplay } from "dressed";
|
|
4
4
|
import { parseActionRow } from "../components/action-row.js";
|
|
5
5
|
import { parseButton } from "../components/button.js";
|
|
6
|
+
import { parseCheckboxGroup } from "../components/checkbox.js";
|
|
6
7
|
import { parseContainer } from "../components/container.js";
|
|
7
8
|
import { parseLabel } from "../components/label.js";
|
|
8
9
|
import { parseMediaGallery } from "../components/media-gallery.js";
|
|
10
|
+
import { parseRadioGroup } from "../components/radio-group.js";
|
|
9
11
|
import { parseSection } from "../components/section.js";
|
|
10
12
|
import { parseSelectMenu } from "../components/select-menu.js";
|
|
11
13
|
import { parseTextDisplay } from "../components/text-display.js";
|
|
@@ -51,41 +53,37 @@ export function createRenderer(callback) {
|
|
|
51
53
|
}
|
|
52
54
|
export async function parseNode(node) {
|
|
53
55
|
switch (node.props.type) {
|
|
54
|
-
case ComponentType.ActionRow:
|
|
56
|
+
case ComponentType.ActionRow:
|
|
55
57
|
return parseActionRow(node.props, node.children);
|
|
56
|
-
|
|
57
|
-
case ComponentType.Button: {
|
|
58
|
+
case ComponentType.Button:
|
|
58
59
|
return parseButton(node.id, node.props);
|
|
59
|
-
}
|
|
60
60
|
case ComponentType.StringSelect:
|
|
61
61
|
case ComponentType.UserSelect:
|
|
62
62
|
case ComponentType.RoleSelect:
|
|
63
63
|
case ComponentType.MentionableSelect:
|
|
64
|
-
case ComponentType.ChannelSelect:
|
|
64
|
+
case ComponentType.ChannelSelect:
|
|
65
65
|
return parseSelectMenu(node.id, node.props, node.children);
|
|
66
|
-
}
|
|
67
66
|
case ComponentType.TextInput:
|
|
68
67
|
case ComponentType.Thumbnail:
|
|
69
68
|
case ComponentType.File:
|
|
70
69
|
case ComponentType.Separator:
|
|
71
|
-
case ComponentType.FileUpload:
|
|
70
|
+
case ComponentType.FileUpload:
|
|
71
|
+
case ComponentType.Checkbox:
|
|
72
72
|
return node.props;
|
|
73
|
-
|
|
74
|
-
case ComponentType.Section: {
|
|
73
|
+
case ComponentType.Section:
|
|
75
74
|
return parseSection(node.props, node.children);
|
|
76
|
-
|
|
77
|
-
case ComponentType.TextDisplay: {
|
|
75
|
+
case ComponentType.TextDisplay:
|
|
78
76
|
return parseTextDisplay(node.props, node.text());
|
|
79
|
-
|
|
80
|
-
case ComponentType.MediaGallery: {
|
|
77
|
+
case ComponentType.MediaGallery:
|
|
81
78
|
return parseMediaGallery(node.props, node.children);
|
|
82
|
-
|
|
83
|
-
case ComponentType.Container: {
|
|
79
|
+
case ComponentType.Container:
|
|
84
80
|
return parseContainer(node.props, node.children);
|
|
85
|
-
|
|
86
|
-
case ComponentType.Label: {
|
|
81
|
+
case ComponentType.Label:
|
|
87
82
|
return parseLabel(node.props, node.children);
|
|
88
|
-
|
|
83
|
+
case ComponentType.RadioGroup:
|
|
84
|
+
return parseRadioGroup(node.props, node.children);
|
|
85
|
+
case ComponentType.CheckboxGroup:
|
|
86
|
+
return parseCheckboxGroup(node.props, node.children);
|
|
89
87
|
default: {
|
|
90
88
|
if (typeof node.props === "string") {
|
|
91
89
|
return TextDisplay(node.text());
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"renderer.js","sourceRoot":"","sources":["../../src/react/renderer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAKL,aAAa,GACd,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AACtC,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAC7D,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAC5D,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC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,aAAa,CAAC,WAAW;YAC5B,OAAO,gBAAgB,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;QACnD,KAAK,aAAa,CAAC,YAAY;YAC7B,OAAO,iBAAiB,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,QAAuC,CAAC,CAAC;QACrF,KAAK,aAAa,CAAC,SAAS;YAC1B,OAAO,cAAc,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC;QACnD,KAAK,aAAa,CAAC,KAAK;YACtB,OAAO,UAAU,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC;QAC/C,KAAK,aAAa,CAAC,UAAU;YAC3B,OAAO,eAAe,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC;QACpD,KAAK,aAAa,CAAC,aAAa;YAC9B,OAAO,kBAAkB,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC;QACvD,OAAO,CAAC,CAAC,CAAC;YACR,IAAI,OAAO,IAAI,CAAC,KAAK,KAAK,QAAQ,EAAE,CAAC;gBACnC,OAAO,WAAW,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;YAClC,CAAC;YACD,MAAM,IAAI,KAAK,CAAC,cAAc,CAAC,CAAC;QAClC,CAAC;IACH,CAAC;AACH,CAAC"}
|
|
@@ -7,7 +7,7 @@ type ReactivatedInteraction<T> = OverrideMethodParams<T, {
|
|
|
7
7
|
[K in "reply" | "editReply" | "update" | "followUp" | "showModal"]: [
|
|
8
8
|
components: ReactNode,
|
|
9
9
|
...(Parameters<T[K]> extends readonly [...infer P] ? [
|
|
10
|
-
data?: Omit<Exclude<P[0], string>, "content" | "components">,
|
|
10
|
+
data?: Omit<Exclude<P[0], string>, "content" | "components" | "embeds">,
|
|
11
11
|
$req?: P[1] & {
|
|
12
12
|
/**
|
|
13
13
|
* Do not set the contents of your response to `null` after 15 minutes (when Discord deletes the original interaction) in order to conserve resources.
|
|
@@ -17,9 +17,9 @@ export type WithContainer<T> = T & {
|
|
|
17
17
|
* Renders the provided children and posts a message to a guild text or DM channel with the `IsComponentsV2` flag.
|
|
18
18
|
* @example createMessage(channelId, <Button label="Foo" />)
|
|
19
19
|
*/
|
|
20
|
-
export declare function createMessage(channelId: Snowflake, components: ReactNode, data?: Omit<Exclude<Parameters<typeof dressedCreateMessage>[1], string>, "content" | "components">, $req?: CallConfig): Promise<WithContainer<APIMessage>>;
|
|
20
|
+
export declare function createMessage(channelId: Snowflake, components: ReactNode, data?: Omit<Exclude<Parameters<typeof dressedCreateMessage>[1], string>, "content" | "components" | "embeds">, $req?: CallConfig): Promise<WithContainer<APIMessage>>;
|
|
21
21
|
/**
|
|
22
22
|
* Renders the provided children and edits a previously sent message.
|
|
23
23
|
* @example editMessage(channelId, messageId, <Button label="Bar" />)
|
|
24
24
|
*/
|
|
25
|
-
export declare function editMessage(channelId: Snowflake, messageId: Snowflake, components: ReactNode, data?: Omit<Exclude<Parameters<typeof dressedEditMessage>[2], string>, "content" | "components">, $req?: CallConfig): Promise<WithContainer<APIMessage>>;
|
|
25
|
+
export declare function editMessage(channelId: Snowflake, messageId: Snowflake, components: ReactNode, data?: Omit<Exclude<Parameters<typeof dressedEditMessage>[2], string>, "content" | "components" | "embeds">, $req?: CallConfig): Promise<WithContainer<APIMessage>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"message.js","sourceRoot":"","sources":["../../src/rendering/message.ts"],"names":[],"mappings":"AAAA,OAAO,EAAmB,YAAY,EAAkB,MAAM,uBAAuB,CAAC;AACtF,OAAO,EAAE,aAAa,IAAI,oBAAoB,EAAE,WAAW,IAAI,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAInG,OAAO,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAapC;;;GAGG;AACH,MAAM,UAAU,aAAa,CAC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C;YAClE,SAAS,GAAG,OAAO,CAAC,EAAE,CAAC;YACvB,IAAI,WAAW;gBAAE,IAAI,EAAE,CAAC;YACxB,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,OAAO,EAAE,EAAE,UAAU,EAAE,SAAS,EAAE,CAAC,CAAC,CAAC;QAC7D,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,WAAW,CACzB,SAAoB,EACpB,SAAoB,EACpB,UAAqB,EACrB,OAA6G,EAAE,EAC/G,IAAiB;;IAEjB,IAAI,CAAC,KAAK,GAAG,CAAC,MAAA,IAAI,CAAC,KAAK,mCAAI,CAAC,CAAC,GAAG,YAAY,CAAC,cAAc,CAAC;IAE7D,OAAO,IAAI,OAAO,CAA4B,CAAC,OAAO,EAAE,EAAE;QACxD,MAAM,EAAE,SAAS,EAAE,GAAG,MAAM,CAAC,UAAU,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE;YACnD,IAAI,CAAC,CAAC,MAAM,KAAK,CAAC;gBAAE,OAAO;YAC3B,mBAAmB;YACnB,IAAI,CAAC,UAAU,GAAG,CAAC,CAAC;YACpB,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,kBAAkB,CAAC,SAAS,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,EAAE,UAAU,EAAE,SAAS,EAAE,CAAC,CAAC,CAAC;QAChH,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dressed/react",
|
|
3
|
-
"version": "1.8.5-
|
|
3
|
+
"version": "1.8.5-rc.1.1",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/Inbestigator/dressed.git",
|
|
7
7
|
"directory": "packages/dressed-react"
|
|
8
8
|
},
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@types/react": "^19.2.
|
|
10
|
+
"@types/react": "^19.2.14",
|
|
11
11
|
"@types/react-reconciler": "^0.33.0",
|
|
12
|
-
"discord-api-types": "^0.38.
|
|
12
|
+
"discord-api-types": "^0.38.39",
|
|
13
13
|
"react-reconciler": "npm:@dressed/react-reconciler"
|
|
14
14
|
},
|
|
15
15
|
"peerDependencies": {
|
|
16
|
-
"dressed": "^
|
|
16
|
+
"dressed": "^2.0.0-canary.2",
|
|
17
17
|
"react": "^19.2.4"
|
|
18
18
|
},
|
|
19
19
|
"exports": {
|