@ankhorage/templates 1.2.22 → 1.2.23
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/CHANGELOG.md +6 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/templates/shared/create-manifest-shell.d.ts +2 -1
- package/dist/templates/shared/create-manifest-shell.d.ts.map +1 -1
- package/dist/templates/shared/create-manifest-shell.js +2 -0
- package/dist/templates/shared/create-manifest-shell.js.map +1 -1
- package/dist/templates/shared/splash-screen.d.ts +19 -0
- package/dist/templates/shared/splash-screen.d.ts.map +1 -0
- package/dist/templates/shared/splash-screen.js +19 -0
- package/dist/templates/shared/splash-screen.js.map +1 -0
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { createCategoryAppManifest } from './generators/create-category-app';
|
|
2
2
|
export { CATEGORY_PRESETS, type CategoryPreset } from './presets/category-presets';
|
|
3
|
+
export type { TemplateSplashScreenSpec } from './templates/shared/splash-screen';
|
|
3
4
|
export { type CategoryStarterTemplateDefinition, createStarterTemplate, listStarterTemplates, listStarterTemplatesByCategory, listStarterTemplateSummaries, resolveStarterTemplate, type StarterTemplateFactory, type StarterTemplateId, type StarterTemplateOptions, type StarterTemplateSelection, type StarterTemplateSummary, TEMPLATE_KINDS, type TemplateKind, type TemplateSeed, } from './templates/starter';
|
|
4
5
|
export { APP_CATEGORIES, type AppCategory } from '@ankhorage/contracts';
|
|
5
6
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,kCAAkC,CAAC;AAC7E,OAAO,EAAE,gBAAgB,EAAE,KAAK,cAAc,EAAE,MAAM,4BAA4B,CAAC;AACnF,OAAO,EACL,KAAK,iCAAiC,EACtC,qBAAqB,EACrB,oBAAoB,EACpB,8BAA8B,EAC9B,4BAA4B,EAC5B,sBAAsB,EACtB,KAAK,sBAAsB,EAC3B,KAAK,iBAAiB,EACtB,KAAK,sBAAsB,EAC3B,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,cAAc,EACd,KAAK,YAAY,EACjB,KAAK,YAAY,GAClB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,cAAc,EAAE,KAAK,WAAW,EAAE,MAAM,sBAAsB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,kCAAkC,CAAC;AAC7E,OAAO,EAAE,gBAAgB,EAAE,KAAK,cAAc,EAAE,MAAM,4BAA4B,CAAC;AACnF,YAAY,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AACjF,OAAO,EACL,KAAK,iCAAiC,EACtC,qBAAqB,EACrB,oBAAoB,EACpB,8BAA8B,EAC9B,4BAA4B,EAC5B,sBAAsB,EACtB,KAAK,sBAAsB,EAC3B,KAAK,iBAAiB,EACtB,KAAK,sBAAsB,EAC3B,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,cAAc,EACd,KAAK,YAAY,EACjB,KAAK,YAAY,GAClB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,cAAc,EAAE,KAAK,WAAW,EAAE,MAAM,sBAAsB,CAAC"}
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,kCAAkC,CAAC;AAC7E,OAAO,EAAE,gBAAgB,EAAuB,MAAM,4BAA4B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,kCAAkC,CAAC;AAC7E,OAAO,EAAE,gBAAgB,EAAuB,MAAM,4BAA4B,CAAC;AAEnF,OAAO,EAEL,qBAAqB,EACrB,oBAAoB,EACpB,8BAA8B,EAC9B,4BAA4B,EAC5B,sBAAsB,EAMtB,cAAc,GAGf,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,cAAc,EAAoB,MAAM,sBAAsB,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { AppManifest, ThemeConfig } from '@ankhorage/contracts';
|
|
2
|
+
import { type AppManifestWithSplashScreen } from './splash-screen';
|
|
2
3
|
interface ManifestShellSeed {
|
|
3
4
|
appName: string;
|
|
4
5
|
slug: string;
|
|
@@ -9,6 +10,6 @@ export declare function createManifestShell(args: {
|
|
|
9
10
|
version: string;
|
|
10
11
|
navigator: AppManifest['navigator'];
|
|
11
12
|
screens: AppManifest['screens'];
|
|
12
|
-
}):
|
|
13
|
+
}): AppManifestWithSplashScreen;
|
|
13
14
|
export {};
|
|
14
15
|
//# sourceMappingURL=create-manifest-shell.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-manifest-shell.d.ts","sourceRoot":"","sources":["../../../src/templates/shared/create-manifest-shell.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"create-manifest-shell.d.ts","sourceRoot":"","sources":["../../../src/templates/shared/create-manifest-shell.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAGrE,OAAO,EAAsB,KAAK,2BAA2B,EAAE,MAAM,iBAAiB,CAAC;AAEvF,UAAU,iBAAiB;IACzB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;CACd;AAED,wBAAgB,mBAAmB,CAAC,IAAI,EAAE;IACxC,IAAI,EAAE,iBAAiB,CAAC;IACxB,KAAK,EAAE,WAAW,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,WAAW,CAAC,WAAW,CAAC,CAAC;IACpC,OAAO,EAAE,WAAW,CAAC,SAAS,CAAC,CAAC;CACjC,GAAG,2BAA2B,CAgB9B"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { BASE_INFRA, BASE_SETTINGS } from '../../internal/defaults';
|
|
2
|
+
import { createSplashScreen } from './splash-screen';
|
|
2
3
|
export function createManifestShell(args) {
|
|
3
4
|
return {
|
|
4
5
|
metadata: {
|
|
@@ -9,6 +10,7 @@ export function createManifestShell(args) {
|
|
|
9
10
|
},
|
|
10
11
|
themes: [args.theme],
|
|
11
12
|
activeThemeId: args.theme.id,
|
|
13
|
+
splashScreen: createSplashScreen(args.theme),
|
|
12
14
|
infra: structuredClone(BASE_INFRA),
|
|
13
15
|
settings: structuredClone(BASE_SETTINGS),
|
|
14
16
|
navigator: args.navigator,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-manifest-shell.js","sourceRoot":"","sources":["../../../src/templates/shared/create-manifest-shell.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;
|
|
1
|
+
{"version":3,"file":"create-manifest-shell.js","sourceRoot":"","sources":["../../../src/templates/shared/create-manifest-shell.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAoC,MAAM,iBAAiB,CAAC;AAOvF,MAAM,UAAU,mBAAmB,CAAC,IAMnC;IACC,OAAO;QACL,QAAQ,EAAE;YACR,IAAI,EAAE,IAAI,CAAC,IAAI,CAAC,OAAO;YACvB,IAAI,EAAE,IAAI,CAAC,IAAI,CAAC,IAAI;YACpB,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,OAAO,EAAE,IAAI,CAAC,KAAK,CAAC,EAAE;SACvB;QACD,MAAM,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC;QACpB,aAAa,EAAE,IAAI,CAAC,KAAK,CAAC,EAAE;QAC5B,YAAY,EAAE,kBAAkB,CAAC,IAAI,CAAC,KAAK,CAAC;QAC5C,KAAK,EAAE,eAAe,CAAC,UAAU,CAAC;QAClC,QAAQ,EAAE,eAAe,CAAC,aAAa,CAAC;QACxC,SAAS,EAAE,IAAI,CAAC,SAAS;QACzB,OAAO,EAAE,IAAI,CAAC,OAAO;KACtB,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { AppManifest, ThemeConfig } from '@ankhorage/contracts';
|
|
2
|
+
type TemplateSplashScreenResizeMode = 'contain' | 'cover' | 'native';
|
|
3
|
+
interface TemplateSplashScreenAssetSpec {
|
|
4
|
+
readonly image?: string;
|
|
5
|
+
readonly imageWidth?: number;
|
|
6
|
+
readonly resizeMode?: TemplateSplashScreenResizeMode;
|
|
7
|
+
}
|
|
8
|
+
export interface TemplateSplashScreenSpec extends TemplateSplashScreenAssetSpec {
|
|
9
|
+
readonly backgroundColor?: string;
|
|
10
|
+
readonly dark?: TemplateSplashScreenAssetSpec & {
|
|
11
|
+
readonly backgroundColor?: string;
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
export type AppManifestWithSplashScreen = AppManifest & {
|
|
15
|
+
readonly splashScreen: TemplateSplashScreenSpec;
|
|
16
|
+
};
|
|
17
|
+
export declare function createSplashScreen(theme: ThemeConfig): TemplateSplashScreenSpec;
|
|
18
|
+
export {};
|
|
19
|
+
//# sourceMappingURL=splash-screen.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"splash-screen.d.ts","sourceRoot":"","sources":["../../../src/templates/shared/splash-screen.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAErE,KAAK,8BAA8B,GAAG,SAAS,GAAG,OAAO,GAAG,QAAQ,CAAC;AAErE,UAAU,6BAA6B;IACrC,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,UAAU,CAAC,EAAE,8BAA8B,CAAC;CACtD;AAED,MAAM,WAAW,wBAAyB,SAAQ,6BAA6B;IAC7E,QAAQ,CAAC,eAAe,CAAC,EAAE,MAAM,CAAC;IAClC,QAAQ,CAAC,IAAI,CAAC,EAAE,6BAA6B,GAAG;QAC9C,QAAQ,CAAC,eAAe,CAAC,EAAE,MAAM,CAAC;KACnC,CAAC;CACH;AAED,MAAM,MAAM,2BAA2B,GAAG,WAAW,GAAG;IACtD,QAAQ,CAAC,YAAY,EAAE,wBAAwB,CAAC;CACjD,CAAC;AAOF,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,WAAW,GAAG,wBAAwB,CAa/E"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
const DEFAULT_SPLASH_IMAGE = './assets/splash/icon.png';
|
|
2
|
+
const DEFAULT_DARK_SPLASH_IMAGE = './assets/splash/icon-dark.png';
|
|
3
|
+
const DEFAULT_SPLASH_IMAGE_WIDTH = 160;
|
|
4
|
+
const DEFAULT_SPLASH_RESIZE_MODE = 'contain';
|
|
5
|
+
export function createSplashScreen(theme) {
|
|
6
|
+
return {
|
|
7
|
+
backgroundColor: theme.light.primaryColor,
|
|
8
|
+
image: DEFAULT_SPLASH_IMAGE,
|
|
9
|
+
imageWidth: DEFAULT_SPLASH_IMAGE_WIDTH,
|
|
10
|
+
resizeMode: DEFAULT_SPLASH_RESIZE_MODE,
|
|
11
|
+
dark: {
|
|
12
|
+
backgroundColor: theme.dark.primaryColor,
|
|
13
|
+
image: DEFAULT_DARK_SPLASH_IMAGE,
|
|
14
|
+
imageWidth: DEFAULT_SPLASH_IMAGE_WIDTH,
|
|
15
|
+
resizeMode: DEFAULT_SPLASH_RESIZE_MODE,
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
//# sourceMappingURL=splash-screen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"splash-screen.js","sourceRoot":"","sources":["../../../src/templates/shared/splash-screen.ts"],"names":[],"mappings":"AAqBA,MAAM,oBAAoB,GAAG,0BAA0B,CAAC;AACxD,MAAM,yBAAyB,GAAG,+BAA+B,CAAC;AAClE,MAAM,0BAA0B,GAAG,GAAG,CAAC;AACvC,MAAM,0BAA0B,GAAG,SAAkD,CAAC;AAEtF,MAAM,UAAU,kBAAkB,CAAC,KAAkB;IACnD,OAAO;QACL,eAAe,EAAE,KAAK,CAAC,KAAK,CAAC,YAAY;QACzC,KAAK,EAAE,oBAAoB;QAC3B,UAAU,EAAE,0BAA0B;QACtC,UAAU,EAAE,0BAA0B;QACtC,IAAI,EAAE;YACJ,eAAe,EAAE,KAAK,CAAC,IAAI,CAAC,YAAY;YACxC,KAAK,EAAE,yBAAyB;YAChC,UAAU,EAAE,0BAA0B;YACtC,UAAU,EAAE,0BAA0B;SACvC;KACF,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ankhorage/templates",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.23",
|
|
4
4
|
"description": "Reusable Ankhorage app templates, presets, and manifest generators.",
|
|
5
5
|
"homepage": "https://github.com/ankhorage/templates#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -51,8 +51,8 @@
|
|
|
51
51
|
"version-packages": "changeset version"
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
|
-
"@ankhorage/contracts": "^1.
|
|
55
|
-
"@ankhorage/zora": "^2.
|
|
54
|
+
"@ankhorage/contracts": "^1.13.0",
|
|
55
|
+
"@ankhorage/zora": "^2.6.0"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"@ankhorage/devtools": "^1.0.6",
|