@wix/astro 2.14.0 → 2.17.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/build/dependencies/astro-custom-elements-extensions/types/index.d.ts +24 -6
- package/build/dependencies/astro-payment-links/backend-runtime/proposal.d.ts +5 -0
- package/build/dependencies/astro-payment-links/backend-runtime/proposal.js +24 -0
- package/build/integration/builders.d.ts +40 -38
- package/build/integration/builders.js +1 -1
- package/build/integration/builders.js.map +1 -1
- package/build/integration/{chunk-7AVRXF3V.js → chunk-IOVROVEX.js} +252 -118
- package/build/integration/chunk-IOVROVEX.js.map +1 -0
- package/build/integration/index.d.ts +6 -0
- package/build/integration/index.js +25 -18
- package/build/integration/index.js.map +1 -1
- package/package.json +29 -19
- package/build/dependencies/astro-site-plugins-extensions/types/index.d.ts +0 -22
- package/build/integration/chunk-7AVRXF3V.js.map +0 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { WixIntegration } from '@wix/astro-core';
|
|
2
|
-
import { DevCenterCustomElementBehaviors, DevCenterCustomElementSize, DevCenterCustomElementPresets } from '@wix/dev-center-schemas';
|
|
1
|
+
import { WixIntegration, BaseExtension } from '@wix/astro-core';
|
|
2
|
+
import { DevCenterCustomElementBehaviors, DevCenterCustomElementSize, DevCenterCustomElementPresets, DevCenterSitePluginMarketData, DevCenterSitePluginPlacements } from '@wix/dev-center-schemas';
|
|
3
3
|
|
|
4
4
|
declare const createIntegration: () => WixIntegration;
|
|
5
5
|
|
|
6
6
|
interface CustomElement {
|
|
7
7
|
type: 'CustomElement';
|
|
8
|
-
options: Options;
|
|
8
|
+
options: Options$1;
|
|
9
9
|
}
|
|
10
|
-
interface Options {
|
|
10
|
+
interface Options$1 {
|
|
11
11
|
id: string;
|
|
12
12
|
name: string;
|
|
13
13
|
behaviors?: DevCenterCustomElementBehaviors;
|
|
@@ -22,6 +22,24 @@ interface Options {
|
|
|
22
22
|
tagName: string;
|
|
23
23
|
width: DevCenterCustomElementSize['width'];
|
|
24
24
|
}
|
|
25
|
-
declare function customElement(options: Options): CustomElement;
|
|
25
|
+
declare function customElement(options: Options$1): CustomElement;
|
|
26
|
+
|
|
27
|
+
interface SitePlugin extends BaseExtension {
|
|
28
|
+
type: 'SitePlugin';
|
|
29
|
+
options: Options;
|
|
30
|
+
}
|
|
31
|
+
interface Options {
|
|
32
|
+
id: string;
|
|
33
|
+
name: string;
|
|
34
|
+
element: string;
|
|
35
|
+
installation: {
|
|
36
|
+
autoAdd: boolean;
|
|
37
|
+
};
|
|
38
|
+
marketData?: DevCenterSitePluginMarketData;
|
|
39
|
+
placements: DevCenterSitePluginPlacements[];
|
|
40
|
+
settings: string;
|
|
41
|
+
tagName: string;
|
|
42
|
+
}
|
|
43
|
+
declare function sitePlugin(options: Options): SitePlugin;
|
|
26
44
|
|
|
27
|
-
export { customElement, createIntegration as default };
|
|
45
|
+
export { customElement, createIntegration as default, sitePlugin };
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import {
|
|
2
|
+
elevate
|
|
3
|
+
} from "./chunk-656BVIJ3.js";
|
|
4
|
+
|
|
5
|
+
// src/routes/proposal.ts
|
|
6
|
+
import { ok } from "assert";
|
|
7
|
+
import { oAuthApps } from "@wix/auth-management";
|
|
8
|
+
import { WIX_CLIENT_ID } from "astro:env/client";
|
|
9
|
+
var GET = async ({ url }) => {
|
|
10
|
+
const { redirectUrlWixPages } = await elevate(oAuthApps.getOAuthApp)(
|
|
11
|
+
WIX_CLIENT_ID
|
|
12
|
+
);
|
|
13
|
+
ok(redirectUrlWixPages != null);
|
|
14
|
+
const baseUrl = redirectUrlWixPages.endsWith("/") ? redirectUrlWixPages : `${redirectUrlWixPages}/`;
|
|
15
|
+
const newProposalUrl = new URL(url.pathname.replace("/", ""), baseUrl);
|
|
16
|
+
newProposalUrl.search = url.search;
|
|
17
|
+
return new Response(null, {
|
|
18
|
+
headers: { Location: newProposalUrl.toString() },
|
|
19
|
+
status: 302
|
|
20
|
+
});
|
|
21
|
+
};
|
|
22
|
+
export {
|
|
23
|
+
GET
|
|
24
|
+
};
|
|
@@ -29,7 +29,7 @@ interface DevCenterCustomElementSize {
|
|
|
29
29
|
};
|
|
30
30
|
}
|
|
31
31
|
interface DevCenterSitePluginMarketData {
|
|
32
|
-
name
|
|
32
|
+
name?: string;
|
|
33
33
|
description?: string;
|
|
34
34
|
logoUrl?: string;
|
|
35
35
|
}
|
|
@@ -90,15 +90,15 @@ declare function ecomGiftCards(options: Options$4$1): EcomGiftCardsProvider;
|
|
|
90
90
|
|
|
91
91
|
interface EcomPaymentSettings {
|
|
92
92
|
type: 'EcomPaymentSettings';
|
|
93
|
-
options: Options$3$
|
|
93
|
+
options: Options$3$1;
|
|
94
94
|
}
|
|
95
|
-
interface Options$3$
|
|
95
|
+
interface Options$3$1 {
|
|
96
96
|
id: string;
|
|
97
97
|
name: string;
|
|
98
98
|
fallbackValueForRequires3dSecure?: boolean;
|
|
99
99
|
source: string;
|
|
100
100
|
}
|
|
101
|
-
declare function ecomPaymentSettings(options: Options$3$
|
|
101
|
+
declare function ecomPaymentSettings(options: Options$3$1): EcomPaymentSettings;
|
|
102
102
|
|
|
103
103
|
interface EcomShippingRates {
|
|
104
104
|
type: 'EcomShippingRates';
|
|
@@ -118,15 +118,15 @@ declare function ecomShippingRates(options: Options$2$2): EcomShippingRates;
|
|
|
118
118
|
|
|
119
119
|
interface EcomValidations {
|
|
120
120
|
type: 'EcomValidations';
|
|
121
|
-
options: Options$1$
|
|
121
|
+
options: Options$1$3;
|
|
122
122
|
}
|
|
123
|
-
interface Options$1$
|
|
123
|
+
interface Options$1$3 {
|
|
124
124
|
id: string;
|
|
125
125
|
name: string;
|
|
126
126
|
source: string;
|
|
127
127
|
validateInCart?: boolean;
|
|
128
128
|
}
|
|
129
|
-
declare function ecomValidations(options: Options$1$
|
|
129
|
+
declare function ecomValidations(options: Options$1$3): EcomValidations;
|
|
130
130
|
|
|
131
131
|
interface Webhook {
|
|
132
132
|
type: 'Webhook';
|
|
@@ -140,9 +140,9 @@ declare function webhook(options: Options$7): Webhook;
|
|
|
140
140
|
|
|
141
141
|
interface BackofficeExtensionMenuPlugin {
|
|
142
142
|
type: 'BackofficeExtensionMenuPlugin';
|
|
143
|
-
options: Options$3
|
|
143
|
+
options: Options$3;
|
|
144
144
|
}
|
|
145
|
-
interface Options$3
|
|
145
|
+
interface Options$3 {
|
|
146
146
|
id: string;
|
|
147
147
|
action: {
|
|
148
148
|
navigateToPage: {
|
|
@@ -159,7 +159,7 @@ interface Options$3$1 {
|
|
|
159
159
|
subtitle?: string;
|
|
160
160
|
title: string;
|
|
161
161
|
}
|
|
162
|
-
declare function backofficeExtensionMenuPlugin(options: Options$3
|
|
162
|
+
declare function backofficeExtensionMenuPlugin(options: Options$3): BackofficeExtensionMenuPlugin;
|
|
163
163
|
|
|
164
164
|
interface BackofficeExtensionWidget {
|
|
165
165
|
type: 'BackofficeExtensionWidget';
|
|
@@ -177,9 +177,9 @@ declare function backofficeExtensionWidget(options: Options$2$1): BackofficeExte
|
|
|
177
177
|
|
|
178
178
|
interface BackofficeModal {
|
|
179
179
|
type: 'BackofficeModal';
|
|
180
|
-
options: Options$1$
|
|
180
|
+
options: Options$1$2;
|
|
181
181
|
}
|
|
182
|
-
interface Options$1$
|
|
182
|
+
interface Options$1$2 {
|
|
183
183
|
id: string;
|
|
184
184
|
component: string;
|
|
185
185
|
height?: number;
|
|
@@ -187,7 +187,7 @@ interface Options$1$1 {
|
|
|
187
187
|
title: string;
|
|
188
188
|
width?: number;
|
|
189
189
|
}
|
|
190
|
-
declare function backofficeModal(options: Options$1$
|
|
190
|
+
declare function backofficeModal(options: Options$1$2): BackofficeModal;
|
|
191
191
|
|
|
192
192
|
interface BackofficePage {
|
|
193
193
|
type: 'BackofficePage';
|
|
@@ -203,9 +203,9 @@ declare function backofficePage(options: Options$4): BackofficePage;
|
|
|
203
203
|
|
|
204
204
|
interface CustomElement {
|
|
205
205
|
type: 'CustomElement';
|
|
206
|
-
options: Options$
|
|
206
|
+
options: Options$1$1;
|
|
207
207
|
}
|
|
208
|
-
interface Options$
|
|
208
|
+
interface Options$1$1 {
|
|
209
209
|
id: string;
|
|
210
210
|
name: string;
|
|
211
211
|
behaviors?: DevCenterCustomElementBehaviors;
|
|
@@ -220,20 +220,38 @@ interface Options$3 {
|
|
|
220
220
|
tagName: string;
|
|
221
221
|
width: DevCenterCustomElementSize['width'];
|
|
222
222
|
}
|
|
223
|
-
declare function customElement(options: Options$
|
|
223
|
+
declare function customElement(options: Options$1$1): CustomElement;
|
|
224
224
|
|
|
225
|
-
interface
|
|
226
|
-
type: '
|
|
225
|
+
interface SitePlugin extends BaseExtension {
|
|
226
|
+
type: 'SitePlugin';
|
|
227
227
|
options: Options$2;
|
|
228
228
|
}
|
|
229
229
|
interface Options$2 {
|
|
230
|
+
id: string;
|
|
231
|
+
name: string;
|
|
232
|
+
element: string;
|
|
233
|
+
installation: {
|
|
234
|
+
autoAdd: boolean;
|
|
235
|
+
};
|
|
236
|
+
marketData?: DevCenterSitePluginMarketData;
|
|
237
|
+
placements: DevCenterSitePluginPlacements[];
|
|
238
|
+
settings: string;
|
|
239
|
+
tagName: string;
|
|
240
|
+
}
|
|
241
|
+
declare function sitePlugin(options: Options$2): SitePlugin;
|
|
242
|
+
|
|
243
|
+
interface EmbeddedScript extends BaseExtension {
|
|
244
|
+
type: 'EmbeddedScript';
|
|
245
|
+
options: Options$1;
|
|
246
|
+
}
|
|
247
|
+
interface Options$1 {
|
|
230
248
|
id: string;
|
|
231
249
|
name: string;
|
|
232
250
|
placement: 'BODY_END' | 'BODY_START' | 'HEAD';
|
|
233
251
|
scriptType: 'ADVERTISING' | 'ANALYTICS' | 'ESSENTIAL' | 'FUNCTIONAL';
|
|
234
252
|
source: string;
|
|
235
253
|
}
|
|
236
|
-
declare function embeddedScript(options: Options$
|
|
254
|
+
declare function embeddedScript(options: Options$1): EmbeddedScript;
|
|
237
255
|
|
|
238
256
|
interface SiteComponentPanel extends BaseExtension {
|
|
239
257
|
type: 'SiteComponentPanel';
|
|
@@ -259,9 +277,9 @@ interface PresetOptions {
|
|
|
259
277
|
}
|
|
260
278
|
interface SiteComponent extends BaseExtension {
|
|
261
279
|
type: 'SiteComponent';
|
|
262
|
-
options: Options
|
|
280
|
+
options: Options;
|
|
263
281
|
}
|
|
264
|
-
interface Options
|
|
282
|
+
interface Options {
|
|
265
283
|
id: string;
|
|
266
284
|
type: string;
|
|
267
285
|
description: string;
|
|
@@ -287,23 +305,7 @@ interface Options$1 {
|
|
|
287
305
|
};
|
|
288
306
|
};
|
|
289
307
|
}
|
|
290
|
-
declare function siteComponent(options: Options
|
|
291
|
-
|
|
292
|
-
interface SitePlugin extends BaseExtension {
|
|
293
|
-
type: 'SitePlugin';
|
|
294
|
-
options: Options;
|
|
295
|
-
}
|
|
296
|
-
interface Options {
|
|
297
|
-
id: string;
|
|
298
|
-
name: string;
|
|
299
|
-
installation: {
|
|
300
|
-
autoAdd: boolean;
|
|
301
|
-
};
|
|
302
|
-
marketData: DevCenterSitePluginMarketData;
|
|
303
|
-
placements: DevCenterSitePluginPlacements[];
|
|
304
|
-
referenceComponentId: string;
|
|
305
|
-
}
|
|
306
|
-
declare function sitePlugin(options: Options): SitePlugin;
|
|
308
|
+
declare function siteComponent(options: Options): SiteComponent;
|
|
307
309
|
|
|
308
310
|
declare const extensions: {
|
|
309
311
|
customElement: typeof customElement;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/builders.ts"],"sourcesContent":["import {\n ecomAdditionalFees,\n ecomDiscountTriggers,\n ecomGiftCards,\n ecomPaymentSettings,\n ecomShippingRates,\n ecomValidations,\n webhook as event,\n} from '@wix/astro-backend-extensions';\nimport {\n backofficeExtensionMenuPlugin as dashboardMenuPlugin,\n backofficeModal as dashboardModal,\n backofficePage as dashboardPage,\n backofficeExtensionWidget as dashboardPlugin,\n} from '@wix/astro-backoffice-extensions';\nimport { genericExtension } from '@wix/astro-core';\nimport {
|
|
1
|
+
{"version":3,"sources":["../../src/builders.ts"],"sourcesContent":["import {\n ecomAdditionalFees,\n ecomDiscountTriggers,\n ecomGiftCards,\n ecomPaymentSettings,\n ecomShippingRates,\n ecomValidations,\n webhook as event,\n} from '@wix/astro-backend-extensions';\nimport {\n backofficeExtensionMenuPlugin as dashboardMenuPlugin,\n backofficeModal as dashboardModal,\n backofficePage as dashboardPage,\n backofficeExtensionWidget as dashboardPlugin,\n} from '@wix/astro-backoffice-extensions';\nimport { genericExtension } from '@wix/astro-core';\nimport {\n customElement,\n sitePlugin,\n} from '@wix/astro-custom-elements-extensions';\nimport { embeddedScript } from '@wix/astro-embedded-scripts-extensions';\nimport { siteComponentPanel } from '@wix/astro-site-component-panels-extensions';\nimport { siteComponent } from '@wix/astro-site-components-extensions';\n\nexport { app } from '@wix/astro-core';\nexport const extensions = {\n customElement,\n dashboardMenuPlugin,\n dashboardModal,\n dashboardPage,\n dashboardPlugin,\n ecomAdditionalFees,\n ecomDiscountTriggers,\n ecomGiftCards,\n ecomPaymentSettings,\n ecomShippingRates,\n ecomValidations,\n embeddedScript,\n event,\n genericExtension,\n siteComponent,\n siteComponentPanel,\n sitePlugin,\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAyBO,IAAM,aAAa;AAAA,EACxB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;","names":[]}
|