@payloadcms/live-preview 3.0.0-beta.16 → 3.0.0-beta.27

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.
@@ -1 +1 @@
1
- {"version":3,"file":"handleMessage.d.ts","sourceRoot":"","sources":["../src/handleMessage.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,aAAa,YAAmB;IAC3C,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,KAAK,EAAE,YAAY,CAAA;IACnB,WAAW,EAAE,CAAC,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;CAClB,KAAG,QAAQ,CAAC,CAwCZ,CAAA"}
1
+ {"version":3,"file":"handleMessage.d.ts","sourceRoot":"","sources":["../src/handleMessage.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,aAAa,YAAmB;IAC3C,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,KAAK,EAAE,YAAY,CAAA;IACnB,WAAW,EAAE,CAAC,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;CAClB,KAAG,QAAQ,CAAC,CAmCZ,CAAA"}
@@ -1,3 +1,4 @@
1
+ import { isLivePreviewEvent } from './isLivePreviewEvent.js';
1
2
  import { mergeData } from './mergeData.js';
2
3
  // For performance reasons, `fieldSchemaJSON` will only be sent once on the initial message
3
4
  // We need to cache this value so that it can be used across subsequent messages
@@ -10,7 +11,7 @@ let payloadLivePreviewFieldSchema = undefined // TODO: type this from `fieldSche
10
11
  let payloadLivePreviewPreviousData = undefined;
11
12
  export const handleMessage = async (args)=>{
12
13
  const { apiRoute, depth, event, initialData, serverURL } = args;
13
- if (event.origin === serverURL && event.data && typeof event.data === 'object' && event.data.type === 'payload-live-preview') {
14
+ if (isLivePreviewEvent(event, serverURL)) {
14
15
  const { data, externallyUpdatedRelationship, fieldSchemaJSON } = event.data;
15
16
  if (!payloadLivePreviewFieldSchema && fieldSchemaJSON) {
16
17
  payloadLivePreviewFieldSchema = fieldSchemaJSON;
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/handleMessage.ts"],"sourcesContent":["import { mergeData } from './mergeData.js'\n\n// For performance reasons, `fieldSchemaJSON` will only be sent once on the initial message\n// We need to cache this value so that it can be used across subsequent messages\n// To do this, save `fieldSchemaJSON` when it arrives as a global variable\n// Send this cached value to `mergeData`, instead of `eventData.fieldSchemaJSON` directly\nlet payloadLivePreviewFieldSchema = undefined // TODO: type this from `fieldSchemaToJSON` return type\n\n// Each time the data is merged, cache the result as a `previousData` variable\n// This will ensure changes compound overtop of each other\nlet payloadLivePreviewPreviousData = undefined\n\nexport const handleMessage = async <T>(args: {\n apiRoute?: string\n depth?: number\n event: MessageEvent\n initialData: T\n serverURL: string\n}): Promise<T> => {\n const { apiRoute, depth, event, initialData, serverURL } = args\n\n if (\n event.origin === serverURL &&\n event.data &&\n typeof event.data === 'object' &&\n event.data.type === 'payload-live-preview'\n ) {\n const { data, externallyUpdatedRelationship, fieldSchemaJSON } = event.data\n\n if (!payloadLivePreviewFieldSchema && fieldSchemaJSON) {\n payloadLivePreviewFieldSchema = fieldSchemaJSON\n }\n\n if (!payloadLivePreviewFieldSchema) {\n // eslint-disable-next-line no-console\n console.warn(\n 'Payload Live Preview: No `fieldSchemaJSON` was received from the parent window. Unable to merge data.',\n )\n\n return initialData\n }\n\n const mergedData = await mergeData<T>({\n apiRoute,\n depth,\n externallyUpdatedRelationship,\n fieldSchema: payloadLivePreviewFieldSchema,\n incomingData: data,\n initialData: payloadLivePreviewPreviousData || initialData,\n serverURL,\n })\n\n payloadLivePreviewPreviousData = mergedData\n\n return mergedData\n }\n\n return initialData\n}\n"],"names":["mergeData","payloadLivePreviewFieldSchema","undefined","payloadLivePreviewPreviousData","handleMessage","args","apiRoute","depth","event","initialData","serverURL","origin","data","type","externallyUpdatedRelationship","fieldSchemaJSON","console","warn","mergedData","fieldSchema","incomingData"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,SAASA,SAAS,QAAQ,iBAAgB;AAE1C,2FAA2F;AAC3F,gFAAgF;AAChF,0EAA0E;AAC1E,yFAAyF;AACzF,IAAIC,gCAAgCC,UAAU,uDAAuD;;AAErG,8EAA8E;AAC9E,0DAA0D;AAC1D,IAAIC,iCAAiCD;AAErC,OAAO,MAAME,gBAAgB,OAAUC;IAOrC,MAAM,EAAEC,QAAQ,EAAEC,KAAK,EAAEC,KAAK,EAAEC,WAAW,EAAEC,SAAS,EAAE,GAAGL;IAE3D,IACEG,MAAMG,MAAM,KAAKD,aACjBF,MAAMI,IAAI,IACV,OAAOJ,MAAMI,IAAI,KAAK,YACtBJ,MAAMI,IAAI,CAACC,IAAI,KAAK,wBACpB;QACA,MAAM,EAAED,IAAI,EAAEE,6BAA6B,EAAEC,eAAe,EAAE,GAAGP,MAAMI,IAAI;QAE3E,IAAI,CAACX,iCAAiCc,iBAAiB;YACrDd,gCAAgCc;QAClC;QAEA,IAAI,CAACd,+BAA+B;YAClC,sCAAsC;YACtCe,QAAQC,IAAI,CACV;YAGF,OAAOR;QACT;QAEA,MAAMS,aAAa,MAAMlB,UAAa;YACpCM;YACAC;YACAO;YACAK,aAAalB;YACbmB,cAAcR;YACdH,aAAaN,kCAAkCM;YAC/CC;QACF;QAEAP,iCAAiCe;QAEjC,OAAOA;IACT;IAEA,OAAOT;AACT,EAAC"}
1
+ {"version":3,"sources":["../src/handleMessage.ts"],"sourcesContent":["import { isLivePreviewEvent } from './isLivePreviewEvent.js'\nimport { mergeData } from './mergeData.js'\n\n// For performance reasons, `fieldSchemaJSON` will only be sent once on the initial message\n// We need to cache this value so that it can be used across subsequent messages\n// To do this, save `fieldSchemaJSON` when it arrives as a global variable\n// Send this cached value to `mergeData`, instead of `eventData.fieldSchemaJSON` directly\nlet payloadLivePreviewFieldSchema = undefined // TODO: type this from `fieldSchemaToJSON` return type\n\n// Each time the data is merged, cache the result as a `previousData` variable\n// This will ensure changes compound overtop of each other\nlet payloadLivePreviewPreviousData = undefined\n\nexport const handleMessage = async <T>(args: {\n apiRoute?: string\n depth?: number\n event: MessageEvent\n initialData: T\n serverURL: string\n}): Promise<T> => {\n const { apiRoute, depth, event, initialData, serverURL } = args\n\n if (isLivePreviewEvent(event, serverURL)) {\n const { data, externallyUpdatedRelationship, fieldSchemaJSON } = event.data\n\n if (!payloadLivePreviewFieldSchema && fieldSchemaJSON) {\n payloadLivePreviewFieldSchema = fieldSchemaJSON\n }\n\n if (!payloadLivePreviewFieldSchema) {\n // eslint-disable-next-line no-console\n console.warn(\n 'Payload Live Preview: No `fieldSchemaJSON` was received from the parent window. Unable to merge data.',\n )\n\n return initialData\n }\n\n const mergedData = await mergeData<T>({\n apiRoute,\n depth,\n externallyUpdatedRelationship,\n fieldSchema: payloadLivePreviewFieldSchema,\n incomingData: data,\n initialData: payloadLivePreviewPreviousData || initialData,\n serverURL,\n })\n\n payloadLivePreviewPreviousData = mergedData\n\n return mergedData\n }\n\n return initialData\n}\n"],"names":["isLivePreviewEvent","mergeData","payloadLivePreviewFieldSchema","undefined","payloadLivePreviewPreviousData","handleMessage","args","apiRoute","depth","event","initialData","serverURL","data","externallyUpdatedRelationship","fieldSchemaJSON","console","warn","mergedData","fieldSchema","incomingData"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,SAASA,kBAAkB,QAAQ,0BAAyB;AAC5D,SAASC,SAAS,QAAQ,iBAAgB;AAE1C,2FAA2F;AAC3F,gFAAgF;AAChF,0EAA0E;AAC1E,yFAAyF;AACzF,IAAIC,gCAAgCC,UAAU,uDAAuD;;AAErG,8EAA8E;AAC9E,0DAA0D;AAC1D,IAAIC,iCAAiCD;AAErC,OAAO,MAAME,gBAAgB,OAAUC;IAOrC,MAAM,EAAEC,QAAQ,EAAEC,KAAK,EAAEC,KAAK,EAAEC,WAAW,EAAEC,SAAS,EAAE,GAAGL;IAE3D,IAAIN,mBAAmBS,OAAOE,YAAY;QACxC,MAAM,EAAEC,IAAI,EAAEC,6BAA6B,EAAEC,eAAe,EAAE,GAAGL,MAAMG,IAAI;QAE3E,IAAI,CAACV,iCAAiCY,iBAAiB;YACrDZ,gCAAgCY;QAClC;QAEA,IAAI,CAACZ,+BAA+B;YAClC,sCAAsC;YACtCa,QAAQC,IAAI,CACV;YAGF,OAAON;QACT;QAEA,MAAMO,aAAa,MAAMhB,UAAa;YACpCM;YACAC;YACAK;YACAK,aAAahB;YACbiB,cAAcP;YACdF,aAAaN,kCAAkCM;YAC/CC;QACF;QAEAP,iCAAiCa;QAEjC,OAAOA;IACT;IAEA,OAAOP;AACT,EAAC"}
package/dist/index.d.ts CHANGED
@@ -1,4 +1,6 @@
1
1
  export { handleMessage } from './handleMessage.js';
2
+ export { isDocumentEvent } from './isDocumentEvent.js';
3
+ export { isLivePreviewEvent } from './isLivePreviewEvent.js';
2
4
  export { mergeData } from './mergeData.js';
3
5
  export { ready } from './ready.js';
4
6
  export { subscribe } from './subscribe.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAA;AAClD,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAC1C,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAA;AAClC,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAA;AAClD,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAA;AACtD,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAA;AAC5D,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAC1C,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAA;AAClC,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA"}
package/dist/index.js CHANGED
@@ -1,4 +1,6 @@
1
1
  export { handleMessage } from './handleMessage.js';
2
+ export { isDocumentEvent } from './isDocumentEvent.js';
3
+ export { isLivePreviewEvent } from './isLivePreviewEvent.js';
2
4
  export { mergeData } from './mergeData.js';
3
5
  export { ready } from './ready.js';
4
6
  export { subscribe } from './subscribe.js';
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export { handleMessage } from './handleMessage.js'\nexport { mergeData } from './mergeData.js'\nexport { ready } from './ready.js'\nexport { subscribe } from './subscribe.js'\nexport { unsubscribe } from './unsubscribe.js'\n"],"names":["handleMessage","mergeData","ready","subscribe","unsubscribe"],"rangeMappings":";;;;","mappings":"AAAA,SAASA,aAAa,QAAQ,qBAAoB;AAClD,SAASC,SAAS,QAAQ,iBAAgB;AAC1C,SAASC,KAAK,QAAQ,aAAY;AAClC,SAASC,SAAS,QAAQ,iBAAgB;AAC1C,SAASC,WAAW,QAAQ,mBAAkB"}
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export { handleMessage } from './handleMessage.js'\nexport { isDocumentEvent } from './isDocumentEvent.js'\nexport { isLivePreviewEvent } from './isLivePreviewEvent.js'\nexport { mergeData } from './mergeData.js'\nexport { ready } from './ready.js'\nexport { subscribe } from './subscribe.js'\nexport { unsubscribe } from './unsubscribe.js'\n"],"names":["handleMessage","isDocumentEvent","isLivePreviewEvent","mergeData","ready","subscribe","unsubscribe"],"rangeMappings":";;;;;;","mappings":"AAAA,SAASA,aAAa,QAAQ,qBAAoB;AAClD,SAASC,eAAe,QAAQ,uBAAsB;AACtD,SAASC,kBAAkB,QAAQ,0BAAyB;AAC5D,SAASC,SAAS,QAAQ,iBAAgB;AAC1C,SAASC,KAAK,QAAQ,aAAY;AAClC,SAASC,SAAS,QAAQ,iBAAgB;AAC1C,SAASC,WAAW,QAAQ,mBAAkB"}
@@ -0,0 +1,2 @@
1
+ export declare const isDocumentEvent: (event: MessageEvent, serverURL: string) => boolean;
2
+ //# sourceMappingURL=isDocumentEvent.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isDocumentEvent.d.ts","sourceRoot":"","sources":["../src/isDocumentEvent.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,eAAe,UAAW,YAAY,aAAa,MAAM,KAAG,OAI3B,CAAA"}
@@ -0,0 +1,3 @@
1
+ export const isDocumentEvent = (event, serverURL)=>event.origin === serverURL && event.data && typeof event.data === 'object' && event.data.type === 'payload-document-event';
2
+
3
+ //# sourceMappingURL=isDocumentEvent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/isDocumentEvent.ts"],"sourcesContent":["export const isDocumentEvent = (event: MessageEvent, serverURL: string): boolean =>\n event.origin === serverURL &&\n event.data &&\n typeof event.data === 'object' &&\n event.data.type === 'payload-document-event'\n"],"names":["isDocumentEvent","event","serverURL","origin","data","type"],"rangeMappings":"","mappings":"AAAA,OAAO,MAAMA,kBAAkB,CAACC,OAAqBC,YACnDD,MAAME,MAAM,KAAKD,aACjBD,MAAMG,IAAI,IACV,OAAOH,MAAMG,IAAI,KAAK,YACtBH,MAAMG,IAAI,CAACC,IAAI,KAAK,yBAAwB"}
@@ -0,0 +1,2 @@
1
+ export declare const isLivePreviewEvent: (event: MessageEvent, serverURL: string) => boolean;
2
+ //# sourceMappingURL=isLivePreviewEvent.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isLivePreviewEvent.d.ts","sourceRoot":"","sources":["../src/isLivePreviewEvent.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,kBAAkB,UAAW,YAAY,aAAa,MAAM,KAAG,OAIhC,CAAA"}
@@ -0,0 +1,3 @@
1
+ export const isLivePreviewEvent = (event, serverURL)=>event.origin === serverURL && event.data && typeof event.data === 'object' && event.data.type === 'payload-live-preview';
2
+
3
+ //# sourceMappingURL=isLivePreviewEvent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/isLivePreviewEvent.ts"],"sourcesContent":["export const isLivePreviewEvent = (event: MessageEvent, serverURL: string): boolean =>\n event.origin === serverURL &&\n event.data &&\n typeof event.data === 'object' &&\n event.data.type === 'payload-live-preview'\n"],"names":["isLivePreviewEvent","event","serverURL","origin","data","type"],"rangeMappings":"","mappings":"AAAA,OAAO,MAAMA,qBAAqB,CAACC,OAAqBC,YACtDD,MAAME,MAAM,KAAKD,aACjBD,MAAMG,IAAI,IACV,OAAOH,MAAMG,IAAI,KAAK,YACtBH,MAAMG,IAAI,CAACC,IAAI,KAAK,uBAAsB"}
@@ -1 +1 @@
1
- {"version":3,"file":"subscribe.d.ts","sourceRoot":"","sources":["../src/subscribe.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,SAAS,YAAa;IACjC,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,QAAQ,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,IAAI,CAAA;IAC3B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,WAAW,EAAE,CAAC,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;CAClB,KAAG,CAAC,CAAC,KAAK,EAAE,YAAY,KAAK,IAAI,CAajC,CAAA"}
1
+ {"version":3,"file":"subscribe.d.ts","sourceRoot":"","sources":["../src/subscribe.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,SAAS,YAAa;IACjC,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,QAAQ,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,IAAI,CAAA;IAC3B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,WAAW,EAAE,CAAC,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;CAClB,KAAG,CAAC,CAAC,KAAK,EAAE,YAAY,KAAK,IAAI,CAoBjC,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/subscribe.ts"],"sourcesContent":["import { handleMessage } from './handleMessage.js'\n\nexport const subscribe = <T>(args: {\n apiRoute?: string\n callback: (data: T) => void\n depth?: number\n initialData: T\n serverURL: string\n}): ((event: MessageEvent) => void) => {\n const { apiRoute, callback, depth, initialData, serverURL } = args\n\n const onMessage = async (event: MessageEvent) => {\n const mergedData = await handleMessage<T>({ apiRoute, depth, event, initialData, serverURL })\n callback(mergedData)\n }\n\n if (typeof window !== 'undefined') {\n window.addEventListener('message', onMessage)\n }\n\n return onMessage\n}\n"],"names":["handleMessage","subscribe","args","apiRoute","callback","depth","initialData","serverURL","onMessage","event","mergedData","window","addEventListener"],"rangeMappings":";;;;;;;;;;;;;;;;;","mappings":"AAAA,SAASA,aAAa,QAAQ,qBAAoB;AAElD,OAAO,MAAMC,YAAY,CAAIC;IAO3B,MAAM,EAAEC,QAAQ,EAAEC,QAAQ,EAAEC,KAAK,EAAEC,WAAW,EAAEC,SAAS,EAAE,GAAGL;IAE9D,MAAMM,YAAY,OAAOC;QACvB,MAAMC,aAAa,MAAMV,cAAiB;YAAEG;YAAUE;YAAOI;YAAOH;YAAaC;QAAU;QAC3FH,SAASM;IACX;IAEA,IAAI,OAAOC,WAAW,aAAa;QACjCA,OAAOC,gBAAgB,CAAC,WAAWJ;IACrC;IAEA,OAAOA;AACT,EAAC"}
1
+ {"version":3,"sources":["../src/subscribe.ts"],"sourcesContent":["import { handleMessage } from './handleMessage.js'\n\nexport const subscribe = <T>(args: {\n apiRoute?: string\n callback: (data: T) => void\n depth?: number\n initialData: T\n serverURL: string\n}): ((event: MessageEvent) => void) => {\n const { apiRoute, callback, depth, initialData, serverURL } = args\n\n const onMessage = async (event: MessageEvent) => {\n const mergedData = await handleMessage<T>({\n apiRoute,\n depth,\n event,\n initialData,\n serverURL,\n })\n\n callback(mergedData)\n }\n\n if (typeof window !== 'undefined') {\n window.addEventListener('message', onMessage)\n }\n\n return onMessage\n}\n"],"names":["handleMessage","subscribe","args","apiRoute","callback","depth","initialData","serverURL","onMessage","event","mergedData","window","addEventListener"],"rangeMappings":";;;;;;;;;;;;;;;;;","mappings":"AAAA,SAASA,aAAa,QAAQ,qBAAoB;AAElD,OAAO,MAAMC,YAAY,CAAIC;IAO3B,MAAM,EAAEC,QAAQ,EAAEC,QAAQ,EAAEC,KAAK,EAAEC,WAAW,EAAEC,SAAS,EAAE,GAAGL;IAE9D,MAAMM,YAAY,OAAOC;QACvB,MAAMC,aAAa,MAAMV,cAAiB;YACxCG;YACAE;YACAI;YACAH;YACAC;QACF;QAEAH,SAASM;IACX;IAEA,IAAI,OAAOC,WAAW,aAAa;QACjCA,OAAOC,gBAAgB,CAAC,WAAWJ;IACrC;IAEA,OAAOA;AACT,EAAC"}
package/package.json CHANGED
@@ -1,22 +1,16 @@
1
1
  {
2
2
  "name": "@payloadcms/live-preview",
3
- "version": "3.0.0-beta.16",
3
+ "version": "3.0.0-beta.27",
4
4
  "description": "The official live preview JavaScript SDK for Payload",
5
+ "homepage": "https://payloadcms.com",
5
6
  "repository": {
6
7
  "type": "git",
7
8
  "url": "https://github.com/payloadcms/payload.git",
8
9
  "directory": "packages/live-preview"
9
10
  },
10
11
  "license": "MIT",
11
- "homepage": "https://payloadcms.com",
12
- "author": "Payload CMS, Inc.",
13
- "main": "./dist/index.js",
14
- "types": "./dist/index.d.ts",
12
+ "author": "Payload <dev@payloadcms.com> (https://payloadcms.com)",
15
13
  "type": "module",
16
- "devDependencies": {
17
- "@payloadcms/eslint-config": "3.0.0-beta.16",
18
- "payload": "3.0.0-beta.16"
19
- },
20
14
  "exports": {
21
15
  ".": {
22
16
  "import": "./dist/index.js",
@@ -24,12 +18,18 @@
24
18
  "types": "./dist/index.d.ts"
25
19
  }
26
20
  },
27
- "publishConfig": {
28
- "registry": "https://registry.npmjs.org/"
29
- },
21
+ "main": "./dist/index.js",
22
+ "types": "./dist/index.d.ts",
30
23
  "files": [
31
24
  "dist"
32
25
  ],
26
+ "devDependencies": {
27
+ "@payloadcms/eslint-config": "1.1.1",
28
+ "payload": "3.0.0-beta.27"
29
+ },
30
+ "publishConfig": {
31
+ "registry": "https://registry.npmjs.org/"
32
+ },
33
33
  "scripts": {
34
34
  "build": "pnpm copyfiles && pnpm build:swc && pnpm build:types",
35
35
  "build:swc": "swc ./src -d ./dist --config-file .swcrc",
@@ -1,3 +0,0 @@
1
- export { }; //# sourceMappingURL=handleMessage.d.ts.map
2
-
3
- //# sourceMappingURL=handleMessage.d.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/handleMessage.d.ts"],"names":[],"rangeMappings":"","mappings":"AAYA,WA8CC"}
package/dist/index.d.js DELETED
@@ -1,7 +0,0 @@
1
- export { handleMessage } from './handleMessage.js';
2
- export { mergeData } from './mergeData.js';
3
- export { ready } from './ready.js';
4
- export { subscribe } from './subscribe.js';
5
- export { unsubscribe } from './unsubscribe.js'; //# sourceMappingURL=index.d.ts.map
6
-
7
- //# sourceMappingURL=index.d.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/index.d.ts"],"names":["handleMessage","mergeData","ready","subscribe","unsubscribe"],"rangeMappings":";;;;","mappings":"AAAA,SAASA,aAAa,QAAQ,qBAAoB;AAClD,SAASC,SAAS,QAAQ,iBAAgB;AAC1C,SAASC,KAAK,QAAQ,aAAY;AAClC,SAASC,SAAS,QAAQ,iBAAgB;AAC1C,SAASC,WAAW,QAAQ,mBAAkB"}
@@ -1,3 +0,0 @@
1
- export { }; //# sourceMappingURL=mergeData.d.ts.map
2
-
3
- //# sourceMappingURL=mergeData.d.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/mergeData.d.ts"],"names":[],"rangeMappings":"","mappings":"AAiBA"}
@@ -1,3 +0,0 @@
1
- export { }; //# sourceMappingURL=subscribe.d.ts.map
2
-
3
- //# sourceMappingURL=subscribe.d.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/subscribe.d.ts"],"names":[],"rangeMappings":"","mappings":"AAEA,WAmBC"}
@@ -1,3 +0,0 @@
1
- export { }; //# sourceMappingURL=traverseFields.d.ts.map
2
-
3
- //# sourceMappingURL=traverseFields.d.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/traverseFields.d.ts"],"names":[],"rangeMappings":"","mappings":"AAMA,WAkRC"}