@cmssy/core 19.14.0 → 19.16.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/{content-client-MPHJMucu.d.cts → content-client-EAeHiBv2.d.cts} +6 -2
- package/dist/{content-client-MPHJMucu.d.ts → content-client-EAeHiBv2.d.ts} +6 -2
- package/dist/{csp-DKvpTbqW.d.ts → csp-CYbG4uan.d.cts} +8 -3
- package/dist/{csp-B7EAjPSy.d.cts → csp-DE59VC7Q.d.ts} +8 -3
- package/dist/index.cjs +333 -12
- package/dist/index.d.cts +119 -10
- package/dist/index.d.ts +119 -10
- package/dist/index.js +324 -13
- package/dist/internal/locale.cjs +21 -8
- package/dist/internal/locale.d.cts +2 -2
- package/dist/internal/locale.d.ts +2 -2
- package/dist/internal/locale.js +21 -8
- package/dist/internal.cjs +45 -10
- package/dist/internal.d.cts +7 -6
- package/dist/internal.d.ts +7 -6
- package/dist/internal.js +45 -10
- package/dist/{locale-DfW5CAIM.d.cts → locale-CUk6dYTo.d.cts} +2 -2
- package/dist/{locale-B3M-PFm4.d.ts → locale-Ds2uJX5V.d.ts} +2 -2
- package/dist/preflight.cjs +1 -1
- package/dist/preflight.d.cts +2 -2
- package/dist/preflight.d.ts +2 -2
- package/dist/preflight.js +1 -1
- package/package.json +2 -2
package/dist/internal.js
CHANGED
|
@@ -152,7 +152,7 @@ function documentText(document2) {
|
|
|
152
152
|
}
|
|
153
153
|
|
|
154
154
|
// src/version.ts
|
|
155
|
-
var CMSSY_CORE_VERSION = "19.
|
|
155
|
+
var CMSSY_CORE_VERSION = "19.16.0" ;
|
|
156
156
|
var CMSSY_USER_AGENT = `@cmssy/core/${CMSSY_CORE_VERSION}`;
|
|
157
157
|
|
|
158
158
|
// src/data/http.ts
|
|
@@ -591,13 +591,26 @@ function asBucket(value) {
|
|
|
591
591
|
// src/data/graphql-request.ts
|
|
592
592
|
async function graphqlRequest(config, query, variables, options = {}, label = "request") {
|
|
593
593
|
const url = options.public ? resolvePublicUrl(config) : resolveApiUrl(config.apiUrl);
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
594
|
+
const text = documentText(query);
|
|
595
|
+
return postGraphql(
|
|
596
|
+
url,
|
|
597
|
+
text,
|
|
598
|
+
withConfigChannel(config, text, variables),
|
|
599
|
+
{
|
|
600
|
+
fetch: options.fetch,
|
|
601
|
+
signal: options.signal,
|
|
602
|
+
headers: options.headers,
|
|
603
|
+
retry: options.retry,
|
|
604
|
+
label
|
|
605
|
+
}
|
|
606
|
+
);
|
|
607
|
+
}
|
|
608
|
+
function withConfigChannel(config, document2, variables) {
|
|
609
|
+
const channel = config.channel?.trim();
|
|
610
|
+
if (!channel || !/\$channel\b/.test(document2)) return variables;
|
|
611
|
+
const current = variables ?? {};
|
|
612
|
+
if (current.channel !== void 0) return variables;
|
|
613
|
+
return { ...current, channel };
|
|
601
614
|
}
|
|
602
615
|
var SITE_CONFIG_QUERY = typedOperation(`query PublicSiteConfig($workspaceSlug: String!) {
|
|
603
616
|
public {
|
|
@@ -1334,9 +1347,13 @@ function cmssyCspHeaders(options) {
|
|
|
1334
1347
|
}
|
|
1335
1348
|
|
|
1336
1349
|
// src/data/buyer-prices.ts
|
|
1337
|
-
var BUYER_PRICES_QUERY = typedOperation(`query BuyerPrices(
|
|
1350
|
+
var BUYER_PRICES_QUERY = typedOperation(`query BuyerPrices(
|
|
1351
|
+
$workspaceId: ID!
|
|
1352
|
+
$items: [PriceQueryItem!]!
|
|
1353
|
+
$channel: String
|
|
1354
|
+
) {
|
|
1338
1355
|
account {
|
|
1339
|
-
prices(workspaceId: $workspaceId, items: $items) {
|
|
1356
|
+
prices(workspaceId: $workspaceId, items: $items, channel: $channel) {
|
|
1340
1357
|
recordId
|
|
1341
1358
|
variantKey
|
|
1342
1359
|
currency
|
|
@@ -1345,6 +1362,7 @@ var BUYER_PRICES_QUERY = typedOperation(`query BuyerPrices($workspaceId: ID!, $i
|
|
|
1345
1362
|
listed
|
|
1346
1363
|
basePrice
|
|
1347
1364
|
source
|
|
1365
|
+
listSource
|
|
1348
1366
|
minQuantity
|
|
1349
1367
|
maxQuantity
|
|
1350
1368
|
increment
|
|
@@ -1352,6 +1370,23 @@ var BUYER_PRICES_QUERY = typedOperation(`query BuyerPrices($workspaceId: ID!, $i
|
|
|
1352
1370
|
minQty
|
|
1353
1371
|
price
|
|
1354
1372
|
}
|
|
1373
|
+
displayMode
|
|
1374
|
+
taxRate
|
|
1375
|
+
priceAmount {
|
|
1376
|
+
net
|
|
1377
|
+
tax
|
|
1378
|
+
gross
|
|
1379
|
+
}
|
|
1380
|
+
priceMaxAmount {
|
|
1381
|
+
net
|
|
1382
|
+
tax
|
|
1383
|
+
gross
|
|
1384
|
+
}
|
|
1385
|
+
basePriceAmount {
|
|
1386
|
+
net
|
|
1387
|
+
tax
|
|
1388
|
+
gross
|
|
1389
|
+
}
|
|
1355
1390
|
}
|
|
1356
1391
|
}
|
|
1357
1392
|
}`);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { F as FetchLike, R as RetryOption } from './content-client-
|
|
1
|
+
import { CmssyLocaleContext, CmssySiteLocales } from '@cmssy/types';
|
|
2
|
+
import { F as FetchLike, R as RetryOption, C as CmssyClientConfig } from './content-client-EAeHiBv2.cjs';
|
|
3
3
|
|
|
4
4
|
interface CmssyTypedDocument<Result, Variables> {
|
|
5
5
|
__apiType?: (variables: Variables) => Result;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { F as FetchLike, R as RetryOption } from './content-client-
|
|
1
|
+
import { CmssyLocaleContext, CmssySiteLocales } from '@cmssy/types';
|
|
2
|
+
import { F as FetchLike, R as RetryOption, C as CmssyClientConfig } from './content-client-EAeHiBv2.js';
|
|
3
3
|
|
|
4
4
|
interface CmssyTypedDocument<Result, Variables> {
|
|
5
5
|
__apiType?: (variables: Variables) => Result;
|
package/dist/preflight.cjs
CHANGED
|
@@ -152,7 +152,7 @@ function documentText(document) {
|
|
|
152
152
|
}
|
|
153
153
|
|
|
154
154
|
// src/version.ts
|
|
155
|
-
var CMSSY_CORE_VERSION = "19.
|
|
155
|
+
var CMSSY_CORE_VERSION = "19.16.0" ;
|
|
156
156
|
var CMSSY_USER_AGENT = `@cmssy/core/${CMSSY_CORE_VERSION}`;
|
|
157
157
|
|
|
158
158
|
// src/content/content-client.ts
|
package/dist/preflight.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { F as FetchLike } from './content-client-
|
|
2
|
-
import
|
|
1
|
+
import { F as FetchLike, C as CmssyClientConfig } from './content-client-EAeHiBv2.cjs';
|
|
2
|
+
import '@cmssy/types';
|
|
3
3
|
|
|
4
4
|
interface EditDiagnosticsConfig {
|
|
5
5
|
apiUrl?: string;
|
package/dist/preflight.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { F as FetchLike } from './content-client-
|
|
2
|
-
import
|
|
1
|
+
import { F as FetchLike, C as CmssyClientConfig } from './content-client-EAeHiBv2.js';
|
|
2
|
+
import '@cmssy/types';
|
|
3
3
|
|
|
4
4
|
interface EditDiagnosticsConfig {
|
|
5
5
|
apiUrl?: string;
|
package/dist/preflight.js
CHANGED
|
@@ -150,7 +150,7 @@ function documentText(document) {
|
|
|
150
150
|
}
|
|
151
151
|
|
|
152
152
|
// src/version.ts
|
|
153
|
-
var CMSSY_CORE_VERSION = "19.
|
|
153
|
+
var CMSSY_CORE_VERSION = "19.16.0" ;
|
|
154
154
|
var CMSSY_USER_AGENT = `@cmssy/core/${CMSSY_CORE_VERSION}`;
|
|
155
155
|
|
|
156
156
|
// src/content/content-client.ts
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cmssy/core",
|
|
3
|
-
"version": "19.
|
|
3
|
+
"version": "19.16.0",
|
|
4
4
|
"description": "Framework-agnostic cmssy gateway: GraphQL client, block/field system, editor protocol. No React, no Next.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cmssy",
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
"vitest": "^2.1.0"
|
|
88
88
|
},
|
|
89
89
|
"dependencies": {
|
|
90
|
-
"@cmssy/types": "0.
|
|
90
|
+
"@cmssy/types": "0.67.0",
|
|
91
91
|
"jose": "^6.2.3"
|
|
92
92
|
},
|
|
93
93
|
"scripts": {
|