@dressed/react 1.0.0-rc.3.1 → 1.1.0

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/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import type { ReactNode } from "react";
2
- import { type APIInteractionResponseCallbackData } from "discord-api-types/v10";
2
+ import { type APIInteractionResponseCallbackData, type APIModalInteractionResponseCallbackData } from "discord-api-types/v10";
3
3
  import type { createInteraction, RawFile } from "dressed/server";
4
4
  type ReplyProps = [
5
5
  components: ReactNode,
@@ -28,11 +28,16 @@ type FollowUpProps = [
28
28
  ephemeral?: boolean;
29
29
  }
30
30
  ];
31
+ type ShowModalProps = [
32
+ components: ReactNode,
33
+ data?: Omit<APIModalInteractionResponseCallbackData, "components">
34
+ ];
31
35
  type ReactivatedInteraction<T extends NonNullable<ReturnType<typeof createInteraction>>> = OverrideMethodParams<T, {
32
36
  reply: ReplyProps;
33
37
  editReply: EditReplyProps;
34
38
  update: EditReplyProps;
35
39
  followUp: FollowUpProps;
40
+ showModal: ShowModalProps;
36
41
  }>;
37
42
  type OverrideMethodParams<T, Overrides extends Record<string, unknown[]>> = {
38
43
  [K in keyof T]: K extends keyof Overrides ? T[K] extends (...args: any) => any ? (...args: Overrides[K]) => ReturnType<T[K]> : T[K] : T[K];
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EACL,YAAY,GAEb,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AACrD,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAoDnD,MAAM,CAAC,KAAK,UAAU,MAAM,CAAC,SAAoB;IAC/C,MAAM,SAAS,GAAG,cAAc,EAAE,CAAC;IACnC,MAAM,IAAI,GAAG,UAAU,CAAC,eAAe,CACrC,SAAS,EACT,CAAC,E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EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAC3E,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AACtD,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dressed/react",
3
- "version": "1.0.0-rc.3.1",
3
+ "version": "1.1.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/Inbestigator/dressed.git",
@@ -13,7 +13,6 @@
13
13
  "exports": "./dist/index.js",
14
14
  "description": "Render Dressed's components using React",
15
15
  "files": [
16
- "patches",
17
16
  "dist"
18
17
  ],
19
18
  "homepage": "https://dressed.vercel.app",
@@ -27,18 +26,16 @@
27
26
  "scripts": {
28
27
  "dist": "rm -fr dist && tsc",
29
28
  "check-types": "tsc --noEmit",
30
- "dry-publish": "bun publish --dry-run",
31
- "postinstall": "patch-package"
29
+ "dry-publish": "bun publish --dry-run"
32
30
  },
33
31
  "type": "module",
34
32
  "types": "./dist/index.d.ts",
35
33
  "dependencies": {
36
- "discord-api-types": "^0.38.10",
37
- "patch-package": "^8.0.0",
38
- "react-reconciler": "^0.32.0"
34
+ "discord-api-types": "^0.38.11",
35
+ "react-reconciler": "github:inbestigator/dressed-rr"
39
36
  },
40
37
  "devDependencies": {
41
- "@types/react": "^19.1.6",
38
+ "@types/react": "^19.1.8",
42
39
  "@types/react-reconciler": "^0.32.0"
43
40
  }
44
41
  }
@@ -1,45 +0,0 @@
1
- diff --git a/node_modules/react-reconciler/cjs/react-reconciler.development.js b/node_modules/react-reconciler/cjs/react-reconciler.development.js
2
- index b6ce230..479433e 100644
3
- --- a/node_modules/react-reconciler/cjs/react-reconciler.development.js
4
- +++ b/node_modules/react-reconciler/cjs/react-reconciler.development.js
5
- @@ -14280,7 +14280,20 @@
6
- REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"),
7
- isArrayImpl = Array.isArray,
8
- ReactSharedInternals =
9
- - React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
10
- + React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE ?? {
11
- + H: null,
12
- + A: null,
13
- + T: null,
14
- + S: null,
15
- + V: null,
16
- + actQueue: null,
17
- + isBatchingLegacy: false,
18
- + didScheduleLegacyUpdate: false,
19
- + didUsePromise: false,
20
- + thrownErrors: [],
21
- + getCurrentStack: null,
22
- + recentlyCreatedOwnerStacks: 0,
23
- + },
24
- rendererVersion = $$$config.rendererVersion,
25
- rendererPackageName = $$$config.rendererPackageName,
26
- extraDevToolsConfig = $$$config.extraDevToolsConfig,
27
- diff --git a/node_modules/react-reconciler/cjs/react-reconciler.production.js b/node_modules/react-reconciler/cjs/react-reconciler.production.js
28
- index 5877989..4d56c34 100644
29
- --- a/node_modules/react-reconciler/cjs/react-reconciler.production.js
30
- +++ b/node_modules/react-reconciler/cjs/react-reconciler.production.js
31
- @@ -9891,7 +9891,13 @@ module.exports = function ($$$config) {
32
- REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"),
33
- isArrayImpl = Array.isArray,
34
- ReactSharedInternals =
35
- - React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
36
- + React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE ?? {
37
- + H: null,
38
- + A: null,
39
- + T: null,
40
- + S: null,
41
- + V: null,
42
- + },
43
- rendererVersion = $$$config.rendererVersion,
44
- rendererPackageName = $$$config.rendererPackageName,
45
- extraDevToolsConfig = $$$config.extraDevToolsConfig,