@adminide-stack/clock-tik-browser 12.0.28 → 12.0.29-alpha.1
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/lib/compute.js +26 -13
- package/lib/pages/CategoryCollection/index.d.ts +4 -0
- package/lib/pages/CategoryCollection/index.d.ts.map +1 -1
- package/lib/pages/CategoryCollection/index.js +4 -2
- package/lib/pages/CategoryCollection/index.js.map +1 -1
- package/lib/pages/Contact-us/index.d.ts +2 -0
- package/lib/pages/Contact-us/index.d.ts.map +1 -1
- package/lib/pages/Contact-us/index.js +5 -6
- package/lib/pages/Contact-us/index.js.map +1 -1
- package/lib/pages/Demo/index.d.ts +2 -0
- package/lib/pages/Demo/index.d.ts.map +1 -1
- package/lib/pages/Demo/index.js +4 -5
- package/lib/pages/Demo/index.js.map +1 -1
- package/lib/pages/Feedback/index.d.ts +2 -0
- package/lib/pages/Feedback/index.d.ts.map +1 -1
- package/lib/pages/Feedback/index.js +5 -6
- package/lib/pages/Feedback/index.js.map +1 -1
- package/lib/pages/Freelancers/index.d.ts +2 -0
- package/lib/pages/Freelancers/index.d.ts.map +1 -1
- package/lib/pages/Freelancers/index.js +4 -2
- package/lib/pages/Freelancers/index.js.map +1 -1
- package/lib/pages/GetStarted/index.d.ts +2 -0
- package/lib/pages/GetStarted/index.d.ts.map +1 -1
- package/lib/pages/GetStarted/index.js +4 -2
- package/lib/pages/GetStarted/index.js.map +1 -1
- package/lib/pages/HelpCenter/index.d.ts +2 -0
- package/lib/pages/HelpCenter/index.d.ts.map +1 -1
- package/lib/pages/HelpCenter/index.js +4 -2
- package/lib/pages/HelpCenter/index.js.map +1 -1
- package/lib/pages/Home/assets.js +1 -3
- package/lib/pages/Home/assets.js.map +1 -1
- package/lib/pages/Home/index.d.ts +3 -3
- package/lib/pages/Home/index.d.ts.map +1 -1
- package/lib/pages/Home/index.js +7 -4
- package/lib/pages/Home/index.js.map +1 -1
- package/lib/pages/LandingPage/index.d.ts +2 -0
- package/lib/pages/LandingPage/index.d.ts.map +1 -1
- package/lib/pages/LandingPage/index.js +4 -2
- package/lib/pages/LandingPage/index.js.map +1 -1
- package/lib/pages/Pricing/index.d.ts +2 -0
- package/lib/pages/Pricing/index.d.ts.map +1 -1
- package/lib/pages/Pricing/index.js +4 -5
- package/lib/pages/Pricing/index.js.map +1 -1
- package/lib/pages/Privacy/index.d.ts +2 -0
- package/lib/pages/Privacy/index.d.ts.map +1 -1
- package/lib/pages/Privacy/index.js +4 -5
- package/lib/pages/Privacy/index.js.map +1 -1
- package/lib/pages/ProductLandingPage/index.d.ts +4 -0
- package/lib/pages/ProductLandingPage/index.d.ts.map +1 -1
- package/lib/pages/ProductLandingPage/index.js +4 -5
- package/lib/pages/ProductLandingPage/index.js.map +1 -1
- package/lib/pages/Products/index.d.ts +2 -0
- package/lib/pages/Products/index.d.ts.map +1 -1
- package/lib/pages/Products/index.js +4 -2
- package/lib/pages/Products/index.js.map +1 -1
- package/lib/pages/Thanks/index.d.ts +2 -0
- package/lib/pages/Thanks/index.d.ts.map +1 -1
- package/lib/pages/Thanks/index.js +4 -5
- package/lib/pages/Thanks/index.js.map +1 -1
- package/lib/routes.json +26 -13
- package/lib/seo/__tests__/seo.test.d.ts +2 -0
- package/lib/seo/__tests__/seo.test.d.ts.map +1 -0
- package/lib/seo/businessMeta.d.ts +29 -0
- package/lib/seo/businessMeta.d.ts.map +1 -0
- package/lib/seo/businessMeta.js +199 -0
- package/lib/seo/businessMeta.js.map +1 -0
- package/lib/seo/crawlFiles.d.ts +19 -0
- package/lib/seo/crawlFiles.d.ts.map +1 -0
- package/lib/seo/crawlFiles.js +23 -0
- package/lib/seo/crawlFiles.js.map +1 -0
- package/lib/seo/pageMeta.d.ts +41 -0
- package/lib/seo/pageMeta.d.ts.map +1 -0
- package/lib/seo/pageMeta.js +116 -0
- package/lib/seo/pageMeta.js.map +1 -0
- package/lib/seo/publicPages.d.ts +31 -0
- package/lib/seo/publicPages.d.ts.map +1 -0
- package/lib/seo/publicPages.js +85 -0
- package/lib/seo/publicPages.js.map +1 -0
- package/lib/seo/site.d.ts +46 -0
- package/lib/seo/site.d.ts.map +1 -0
- package/lib/seo/site.js +55 -0
- package/lib/seo/site.js.map +1 -0
- package/lib/templates/static/brand/apple-touch-icon.png +0 -0
- package/lib/templates/static/brand/clockbook-logo-512.png +0 -0
- package/lib/templates/static/brand/favicon-32.png +0 -0
- package/lib/templates/static/brand/icon-192.png +0 -0
- package/lib/templates/static/brand/icon-512.png +0 -0
- package/lib/templates/static/brand/icon-maskable-512.png +0 -0
- package/lib/templates/static/brand/site.webmanifest +15 -0
- package/package.json +5 -5
|
@@ -0,0 +1,199 @@
|
|
|
1
|
+
import {PRODUCT_CATALOG}from'../pages/productCatalog.js';import {pageMeta}from'./pageMeta.js';import {SITE}from'./site.js';/**
|
|
2
|
+
* `meta` for every /business page, in one place so titles and descriptions can be reviewed
|
|
3
|
+
* side by side. Each page module re-exports its entry as `meta` (the route build picks the
|
|
4
|
+
* export up from the page module).
|
|
5
|
+
*
|
|
6
|
+
* Positioning: clockbook.com itself (pages/Home) is Clockbook for everyone - an AI that saves
|
|
7
|
+
* time on life admin. Clockbook Business, under /business, is timesheets and HRM; the
|
|
8
|
+
* search copy here leads with that, and the rest of the catalog is secondary.
|
|
9
|
+
*/
|
|
10
|
+
const B = SITE.businessBase;
|
|
11
|
+
const BUSINESS = {
|
|
12
|
+
name: 'Clockbook Business',
|
|
13
|
+
path: B
|
|
14
|
+
};
|
|
15
|
+
const PRODUCTS = {
|
|
16
|
+
name: 'Products',
|
|
17
|
+
path: `${B}/products`
|
|
18
|
+
};
|
|
19
|
+
const HELP_CENTER = {
|
|
20
|
+
name: 'Help Center',
|
|
21
|
+
path: `${B}/help-center`
|
|
22
|
+
};
|
|
23
|
+
/** Cut a description to `max` characters on a word boundary. */
|
|
24
|
+
function clampDescription(text, max = 160) {
|
|
25
|
+
const clean = text.replace(/\s+/g, ' ').trim();
|
|
26
|
+
if (clean.length <= max) return clean;
|
|
27
|
+
const cut = clean.slice(0, max - 1);
|
|
28
|
+
return `${cut.slice(0, cut.lastIndexOf(' ')).replace(/[\s,;:.]+$/, '')}…`;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Search titles for the Clockbook Business core (SITE.businessCoreProducts), written for what
|
|
32
|
+
* people search for; every other product uses its catalog name and badge.
|
|
33
|
+
*/
|
|
34
|
+
const CORE_PRODUCT_TITLES = {
|
|
35
|
+
'time-tracker': 'Time Tracking and Timesheet Software | Clockbook Business',
|
|
36
|
+
hrm: 'HRM: Employee Records, Time Off and Onboarding | Clockbook',
|
|
37
|
+
payroll: 'Payroll Software: Runs, Approvals and Pay Schedules | Clockbook'
|
|
38
|
+
};
|
|
39
|
+
/** The help-center categories (folders under templates/content). */
|
|
40
|
+
const HELP_CATEGORIES = {
|
|
41
|
+
blog: {
|
|
42
|
+
name: 'Blog',
|
|
43
|
+
title: 'Clockbook Blog: Timesheets, Time Tracking and HR Guides',
|
|
44
|
+
description: 'Guides from the Clockbook team on timesheets, time tracking, leave, expenses and HR for small businesses and teams.'
|
|
45
|
+
},
|
|
46
|
+
docs: {
|
|
47
|
+
name: 'Docs',
|
|
48
|
+
title: 'Clockbook Business Docs: Timesheet and HRM How-To Guides',
|
|
49
|
+
description: 'Step-by-step help for Clockbook Business: tracking time, timesheets, projects and clients, invoicing, reports, HRM and team settings.'
|
|
50
|
+
}
|
|
51
|
+
};
|
|
52
|
+
const businessMeta = {
|
|
53
|
+
landing: () => pageMeta({
|
|
54
|
+
path: B,
|
|
55
|
+
title: 'Clockbook Business: Timesheets, Time Tracking and HRM',
|
|
56
|
+
socialTitle: 'Clockbook Business',
|
|
57
|
+
description: 'Track time from anywhere, approve timesheets, and manage employee records, time off and onboarding in one place with Clockbook Business.',
|
|
58
|
+
crumbName: BUSINESS.name
|
|
59
|
+
}),
|
|
60
|
+
products: () => pageMeta({
|
|
61
|
+
path: PRODUCTS.path,
|
|
62
|
+
title: 'Products | Clockbook Business',
|
|
63
|
+
description: 'Time Tracker and HRM at the core of Clockbook Business, with payroll, expenses, billing and more products for running your team.',
|
|
64
|
+
pageType: 'CollectionPage',
|
|
65
|
+
breadcrumbs: [BUSINESS],
|
|
66
|
+
crumbName: PRODUCTS.name
|
|
67
|
+
}),
|
|
68
|
+
product: ({
|
|
69
|
+
params
|
|
70
|
+
} = {}) => {
|
|
71
|
+
const slug = params?.slug ?? '';
|
|
72
|
+
const product = PRODUCT_CATALOG[slug];
|
|
73
|
+
const path = `${PRODUCTS.path}/${slug}`;
|
|
74
|
+
if (!product) {
|
|
75
|
+
// Unknown slugs render the default product page; keep that copy out of search.
|
|
76
|
+
return pageMeta({
|
|
77
|
+
path,
|
|
78
|
+
title: 'Product not found | Clockbook',
|
|
79
|
+
description: 'This Clockbook product does not exist. See all products for the full list.',
|
|
80
|
+
indexable: false,
|
|
81
|
+
breadcrumbs: [BUSINESS, PRODUCTS]
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
return pageMeta({
|
|
85
|
+
path,
|
|
86
|
+
title: CORE_PRODUCT_TITLES[slug] ?? `${product.name}: ${product.badge} | Clockbook Business`,
|
|
87
|
+
socialTitle: `Clockbook ${product.name}`,
|
|
88
|
+
description: clampDescription(product.subtitle),
|
|
89
|
+
breadcrumbs: [BUSINESS, PRODUCTS],
|
|
90
|
+
crumbName: product.name,
|
|
91
|
+
jsonLd: [{
|
|
92
|
+
'@type': 'SoftwareApplication',
|
|
93
|
+
name: `Clockbook ${product.name}`,
|
|
94
|
+
applicationCategory: 'BusinessApplication',
|
|
95
|
+
operatingSystem: 'Web',
|
|
96
|
+
description: clampDescription(product.overview, 300),
|
|
97
|
+
featureList: product.features,
|
|
98
|
+
url: `${SITE.origin}${path}`,
|
|
99
|
+
publisher: {
|
|
100
|
+
'@type': 'Organization',
|
|
101
|
+
name: SITE.name,
|
|
102
|
+
url: `${SITE.origin}/`
|
|
103
|
+
}
|
|
104
|
+
}]
|
|
105
|
+
});
|
|
106
|
+
},
|
|
107
|
+
pricing: () => pageMeta({
|
|
108
|
+
path: `${B}/pricing`,
|
|
109
|
+
title: 'Clockbook Business Pricing: Timesheets and HRM, One Price',
|
|
110
|
+
socialTitle: 'Clockbook Business Pricing',
|
|
111
|
+
description: 'Start free and scale when you are ready. No ads, no data resale, no lock-in: you pay only for the software your team actually uses.',
|
|
112
|
+
breadcrumbs: [BUSINESS],
|
|
113
|
+
crumbName: 'Pricing'
|
|
114
|
+
}),
|
|
115
|
+
freelancers: () => pageMeta({
|
|
116
|
+
path: `${B}/freelancers`,
|
|
117
|
+
title: 'Hire Freelancers and AI Agents in One Place | Clockbook',
|
|
118
|
+
description: 'Bring on expert freelancers and autonomous AI agents side by side, or find verified projects that match your skills, schedule and goals.',
|
|
119
|
+
breadcrumbs: [BUSINESS],
|
|
120
|
+
crumbName: 'Freelancers'
|
|
121
|
+
}),
|
|
122
|
+
getStarted: () => pageMeta({
|
|
123
|
+
path: `${B}/get-started`,
|
|
124
|
+
title: 'Getting Started with Clockbook Business',
|
|
125
|
+
description: 'Everything you need to know to start using Clockbook Business for timesheets, time tracking and HR.',
|
|
126
|
+
breadcrumbs: [BUSINESS],
|
|
127
|
+
crumbName: 'Getting Started'
|
|
128
|
+
}),
|
|
129
|
+
helpCenter: () => pageMeta({
|
|
130
|
+
path: HELP_CENTER.path,
|
|
131
|
+
title: 'Clockbook Help Center: Timesheet and HRM Guides and Support',
|
|
132
|
+
description: 'How-to guides for timesheets, time tracking, projects, invoicing and HRM, plus Clockbook support plans with priority assistance.',
|
|
133
|
+
breadcrumbs: [BUSINESS],
|
|
134
|
+
crumbName: HELP_CENTER.name
|
|
135
|
+
}),
|
|
136
|
+
helpCategory: ({
|
|
137
|
+
params
|
|
138
|
+
} = {}) => {
|
|
139
|
+
const categoryId = params?.categoryId ?? '';
|
|
140
|
+
const category = HELP_CATEGORIES[categoryId];
|
|
141
|
+
const path = `${HELP_CENTER.path}/${categoryId}`;
|
|
142
|
+
if (!category) {
|
|
143
|
+
return pageMeta({
|
|
144
|
+
path,
|
|
145
|
+
title: 'Category not found | Clockbook Help Center',
|
|
146
|
+
description: 'This help-center category does not exist. Browse the Clockbook Help Center instead.',
|
|
147
|
+
indexable: false,
|
|
148
|
+
breadcrumbs: [BUSINESS, HELP_CENTER]
|
|
149
|
+
});
|
|
150
|
+
}
|
|
151
|
+
return pageMeta({
|
|
152
|
+
path,
|
|
153
|
+
title: category.title,
|
|
154
|
+
socialTitle: `Clockbook ${category.name}`,
|
|
155
|
+
description: category.description,
|
|
156
|
+
pageType: 'CollectionPage',
|
|
157
|
+
breadcrumbs: [BUSINESS, HELP_CENTER],
|
|
158
|
+
crumbName: category.name
|
|
159
|
+
});
|
|
160
|
+
},
|
|
161
|
+
privacy: () => pageMeta({
|
|
162
|
+
path: `${B}/privacy`,
|
|
163
|
+
title: 'Privacy Notice | Clockbook',
|
|
164
|
+
description: 'How Clockbook collects, uses and protects your personal information, and the choices and rights you have over it.',
|
|
165
|
+
breadcrumbs: [BUSINESS],
|
|
166
|
+
crumbName: 'Privacy Notice'
|
|
167
|
+
}),
|
|
168
|
+
contactUs: () => pageMeta({
|
|
169
|
+
path: `${B}/contact-us`,
|
|
170
|
+
title: 'Contact Us | Clockbook',
|
|
171
|
+
description: 'Have a question or need help? Send the Clockbook team a message and we will get back to you.',
|
|
172
|
+
pageType: 'ContactPage',
|
|
173
|
+
breadcrumbs: [BUSINESS],
|
|
174
|
+
crumbName: 'Contact Us'
|
|
175
|
+
}),
|
|
176
|
+
demo: () => pageMeta({
|
|
177
|
+
path: `${B}/demo`,
|
|
178
|
+
title: 'Watch the Clockbook Business Demo',
|
|
179
|
+
description: 'Watch the Clockbook Business demo and see how your team can track time, run timesheets and manage HR in one place.',
|
|
180
|
+
breadcrumbs: [BUSINESS],
|
|
181
|
+
crumbName: 'Demo'
|
|
182
|
+
}),
|
|
183
|
+
feedback: () => pageMeta({
|
|
184
|
+
path: `${B}/feedback`,
|
|
185
|
+
title: 'Feedback | Clockbook',
|
|
186
|
+
description: 'Missing a feature in Clockbook, or have an improvement in mind? Send us your feedback.',
|
|
187
|
+
indexable: false,
|
|
188
|
+
breadcrumbs: [BUSINESS],
|
|
189
|
+
crumbName: 'Feedback'
|
|
190
|
+
}),
|
|
191
|
+
thanks: () => pageMeta({
|
|
192
|
+
path: `${B}/thanks`,
|
|
193
|
+
title: 'Thanks | Clockbook',
|
|
194
|
+
description: 'Thanks for reaching out to Clockbook.',
|
|
195
|
+
indexable: false,
|
|
196
|
+
breadcrumbs: [BUSINESS],
|
|
197
|
+
crumbName: 'Thanks'
|
|
198
|
+
})
|
|
199
|
+
};export{HELP_CATEGORIES,businessMeta,clampDescription};//# sourceMappingURL=businessMeta.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"businessMeta.js","sources":["../../src/seo/businessMeta.ts"],"sourcesContent":[null],"names":[],"mappings":"2HAKA;;;;;;;;AAQG;AAEH,MAAM,CAAC,GAAG,IAAI,CAAC,YAAY;AAC3B,MAAM,QAAQ,GAAU;AACxB,EAAA,IAAM,EAAQ,oBAAkB;AAChC,EAAA,IAAM,EAAW;AAIjB,CAAgE;AAChE,MAAM,WAA0B;AAC5B,EAAA,IAAA,EAAA,UAAc;AACd,EAAA,IAAA,EAAI,CAAK,EAAA,CAAA,CAAA,SAAO;AAAS,CAAA;AACzB,MAAA,WAAiB,GAAA;MACV,EAAA,aAAO;AAClB,EAAC,IAAA,EAAA,CAAA,EAAA,CAAA,CAAA,YAAA;AAED,CAAA;;;AAGG,EAAA,MAAA,KAAA,GAAA,IAAA,CAAA,OAAA,CAAA,MAAA,EAAA,GAAA,CAAA,CAAA,IAAA,EAAA;AACH,EAAA,IAAM,mBAAmB,EAA2B,OAAA,KAAA;AAChD,EAAA,MAAA,GAAA,GAAA,MAAgB,KAA2D,CAAA,CAAA,EAAA,GAAA,GAAA,CAAA,CAAA;AAC3E,EAAA,OAAK,CAA4D,EAAA,GAAA,CAAA,KAAA,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;AACvB,MAAA,UAA+B,gBAAA;AAC/B,MAAA,WAAA,EAAW,SAAgG,EAAA,WAAA,CAAA;AAC3G,MAAA,SAAA,UAAuB,CAAA;;AAEvB,GAAA;SACF,EAAA,MAAA,QAAA,CAAA;AACN,IAAA,IAAI,EAAE,CAAA,EAAqB,CAAE,CAAA,SACjB;SACA,EAAA,4BAAa;AACjB,IAAA,WAAO,EAAmC,mHAAA;AAC1C,IAAA,WAAA,EAAA,CAAA,QACwH,CAAA;aAC7G,EAAA;AACX,GAAA,CAAA;WACF,EAAA,MAAA,QAAA,CAAA;AACN,IAAA,IAAA,EAAA,CAAA,EAAU,CAAA,CAAA;SAEE,EAAA,wBAAiB;AACrB,IAAA,WAAO,EAAsB,8FAAA;AAC7B,IAAA,QAAA,EAAA,aAAqG;AACrG,IAAA,WAAA,EAAS,SAAO,CAAA;aACL,EAAA;AACX,GAAA,CAAA;MACF,EAAA,MAAA,QAAA,CAAA;AACN,IAAA,IAAA,EAAM,CAAE,EAAA,CAAA,CAAqB;SAEjB,EAAA,mCAAe;AACnB,IAAA,WAAO,EAAoB,oHAAA;AAC3B,IAAA,WAAA,EAAA,CAAA,QAAoD,CAAA;AACpD,IAAA,SAAA,EAAA;;AAEA,EAAA,QAAA,EAAA,cAAmB,CAAA;QACrB,EAAA,CAAA,EAAA,CAAA,CAAA,SAAA,CAAA;IACR,KAAA,EAAA,sBAAA;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { publicPages, type HelpCenterManifest, type PublicPage } from './publicPages';
|
|
2
|
+
/**
|
|
3
|
+
* Bodies of `/robots.txt` and `/sitemap.xml`, served by the help server
|
|
4
|
+
* (servers/frontend-help-server/crawl-files.js). Pure functions of the page registry and the
|
|
5
|
+
* deployment, so the output is unit-testable. Built as its own rollup input so the server can
|
|
6
|
+
* import lib/seo/crawlFiles.js without the React app.
|
|
7
|
+
*/
|
|
8
|
+
export type { HelpCenterManifest, PublicPage };
|
|
9
|
+
export { publicPages };
|
|
10
|
+
export { isIndexableDeployment } from './site';
|
|
11
|
+
/**
|
|
12
|
+
* Static files that must not compete with the pages built from them: the raw markdown and
|
|
13
|
+
* manifest behind the help center (served from /content) and the locale bundles.
|
|
14
|
+
*/
|
|
15
|
+
export declare const CRAWL_DISALLOWED_PREFIXES: readonly string[];
|
|
16
|
+
export declare function robotsTxt(indexable: boolean): string;
|
|
17
|
+
/** Sitemap of the given pages on the production origin. */
|
|
18
|
+
export declare function sitemapXml(pages: readonly PublicPage[]): string;
|
|
19
|
+
//# sourceMappingURL=crawlFiles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"crawlFiles.d.ts","sourceRoot":"","sources":["../../src/seo/crawlFiles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,KAAK,kBAAkB,EAAE,KAAK,UAAU,EAAE,MAAM,eAAe,CAAC;AAGtF;;;;;GAKG;AAEH,YAAY,EAAE,kBAAkB,EAAE,UAAU,EAAE,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,CAAC;AACvB,OAAO,EAAE,qBAAqB,EAAE,MAAM,QAAQ,CAAC;AAE/C;;;GAGG;AACH,eAAO,MAAM,yBAAyB,EAAE,SAAS,MAAM,EAAgD,CAAC;AAWxG,wBAAgB,SAAS,CAAC,SAAS,EAAE,OAAO,GAAG,MAAM,CAapD;AAED,2DAA2D;AAC3D,wBAAgB,UAAU,CAAC,KAAK,EAAE,SAAS,UAAU,EAAE,GAAG,MAAM,CAkB/D"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export{publicPages}from'./publicPages.js';import {absoluteUrl,SITE}from'./site.js';export{isIndexableDeployment}from'./site.js';/**
|
|
2
|
+
* Static files that must not compete with the pages built from them: the raw markdown and
|
|
3
|
+
* manifest behind the help center (served from /content) and the locale bundles.
|
|
4
|
+
*/
|
|
5
|
+
const CRAWL_DISALLOWED_PREFIXES = ['/content/', '/cdm-locales/', '/workers/'];
|
|
6
|
+
function escapeXml(value) {
|
|
7
|
+
return value.replace(/&/g, '&').replace(/</g, '<').replace(/>/g, '>').replace(/"/g, '"').replace(/'/g, ''');
|
|
8
|
+
}
|
|
9
|
+
function robotsTxt(indexable) {
|
|
10
|
+
if (!indexable) {
|
|
11
|
+
// Dev / stage: nothing here should compete with clockbook.com in search results.
|
|
12
|
+
return 'User-agent: *\nDisallow: /\n';
|
|
13
|
+
}
|
|
14
|
+
return ['User-agent: *', 'Allow: /', ...CRAWL_DISALLOWED_PREFIXES.map(prefix => `Disallow: ${prefix}`), '', `Sitemap: ${absoluteUrl('/sitemap.xml', SITE.origin)}`, ''].join('\n');
|
|
15
|
+
}
|
|
16
|
+
/** Sitemap of the given pages on the production origin. */
|
|
17
|
+
function sitemapXml(pages) {
|
|
18
|
+
const urls = pages.map(page => {
|
|
19
|
+
const lastmod = page.lastModified ? `\n <lastmod>${page.lastModified}</lastmod>` : '';
|
|
20
|
+
return [' <url>', ` <loc>${escapeXml(absoluteUrl(page.path, SITE.origin))}</loc>${lastmod}`, ` <changefreq>${page.changeFrequency}</changefreq>`, ` <priority>${page.priority.toFixed(1)}</priority>`, ' </url>'].join('\n');
|
|
21
|
+
});
|
|
22
|
+
return ['<?xml version="1.0" encoding="UTF-8"?>', '<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">', ...urls, '</urlset>', ''].join('\n');
|
|
23
|
+
}export{CRAWL_DISALLOWED_PREFIXES,robotsTxt,sitemapXml};//# sourceMappingURL=crawlFiles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"crawlFiles.js","sources":["../../src/seo/crawlFiles.ts"],"sourcesContent":[null],"names":[],"mappings":"gIAcA;;;AAGG;AACU,MAAA,yBAAyB,GAAsB,CAAC,WAAW,EAAE,eAAe,EAAE,WAAW;AAEtG,SAAS,SAAS,CAAC,KAAa,EAAA;AAC5B,EAAA,OAAA,KAAY,CAAA,OAAA,CAAA,IAAA,EAAA,OAAA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
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import type { MetaDescriptor } from '@remix-run/react';
|
|
2
|
+
/**
|
|
3
|
+
* Remix `meta` for a public page: title, description, canonical, robots, Open Graph, X card
|
|
4
|
+
* and a JSON-LD graph (WebPage + BreadcrumbList + any page-specific nodes). Server-rendered,
|
|
5
|
+
* so search engines and link previews read it without running the app.
|
|
6
|
+
*/
|
|
7
|
+
export interface Crumb {
|
|
8
|
+
name: string;
|
|
9
|
+
path: string;
|
|
10
|
+
}
|
|
11
|
+
export interface PageMetaInput {
|
|
12
|
+
/** Canonical path on the public site, e.g. `/business/pricing`. */
|
|
13
|
+
path: string;
|
|
14
|
+
/** Full <title>; keep it under ~60 characters. */
|
|
15
|
+
title: string;
|
|
16
|
+
/** Meta description; keep it under ~160 characters. */
|
|
17
|
+
description: string;
|
|
18
|
+
/** Shorter title for link previews; defaults to `title`. */
|
|
19
|
+
socialTitle?: string;
|
|
20
|
+
image?: {
|
|
21
|
+
path: string;
|
|
22
|
+
width: number;
|
|
23
|
+
height: number;
|
|
24
|
+
alt: string;
|
|
25
|
+
};
|
|
26
|
+
type?: 'website' | 'article';
|
|
27
|
+
/** false: `noindex` (thank-you pages, unknown slugs). Non-production is always `noindex`. */
|
|
28
|
+
indexable?: boolean;
|
|
29
|
+
/** Trail below Home; the page itself is appended last as `crumbName`. */
|
|
30
|
+
breadcrumbs?: Crumb[];
|
|
31
|
+
/** The page's own breadcrumb label (default `socialTitle`). */
|
|
32
|
+
crumbName?: string;
|
|
33
|
+
/** schema.org type of the page node (default `WebPage`). */
|
|
34
|
+
pageType?: string;
|
|
35
|
+
/** Extra JSON-LD nodes for this page (a product, an FAQ, ...). */
|
|
36
|
+
jsonLd?: Array<Record<string, unknown>>;
|
|
37
|
+
}
|
|
38
|
+
/** The robots directive for this deployment: only production is indexed. */
|
|
39
|
+
export declare function robotsContent(indexable?: boolean, clientUrl?: string | undefined): string;
|
|
40
|
+
export declare function pageMeta(input: PageMetaInput, clientUrl?: string | undefined): MetaDescriptor[];
|
|
41
|
+
//# sourceMappingURL=pageMeta.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pageMeta.d.ts","sourceRoot":"","sources":["../../src/seo/pageMeta.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAIvD;;;;GAIG;AAEH,MAAM,WAAW,KAAK;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,aAAa;IAC1B,mEAAmE;IACnE,IAAI,EAAE,MAAM,CAAC;IACb,kDAAkD;IAClD,KAAK,EAAE,MAAM,CAAC;IACd,uDAAuD;IACvD,WAAW,EAAE,MAAM,CAAC;IACpB,4DAA4D;IAC5D,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC;QAAC,GAAG,EAAE,MAAM,CAAA;KAAE,CAAC;IACrE,IAAI,CAAC,EAAE,SAAS,GAAG,SAAS,CAAC;IAC7B,6FAA6F;IAC7F,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,yEAAyE;IACzE,WAAW,CAAC,EAAE,KAAK,EAAE,CAAC;IACtB,+DAA+D;IAC/D,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,4DAA4D;IAC5D,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,kEAAkE;IAClE,MAAM,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;CAC3C;AAKD,4EAA4E;AAC5E,wBAAgB,aAAa,CAAC,SAAS,UAAO,EAAE,SAAS,GAAE,MAAM,GAAG,SAA6B,GAAG,MAAM,CAEzG;AAED,wBAAgB,QAAQ,CAAC,KAAK,EAAE,aAAa,EAAE,SAAS,GAAE,MAAM,GAAG,SAA6B,GAAG,cAAc,EAAE,CA6DlH"}
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import {config}from'../config/env-config.js';import {siteOrigin,absoluteUrl,SITE,isIndexableDeployment}from'./site.js';const INDEX_ROBOTS = 'index, follow, max-image-preview:large, max-snippet:-1, max-video-preview:-1';
|
|
2
|
+
const NOINDEX_ROBOTS = 'noindex, follow';
|
|
3
|
+
/** The robots directive for this deployment: only production is indexed. */
|
|
4
|
+
function robotsContent(indexable = true, clientUrl = config.CLIENT_URL) {
|
|
5
|
+
return indexable && isIndexableDeployment(clientUrl) ? INDEX_ROBOTS : NOINDEX_ROBOTS;
|
|
6
|
+
}
|
|
7
|
+
function pageMeta(input, clientUrl = config.CLIENT_URL) {
|
|
8
|
+
const site = siteOrigin(clientUrl);
|
|
9
|
+
const url = absoluteUrl(input.path, site);
|
|
10
|
+
const image = input.image ?? SITE.ogImage;
|
|
11
|
+
const imageUrl = absoluteUrl(image.path, site);
|
|
12
|
+
const socialTitle = input.socialTitle ?? input.title;
|
|
13
|
+
const crumbs = [{
|
|
14
|
+
name: SITE.name,
|
|
15
|
+
path: '/'
|
|
16
|
+
}, ...(input.breadcrumbs ?? [])];
|
|
17
|
+
if (input.path !== '/') crumbs.push({
|
|
18
|
+
name: input.crumbName ?? socialTitle,
|
|
19
|
+
path: input.path
|
|
20
|
+
});
|
|
21
|
+
const graph = [{
|
|
22
|
+
'@type': input.pageType ?? 'WebPage',
|
|
23
|
+
'@id': `${url}#webpage`,
|
|
24
|
+
url,
|
|
25
|
+
name: input.title,
|
|
26
|
+
description: input.description,
|
|
27
|
+
inLanguage: SITE.language,
|
|
28
|
+
isPartOf: {
|
|
29
|
+
'@id': `${site}/#website`
|
|
30
|
+
},
|
|
31
|
+
primaryImageOfPage: {
|
|
32
|
+
'@type': 'ImageObject',
|
|
33
|
+
url: imageUrl
|
|
34
|
+
},
|
|
35
|
+
...(crumbs.length > 1 ? {
|
|
36
|
+
breadcrumb: {
|
|
37
|
+
'@id': `${url}#breadcrumb`
|
|
38
|
+
}
|
|
39
|
+
} : {})
|
|
40
|
+
}, ...(crumbs.length > 1 ? [{
|
|
41
|
+
'@type': 'BreadcrumbList',
|
|
42
|
+
'@id': `${url}#breadcrumb`,
|
|
43
|
+
itemListElement: crumbs.map((crumb, index) => ({
|
|
44
|
+
'@type': 'ListItem',
|
|
45
|
+
position: index + 1,
|
|
46
|
+
name: crumb.name,
|
|
47
|
+
item: absoluteUrl(crumb.path, site)
|
|
48
|
+
}))
|
|
49
|
+
}] : []), ...(input.jsonLd ?? [])];
|
|
50
|
+
return [{
|
|
51
|
+
title: input.title
|
|
52
|
+
}, {
|
|
53
|
+
name: 'description',
|
|
54
|
+
content: input.description
|
|
55
|
+
}, {
|
|
56
|
+
name: 'robots',
|
|
57
|
+
content: robotsContent(input.indexable ?? true, clientUrl)
|
|
58
|
+
}, {
|
|
59
|
+
tagName: 'link',
|
|
60
|
+
rel: 'canonical',
|
|
61
|
+
href: url
|
|
62
|
+
}, {
|
|
63
|
+
property: 'og:type',
|
|
64
|
+
content: input.type ?? 'website'
|
|
65
|
+
}, {
|
|
66
|
+
property: 'og:site_name',
|
|
67
|
+
content: SITE.name
|
|
68
|
+
}, {
|
|
69
|
+
property: 'og:locale',
|
|
70
|
+
content: SITE.locale
|
|
71
|
+
}, {
|
|
72
|
+
property: 'og:title',
|
|
73
|
+
content: socialTitle
|
|
74
|
+
}, {
|
|
75
|
+
property: 'og:description',
|
|
76
|
+
content: input.description
|
|
77
|
+
}, {
|
|
78
|
+
property: 'og:url',
|
|
79
|
+
content: url
|
|
80
|
+
}, {
|
|
81
|
+
property: 'og:image',
|
|
82
|
+
content: imageUrl
|
|
83
|
+
}, {
|
|
84
|
+
property: 'og:image:width',
|
|
85
|
+
content: String(image.width)
|
|
86
|
+
}, {
|
|
87
|
+
property: 'og:image:height',
|
|
88
|
+
content: String(image.height)
|
|
89
|
+
}, {
|
|
90
|
+
property: 'og:image:alt',
|
|
91
|
+
content: image.alt
|
|
92
|
+
}, {
|
|
93
|
+
name: 'twitter:card',
|
|
94
|
+
content: 'summary_large_image'
|
|
95
|
+
}, {
|
|
96
|
+
name: 'twitter:site',
|
|
97
|
+
content: SITE.xHandle
|
|
98
|
+
}, {
|
|
99
|
+
name: 'twitter:title',
|
|
100
|
+
content: socialTitle
|
|
101
|
+
}, {
|
|
102
|
+
name: 'twitter:description',
|
|
103
|
+
content: input.description
|
|
104
|
+
}, {
|
|
105
|
+
name: 'twitter:image',
|
|
106
|
+
content: imageUrl
|
|
107
|
+
}, {
|
|
108
|
+
name: 'twitter:image:alt',
|
|
109
|
+
content: image.alt
|
|
110
|
+
}, {
|
|
111
|
+
'script:ld+json': {
|
|
112
|
+
'@context': 'https://schema.org',
|
|
113
|
+
'@graph': graph
|
|
114
|
+
}
|
|
115
|
+
}];
|
|
116
|
+
}export{pageMeta,robotsContent};//# sourceMappingURL=pageMeta.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pageMeta.js","sources":["../../src/seo/pageMeta.ts"],"sourcesContent":[null],"names":[],"mappings":"uHAsCA,MAAM,YAAY,GAAG,8EAA8E;AACnG,MAAM,cAAc,GAAG,iBAAiB;AAExC;AACM,SAAU,aAAa,CAAC,SAAS,GAAG,IAAI,EAAE,SAAA,GAAgC,MAAM,CAAC,UAAU,EAAA;AAC7F,EAAA,OAAA,SAAgB,IAAA,qBAAyB,CAAA,aAAY,YAAc,GAAC;AACxE;AAEM,SAAU,QAAQ,CAAC,KAAoB,EAAE,SAAgC,GAAA,MAAM,CAAC,UAAU,EAAA;AAC5F,EAAA,MAAA,OAAa,UAAA,CAAA,SAAW,CAAA;QAClB,GAAA,GAAM,WAAA,CAAA,KAAY,CAAA,IAAU,EAAA,IAAM,CAAA;QAClC,KAAA,QAAa,CAAA,SAAU,IAAA,CAAA,OAAK;QAC5B,QAAA,GAAW,WAAA,CAAA,KAAY,CAAA,IAAU,EAAA,IAAM,C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AAC5B,IAAA,cAAU,CAAE;AACZ,GAAA,EAAA;AACA,IAAA,IAAA,EAAE,QAAQ;AACV,IAAA,OAAU,EAAA,aAAmB,CAAA,KAAA,CAAA,SAAS,IAAA,IAAQ,EAAA,SAAO;;AAErD,IAAA,eAAQ;SACN,WAAoB;AACtB,IAAA,IAAA,EAAE;;AAEF,IAAA,UAAM,SAAE;WACN,EAAA,KAAyB,CAAA,IAAA,IAAA;;YAE7B,EAAA,cAAA;AACN,IAAC,OAAA,EAAA,IAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Every page clockbook.com wants in search, for sitemap.xml. Pages that must stay out
|
|
3
|
+
* (/business/thanks, /business/feedback) are left off here and answer `noindex`.
|
|
4
|
+
*
|
|
5
|
+
* Pure: the help server imports it from lib/ (via crawlFiles) and passes in the help-center
|
|
6
|
+
* manifest it read from public/content at startup.
|
|
7
|
+
*/
|
|
8
|
+
export type ChangeFrequency = 'daily' | 'weekly' | 'monthly' | 'yearly';
|
|
9
|
+
export interface PublicPage {
|
|
10
|
+
path: string;
|
|
11
|
+
changeFrequency: ChangeFrequency;
|
|
12
|
+
priority: number;
|
|
13
|
+
/** YYYY-MM-DD, only when the page really carries a date (dated blog posts). */
|
|
14
|
+
lastModified?: string;
|
|
15
|
+
}
|
|
16
|
+
/** The slice of templates/content/content-manifest.json the sitemap needs. */
|
|
17
|
+
export interface HelpCenterManifest {
|
|
18
|
+
categories?: Record<string, {
|
|
19
|
+
articles?: Array<{
|
|
20
|
+
slug?: string;
|
|
21
|
+
}>;
|
|
22
|
+
}>;
|
|
23
|
+
}
|
|
24
|
+
export declare const STATIC_PUBLIC_PAGES: readonly PublicPage[];
|
|
25
|
+
/** Product pages; the Clockbook Business core (timesheets, HRM, payroll) ranks first. */
|
|
26
|
+
export declare function productPages(): PublicPage[];
|
|
27
|
+
/** Help-center categories and their articles, at the URLs the site links to. */
|
|
28
|
+
export declare function helpCenterPages(manifest: HelpCenterManifest | null | undefined): PublicPage[];
|
|
29
|
+
/** All public pages, deduplicated by path in registry order. */
|
|
30
|
+
export declare function publicPages(manifest?: HelpCenterManifest | null): PublicPage[];
|
|
31
|
+
//# sourceMappingURL=publicPages.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"publicPages.d.ts","sourceRoot":"","sources":["../../src/seo/publicPages.ts"],"names":[],"mappings":"AAGA;;;;;;GAMG;AAEH,MAAM,MAAM,eAAe,GAAG,OAAO,GAAG,QAAQ,GAAG,SAAS,GAAG,QAAQ,CAAC;AAExE,MAAM,WAAW,UAAU;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,eAAe,EAAE,eAAe,CAAC;IACjC,QAAQ,EAAE,MAAM,CAAC;IACjB,+EAA+E;IAC/E,YAAY,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,8EAA8E;AAC9E,MAAM,WAAW,kBAAkB;IAC/B,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE;QAAE,QAAQ,CAAC,EAAE,KAAK,CAAC;YAAE,IAAI,CAAC,EAAE,MAAM,CAAA;SAAE,CAAC,CAAA;KAAE,CAAC,CAAC;CACxE;AAID,eAAO,MAAM,mBAAmB,EAAE,SAAS,UAAU,EAWpD,CAAC;AAEF,yFAAyF;AACzF,wBAAgB,YAAY,IAAI,UAAU,EAAE,CAS3C;AAID,gFAAgF;AAChF,wBAAgB,eAAe,CAAC,QAAQ,EAAE,kBAAkB,GAAG,IAAI,GAAG,SAAS,GAAG,UAAU,EAAE,CAgB7F;AAED,gEAAgE;AAChE,wBAAgB,WAAW,CAAC,QAAQ,CAAC,EAAE,kBAAkB,GAAG,IAAI,GAAG,UAAU,EAAE,CAO9E"}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import {PRODUCT_CATALOG}from'../pages/productCatalog.js';import {SITE}from'./site.js';const B = SITE.businessBase;
|
|
2
|
+
const STATIC_PUBLIC_PAGES = [{
|
|
3
|
+
path: '/',
|
|
4
|
+
changeFrequency: 'weekly',
|
|
5
|
+
priority: 1
|
|
6
|
+
}, {
|
|
7
|
+
path: B,
|
|
8
|
+
changeFrequency: 'weekly',
|
|
9
|
+
priority: 0.9
|
|
10
|
+
}, {
|
|
11
|
+
path: `${B}/pricing`,
|
|
12
|
+
changeFrequency: 'monthly',
|
|
13
|
+
priority: 0.9
|
|
14
|
+
}, {
|
|
15
|
+
path: `${B}/products`,
|
|
16
|
+
changeFrequency: 'monthly',
|
|
17
|
+
priority: 0.8
|
|
18
|
+
}, {
|
|
19
|
+
path: `${B}/help-center`,
|
|
20
|
+
changeFrequency: 'weekly',
|
|
21
|
+
priority: 0.7
|
|
22
|
+
}, {
|
|
23
|
+
path: `${B}/freelancers`,
|
|
24
|
+
changeFrequency: 'monthly',
|
|
25
|
+
priority: 0.6
|
|
26
|
+
}, {
|
|
27
|
+
path: `${B}/get-started`,
|
|
28
|
+
changeFrequency: 'monthly',
|
|
29
|
+
priority: 0.6
|
|
30
|
+
}, {
|
|
31
|
+
path: `${B}/demo`,
|
|
32
|
+
changeFrequency: 'monthly',
|
|
33
|
+
priority: 0.5
|
|
34
|
+
}, {
|
|
35
|
+
path: `${B}/contact-us`,
|
|
36
|
+
changeFrequency: 'yearly',
|
|
37
|
+
priority: 0.4
|
|
38
|
+
}, {
|
|
39
|
+
path: `${B}/privacy`,
|
|
40
|
+
changeFrequency: 'yearly',
|
|
41
|
+
priority: 0.3
|
|
42
|
+
}];
|
|
43
|
+
/** Product pages; the Clockbook Business core (timesheets, HRM, payroll) ranks first. */
|
|
44
|
+
function productPages() {
|
|
45
|
+
const core = SITE.businessCoreProducts;
|
|
46
|
+
return Object.keys(PRODUCT_CATALOG).sort((a, b) => Number(core.includes(b)) - Number(core.includes(a)) || a.localeCompare(b)).map(slug => ({
|
|
47
|
+
path: `${B}/products/${slug}`,
|
|
48
|
+
changeFrequency: 'monthly',
|
|
49
|
+
priority: core.includes(slug) ? 0.8 : 0.4
|
|
50
|
+
}));
|
|
51
|
+
}
|
|
52
|
+
const DATED_SLUG = /^(\d{4}-\d{2}-\d{2})-/;
|
|
53
|
+
/** Help-center categories and their articles, at the URLs the site links to. */
|
|
54
|
+
function helpCenterPages(manifest) {
|
|
55
|
+
const pages = [];
|
|
56
|
+
for (const [categoryId, category] of Object.entries(manifest?.categories ?? {})) {
|
|
57
|
+
pages.push({
|
|
58
|
+
path: `${B}/help-center/${categoryId}`,
|
|
59
|
+
changeFrequency: 'weekly',
|
|
60
|
+
priority: 0.6
|
|
61
|
+
});
|
|
62
|
+
const slugs = (category?.articles ?? []).map(article => article?.slug).filter(Boolean);
|
|
63
|
+
for (const slug of slugs) {
|
|
64
|
+
const date = DATED_SLUG.exec(slug)?.[1];
|
|
65
|
+
pages.push({
|
|
66
|
+
path: `${B}/help-center/${categoryId}/${slug}`,
|
|
67
|
+
changeFrequency: 'monthly',
|
|
68
|
+
priority: 0.5,
|
|
69
|
+
...(date ? {
|
|
70
|
+
lastModified: date
|
|
71
|
+
} : {})
|
|
72
|
+
});
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
return pages;
|
|
76
|
+
}
|
|
77
|
+
/** All public pages, deduplicated by path in registry order. */
|
|
78
|
+
function publicPages(manifest) {
|
|
79
|
+
const seen = new Set();
|
|
80
|
+
return [...STATIC_PUBLIC_PAGES, ...productPages(), ...helpCenterPages(manifest)].filter(page => {
|
|
81
|
+
if (seen.has(page.path)) return false;
|
|
82
|
+
seen.add(page.path);
|
|
83
|
+
return true;
|
|
84
|
+
});
|
|
85
|
+
}export{STATIC_PUBLIC_PAGES,helpCenterPages,productPages,publicPages};//# sourceMappingURL=publicPages.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"publicPages.js","sources":["../../src/seo/publicPages.ts"],"sourcesContent":[null],"names":[],"mappings":"sFA0BA,MAAM,CAAC,GAAG,IAAI,CAA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,CAAA,IAAO,CAAA,eAAc,CAAA,CAAA,IAAA,CAAA,CAAA,CAAA,EAAA,CAAA,KAAA,MAAA,CAAA,IAAA,CAAA,QAAA,CAAA,CAAA,CAAA,CAAA,GAAA,MAAA,CAAA,IAAA,CAAA,QAAA,CAAA,CAAA,CAAA,CAAA,IAAA,CAAA,CAAA,aAAA,CAAA,CAAA,CAAA,CAAA,CAAA,GAAA,CAAA,IAAA,KAAA;IAC/B,IAAO,EAAA,CAAA,IAAI,UAAmB,EAAA,IAAA,CAAA,CAAA;AAC1B,IAAA,eAAS,EAAI,SAAS;AAAG,IAAA,QAAA,EAAA,IAAA,CAAO,QAAM,CAAA,IAAA,CAAA,GAAA,GAAA,GAAA;AACtC,GAAA,CAAA,CAAA;AACA;AACJ,MAAE,UAAC,GAAA,uBAAA;AACP;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Brand facts the crawlable pages publish - in <title>/<meta>, Open Graph cards, JSON-LD and
|
|
3
|
+
* the sitemap. One place, so a search result, a link preview and the structured data behind
|
|
4
|
+
* them never disagree.
|
|
5
|
+
*
|
|
6
|
+
* Pure (no env, no React): the help server imports it from lib/ to build robots.txt and
|
|
7
|
+
* sitemap.xml, outside the Remix build.
|
|
8
|
+
*/
|
|
9
|
+
export declare const SITE: {
|
|
10
|
+
readonly name: "Clockbook";
|
|
11
|
+
/** Production origin. Only this origin may be indexed (see isIndexableDeployment). */
|
|
12
|
+
readonly origin: "https://clockbook.com";
|
|
13
|
+
readonly locale: "en_US";
|
|
14
|
+
readonly language: "en";
|
|
15
|
+
readonly xHandle: "@clockbook2";
|
|
16
|
+
readonly sameAs: readonly ["https://x.com/clockbook2", "https://www.linkedin.com/company/clockbook", "https://github.com/Clockbook-com"];
|
|
17
|
+
/**
|
|
18
|
+
* Clockbook Business lives under /business: timesheets and HRM. clockbook.com itself is
|
|
19
|
+
* Clockbook for everyone, an AI that saves time on life admin.
|
|
20
|
+
*/
|
|
21
|
+
readonly businessBase: "/business";
|
|
22
|
+
/** The Clockbook Business core; the sitemap ranks these above the rest of the catalog. */
|
|
23
|
+
readonly businessCoreProducts: readonly ["time-tracker", "hrm", "payroll"];
|
|
24
|
+
/** Who Clockbook is, for the Organization node search engines show in knowledge panels. */
|
|
25
|
+
readonly description: "Clockbook helps everyone save time with AI: hand over calls, bills, cancellations and chores. Clockbook Business runs timesheets, time tracking and HRM for teams.";
|
|
26
|
+
/** Link-preview card shared by every page that has no image of its own. */
|
|
27
|
+
readonly ogImage: {
|
|
28
|
+
readonly path: "/static/home/og-image.jpg";
|
|
29
|
+
readonly width: 720;
|
|
30
|
+
readonly height: 720;
|
|
31
|
+
readonly alt: "The Clockbook clock rewinds: 38 minutes back every day";
|
|
32
|
+
};
|
|
33
|
+
readonly logoPath: "/static/brand/clockbook-logo-512.png";
|
|
34
|
+
};
|
|
35
|
+
/** `https://clockbook.com` or the deployment's own public site, without a trailing slash. */
|
|
36
|
+
export declare function siteOrigin(clientUrl?: string): string;
|
|
37
|
+
/** Absolute URL for a site path on the given public origin. */
|
|
38
|
+
export declare function absoluteUrl(path: string, clientUrl?: string): string;
|
|
39
|
+
/**
|
|
40
|
+
* Whether this deployment is the public production site. Dev and stage run the same pages on
|
|
41
|
+
* other hosts, and a crawlable copy there competes with clockbook.com in search results, so
|
|
42
|
+
* everything but the production origin answers `noindex` and a disallow-all robots.txt.
|
|
43
|
+
* Decided from `CLIENT_URL` (this site's own public URL; `APP_URL` is the separate web app).
|
|
44
|
+
*/
|
|
45
|
+
export declare function isIndexableDeployment(clientUrl: string | undefined): boolean;
|
|
46
|
+
//# sourceMappingURL=site.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"site.d.ts","sourceRoot":"","sources":["../../src/seo/site.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,eAAO,MAAM,IAAI;;IAEb,sFAAsF;;;;;;IAUtF;;;OAGG;;IAEH,0FAA0F;;IAE1F,2FAA2F;;IAG3F,2EAA2E;;;;;;;;CAQrE,CAAC;AAEX,6FAA6F;AAC7F,wBAAgB,UAAU,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,CAErD;AAED,+DAA+D;AAC/D,wBAAgB,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,CAEpE;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,CAAC,SAAS,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAO5E"}
|