@brandlab-digital/site-core 0.1.0-alpha.19 → 0.1.0-alpha.3
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/analytics.d.ts +1 -30
- package/dist/analytics.d.ts.map +1 -1
- package/dist/analytics.js +0 -119
- package/dist/analytics.js.map +1 -1
- package/dist/contact.d.ts +30 -79
- package/dist/contact.d.ts.map +1 -1
- package/dist/contact.js +1 -189
- package/dist/contact.js.map +1 -1
- package/dist/metadata.d.ts.map +1 -1
- package/dist/metadata.js +1 -7
- package/dist/metadata.js.map +1 -1
- package/dist/sitemaps.d.ts +0 -13
- package/dist/sitemaps.d.ts.map +1 -1
- package/dist/sitemaps.js +0 -23
- package/dist/sitemaps.js.map +1 -1
- package/package.json +2 -16
- package/dist/geography.d.ts +0 -20
- package/dist/geography.d.ts.map +0 -1
- package/dist/geography.js +0 -6708
- package/dist/geography.js.map +0 -1
- package/dist/google-reviews.d.ts +0 -89
- package/dist/google-reviews.d.ts.map +0 -1
- package/dist/google-reviews.js +0 -131
- package/dist/google-reviews.js.map +0 -1
- package/dist/locations.d.ts +0 -169
- package/dist/locations.d.ts.map +0 -1
- package/dist/locations.js +0 -198
- package/dist/locations.js.map +0 -1
package/dist/sitemaps.d.ts
CHANGED
|
@@ -5,10 +5,6 @@ export interface SitemapEntry {
|
|
|
5
5
|
changeFrequency?: SitemapChangeFrequency;
|
|
6
6
|
priority?: number;
|
|
7
7
|
}
|
|
8
|
-
export interface SitemapChunk {
|
|
9
|
-
path: string;
|
|
10
|
-
entries: readonly SitemapEntry[];
|
|
11
|
-
}
|
|
12
8
|
export declare const SITEMAP_PRIORITY: {
|
|
13
9
|
readonly home: 1;
|
|
14
10
|
readonly service: 0.9;
|
|
@@ -46,15 +42,6 @@ export declare function serializeSitemap(entries: readonly SitemapEntry[]): stri
|
|
|
46
42
|
export declare function serializeSitemapIndex(paths: readonly string[], options: {
|
|
47
43
|
absoluteUrl: (path: string) => string;
|
|
48
44
|
}): string;
|
|
49
|
-
export declare function createSitemapChunks(entries: readonly SitemapEntry[], options: {
|
|
50
|
-
pathPrefix: string;
|
|
51
|
-
maxUrlsPerSitemap?: number;
|
|
52
|
-
}): SitemapChunk[];
|
|
53
|
-
export declare function filterSitemapIndexPaths(groups: readonly {
|
|
54
|
-
path: string;
|
|
55
|
-
entryCount: number;
|
|
56
|
-
includeWhenEmpty?: boolean;
|
|
57
|
-
}[]): string[];
|
|
58
45
|
export declare function shouldIndexSite(options: {
|
|
59
46
|
nodeEnv?: string;
|
|
60
47
|
vercelEnv?: string;
|
package/dist/sitemaps.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sitemaps.d.ts","sourceRoot":"","sources":["../src/sitemaps.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,sBAAsB,GAAG,QAAQ,GAAG,SAAS,GAAG,QAAQ,GAAG,OAAO,GAAG,OAAO,CAAA;AAExF,MAAM,WAAW,YAAY;IAC3B,GAAG,EAAE,MAAM,CAAA;IACX,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAC5B,eAAe,CAAC,EAAE,sBAAsB,CAAA;IACxC,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB;AAED,
|
|
1
|
+
{"version":3,"file":"sitemaps.d.ts","sourceRoot":"","sources":["../src/sitemaps.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,sBAAsB,GAAG,QAAQ,GAAG,SAAS,GAAG,QAAQ,GAAG,OAAO,GAAG,OAAO,CAAA;AAExF,MAAM,WAAW,YAAY;IAC3B,GAAG,EAAE,MAAM,CAAA;IACX,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAC5B,eAAe,CAAC,EAAE,sBAAsB,CAAA;IACxC,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB;AAED,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;CAiBnB,CAAA;AAEV,eAAO,MAAM,iBAAiB;;;;;;;;;CAS6B,CAAA;AAE3D,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAO/C;AAQD,wBAAgB,oBAAoB;;;EAKnC;AAED,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,SAAS,YAAY,EAAE,GAAG,MAAM,CA0BzE;AAED,wBAAgB,qBAAqB,CACnC,KAAK,EAAE,SAAS,MAAM,EAAE,EACxB,OAAO,EAAE;IAAE,WAAW,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,CAAA;CAAE,GACjD,MAAM,CAiBR;AAED,wBAAgB,eAAe,CAAC,OAAO,EAAE;IACvC,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,aAAa,CAAC,EAAE,MAAM,CAAA;CACvB,WAMA"}
|
package/dist/sitemaps.js
CHANGED
|
@@ -87,29 +87,6 @@ export function serializeSitemapIndex(paths, options) {
|
|
|
87
87
|
'</sitemapindex>',
|
|
88
88
|
].join('\n');
|
|
89
89
|
}
|
|
90
|
-
export function createSitemapChunks(entries, options) {
|
|
91
|
-
const maxUrlsPerSitemap = options.maxUrlsPerSitemap ?? 500;
|
|
92
|
-
if (!Number.isInteger(maxUrlsPerSitemap) || maxUrlsPerSitemap < 1 || maxUrlsPerSitemap > 50_000) {
|
|
93
|
-
throw new Error('maxUrlsPerSitemap must be an integer between 1 and 50000.');
|
|
94
|
-
}
|
|
95
|
-
const pathPrefix = options.pathPrefix.startsWith('/')
|
|
96
|
-
? options.pathPrefix
|
|
97
|
-
: `/${options.pathPrefix}`;
|
|
98
|
-
const normalizedPrefix = pathPrefix.replace(/\.xml$/, '');
|
|
99
|
-
const chunks = [];
|
|
100
|
-
for (let index = 0; index < entries.length; index += maxUrlsPerSitemap) {
|
|
101
|
-
chunks.push({
|
|
102
|
-
path: `${normalizedPrefix}-${chunks.length + 1}.xml`,
|
|
103
|
-
entries: entries.slice(index, index + maxUrlsPerSitemap),
|
|
104
|
-
});
|
|
105
|
-
}
|
|
106
|
-
return chunks;
|
|
107
|
-
}
|
|
108
|
-
export function filterSitemapIndexPaths(groups) {
|
|
109
|
-
return groups
|
|
110
|
-
.filter((group) => group.includeWhenEmpty || group.entryCount > 0)
|
|
111
|
-
.map((group) => group.path);
|
|
112
|
-
}
|
|
113
90
|
export function shouldIndexSite(options) {
|
|
114
91
|
const isProduction = options.vercelEnv === 'production' ||
|
|
115
92
|
(!options.vercelEnv && options.nodeEnv === 'production');
|
package/dist/sitemaps.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sitemaps.js","sourceRoot":"","sources":["../src/sitemaps.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"sitemaps.js","sourceRoot":"","sources":["../src/sitemaps.ts"],"names":[],"mappings":"AASA,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,IAAI,EAAE,GAAG;IACT,OAAO,EAAE,GAAG;IACZ,aAAa,EAAE,GAAG;IAClB,WAAW,EAAE,GAAG;IAChB,SAAS,EAAE,GAAG;IACd,aAAa,EAAE,GAAG;IAClB,eAAe,EAAE,GAAG;IACpB,QAAQ,EAAE,GAAG;IACb,KAAK,EAAE,GAAG;IACV,IAAI,EAAE,GAAG;IACT,SAAS,EAAE,GAAG;IACd,cAAc,EAAE,GAAG;IACnB,MAAM,EAAE,GAAG;IACX,OAAO,EAAE,GAAG;IACZ,KAAK,EAAE,GAAG;IACV,QAAQ,EAAE,GAAG;CACL,CAAA;AAEV,MAAM,CAAC,MAAM,iBAAiB,GAAG;IAC/B,IAAI,EAAE,SAAS;IACf,OAAO,EAAE,SAAS;IAClB,aAAa,EAAE,SAAS;IACxB,eAAe,EAAE,SAAS;IAC1B,IAAI,EAAE,QAAQ;IACd,QAAQ,EAAE,SAAS;IACnB,KAAK,EAAE,QAAQ;IACf,aAAa,EAAE,QAAQ;CACkC,CAAA;AAE3D,MAAM,UAAU,SAAS,CAAC,KAAa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I,CAAC,IAAI,CAAC,CAAA;IACf,CAAC,CAAC;SACD,IAAI,CAAC,IAAI,CAAC,CAAA;IAEb,OAAO;QACL,wCAAwC;QACxC,8DAA8D;QAC9D,IAAI;QACJ,WAAW;KACZ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;AACd,CAAC;AAED,MAAM,UAAU,qBAAqB,CACnC,KAAwB,EACxB,OAAkD;IAElD,MAAM,OAAO,GAAG,KAAK;SAClB,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CACZ;QACE,aAAa;QACb,YAAY,SAAS,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,QAAQ;QACxD,cAAc;KACf,CAAC,IAAI,CAAC,IAAI,CAAC,CACb;SACA,IAAI,CAAC,IAAI,CAAC,CAAA;IAEb,OAAO;QACL,wCAAwC;QACxC,oEAAoE;QACpE,OAAO;QACP,iBAAiB;KAClB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;AACd,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,OAI/B;IACC,MAAM,YAAY,GAChB,OAAO,CAAC,SAAS,KAAK,YAAY;QAClC,CAAC,CAAC,OAAO,CAAC,SAAS,IAAI,OAAO,CAAC,OAAO,KAAK,YAAY,CAAC,CAAA;IAE1D,OAAO,YAAY,IAAI,OAAO,CAAC,aAAa,KAAK,GAAG,CAAA;AACtD,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@brandlab-digital/site-core",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
3
|
+
"version": "0.1.0-alpha.3",
|
|
4
4
|
"private": false,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"sideEffects": false,
|
|
7
|
-
"files": [
|
|
8
|
-
"dist"
|
|
9
|
-
],
|
|
7
|
+
"files": ["dist"],
|
|
10
8
|
"scripts": {
|
|
11
9
|
"build": "tsc -p tsconfig.json",
|
|
12
10
|
"test": "vitest run",
|
|
@@ -40,18 +38,6 @@
|
|
|
40
38
|
"./analytics": {
|
|
41
39
|
"types": "./dist/analytics.d.ts",
|
|
42
40
|
"import": "./dist/analytics.js"
|
|
43
|
-
},
|
|
44
|
-
"./locations": {
|
|
45
|
-
"types": "./dist/locations.d.ts",
|
|
46
|
-
"import": "./dist/locations.js"
|
|
47
|
-
},
|
|
48
|
-
"./geography": {
|
|
49
|
-
"types": "./dist/geography.d.ts",
|
|
50
|
-
"import": "./dist/geography.js"
|
|
51
|
-
},
|
|
52
|
-
"./google-reviews": {
|
|
53
|
-
"types": "./dist/google-reviews.d.ts",
|
|
54
|
-
"import": "./dist/google-reviews.js"
|
|
55
41
|
}
|
|
56
42
|
}
|
|
57
43
|
}
|
package/dist/geography.d.ts
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Canonical Brandlab Sydney geography registry — generated from
|
|
3
|
-
* standards/registry/sydney-geography.json v1.5.0 (2026-07-10).
|
|
4
|
-
*
|
|
5
|
-
* Source of truth remains the JSON file in the Brandlab standards workspace;
|
|
6
|
-
* regenerate this module when the registry is corrected and version-bumped
|
|
7
|
-
* (Location Pages Standard §5.2). Projects subset this registry — they never
|
|
8
|
-
* invent regions. The normal suburbs collection contains only postcode-backed
|
|
9
|
-
* website candidates; nonSuburbLocalities retains excluded official geography
|
|
10
|
-
* for boundary and council completeness. Internal coverageGroups organise
|
|
11
|
-
* service coverage only and must never create routes, content, metadata,
|
|
12
|
-
* schema, sitemaps, or links.
|
|
13
|
-
*/
|
|
14
|
-
import type { GeographyRegistry, RegistryOfficialLocality } from './locations.js';
|
|
15
|
-
export declare const sydneyGeography: GeographyRegistry;
|
|
16
|
-
/** Postcode-backed candidates only; project page approval remains manual. */
|
|
17
|
-
export declare const sydneyWebsiteSuburbs: readonly import("./locations.js").RegistrySuburb[];
|
|
18
|
-
/** Complete official NSW locality inventory for spatial and council lookups. */
|
|
19
|
-
export declare const sydneyOfficialLocalities: readonly RegistryOfficialLocality[];
|
|
20
|
-
//# sourceMappingURL=geography.d.ts.map
|
package/dist/geography.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"geography.d.ts","sourceRoot":"","sources":["../src/geography.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,OAAO,KAAK,EAAE,iBAAiB,EAAE,wBAAwB,EAAE,MAAM,gBAAgB,CAAA;AAEjF,eAAO,MAAM,eAAe,EAAE,iBA2iN7B,CAAA;AAED,6EAA6E;AAC7E,eAAO,MAAM,oBAAoB,oDAA0B,CAAA;AAE3D,gFAAgF;AAChF,eAAO,MAAM,wBAAwB,EAAE,SAAS,wBAAwB,EAG1B,CAAA"}
|