@akanjs/cli 1.0.19 → 2.1.0-rc.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/guidelines/componentRule/componentRule.generate.json +37 -0
- package/guidelines/componentRule/componentRule.instruction.md +28 -0
- package/guidelines/cssRule/cssRule.generate.json +37 -0
- package/guidelines/cssRule/cssRule.instruction.md +28 -0
- package/guidelines/docPageRule/docPageRule.generate.json +37 -0
- package/guidelines/docPageRule/docPageRule.instruction.md +25 -0
- package/guidelines/docSyncRule/docSyncRule.generate.json +37 -0
- package/guidelines/docSyncRule/docSyncRule.instruction.md +25 -0
- package/guidelines/enumConstant/enumConstant.generate.json +37 -0
- package/guidelines/enumConstant/enumConstant.instruction.md +28 -0
- package/guidelines/fieldRule/fieldRule.generate.json +37 -0
- package/guidelines/fieldRule/fieldRule.instruction.md +31 -0
- package/guidelines/framework/framework.generate.json +37 -0
- package/guidelines/framework/framework.instruction.md +29 -0
- package/guidelines/modelConstant/modelConstant.generate.json +37 -0
- package/guidelines/modelConstant/modelConstant.instruction.md +30 -0
- package/guidelines/modelDictionary/modelDictionary.generate.json +37 -0
- package/guidelines/modelDictionary/modelDictionary.instruction.md +30 -0
- package/guidelines/modelDocument/modelDocument.generate.json +37 -0
- package/guidelines/modelDocument/modelDocument.instruction.md +29 -0
- package/guidelines/modelService/modelService.generate.json +37 -0
- package/guidelines/modelService/modelService.instruction.md +28 -0
- package/guidelines/modelSignal/modelSignal.generate.json +37 -0
- package/guidelines/modelSignal/modelSignal.instruction.md +28 -0
- package/guidelines/modelStore/modelStore.generate.json +37 -0
- package/guidelines/modelStore/modelStore.instruction.md +28 -0
- package/guidelines/modelTemplate/modelTemplate.generate.json +37 -0
- package/guidelines/modelTemplate/modelTemplate.instruction.md +25 -0
- package/guidelines/modelUnit/modelUnit.generate.json +37 -0
- package/guidelines/modelUnit/modelUnit.instruction.md +25 -0
- package/guidelines/modelUtil/modelUtil.generate.json +37 -0
- package/guidelines/modelUtil/modelUtil.instruction.md +25 -0
- package/guidelines/modelView/modelView.generate.json +37 -0
- package/guidelines/modelView/modelView.instruction.md +25 -0
- package/guidelines/modelZone/modelZone.generate.json +37 -0
- package/guidelines/modelZone/modelZone.instruction.md +25 -0
- package/guidelines/moduleCodegen/moduleCodegen.generate.json +37 -0
- package/guidelines/moduleCodegen/moduleCodegen.instruction.md +28 -0
- package/guidelines/moduleOverview/moduleOverview.generate.json +37 -0
- package/guidelines/moduleOverview/moduleOverview.instruction.md +31 -0
- package/guidelines/scalarConstant/scalarConstant.generate.json +37 -0
- package/guidelines/scalarConstant/scalarConstant.instruction.md +28 -0
- package/guidelines/scalarDictionary/scalarDictionary.generate.json +37 -0
- package/guidelines/scalarDictionary/scalarDictionary.instruction.md +28 -0
- package/guidelines/scalarModule/scalarModule.generate.json +37 -0
- package/guidelines/scalarModule/scalarModule.instruction.md +29 -0
- package/guidelines/sharedUiUsage/sharedUiUsage.generate.json +37 -0
- package/guidelines/sharedUiUsage/sharedUiUsage.instruction.md +25 -0
- package/guidelines/utilUiUsage/utilUiUsage.generate.json +37 -0
- package/guidelines/utilUiUsage/utilUiUsage.instruction.md +25 -0
- package/index.js +11630 -0
- package/package.json +38 -56
- package/templates/__scalar/__model__/__model__.constant.ts +15 -0
- package/templates/__scalar/__model__/__model__.dictionary.ts +19 -0
- package/templates/__scalar/__model__/__model__.document.ts +15 -0
- package/templates/app/akan.config.ts +14 -0
- package/templates/app/env/env.client.debug.ts.template +7 -0
- package/templates/app/env/env.client.develop.ts.template +7 -0
- package/templates/app/env/env.client.local.ts.template +7 -0
- package/templates/app/env/env.client.main.ts.template +7 -0
- package/templates/app/env/env.client.testing.ts.template +7 -0
- package/{esm/src/templates/app/env/env.client.js → templates/app/env/env.client.ts} +7 -6
- package/templates/app/env/env.client.type.ts +16 -0
- package/{esm/src/templates/app/env/env.server.testing.ts.template → templates/app/env/env.server.debug.ts.template} +3 -2
- package/templates/app/env/env.server.develop.ts.template +7 -0
- package/templates/app/env/env.server.local.ts.template +7 -0
- package/templates/app/env/env.server.main.ts.template +7 -0
- package/{cjs/src/templates → templates}/app/env/env.server.testing.ts.template +0 -0
- package/{esm/src/templates/app/env/env.server.js → templates/app/env/env.server.ts} +7 -6
- package/templates/app/lib/___appName__/__appName__.dictionary.ts +17 -0
- package/templates/app/lib/___appName__/__appName__.service.ts +13 -0
- package/templates/app/lib/___appName__/__appName__.signal.ts +17 -0
- package/templates/app/lib/___appName__/__appName__.store.ts +17 -0
- package/templates/app/lib/option.ts +18 -0
- package/templates/app/main.ts +16 -0
- package/templates/app/page/_index.tsx +296 -0
- package/templates/app/page/_layout.tsx +31 -0
- package/templates/app/page/styles.css.template +53 -0
- package/templates/app/public/favicon.ico +0 -0
- package/templates/app/public/logo.png +0 -0
- package/{esm/src/templates → templates}/app/tsconfig.json.template +0 -1
- package/templates/client.ts +46 -0
- package/templates/crudPages/[__model__Id]/edit/page.tsx +47 -0
- package/templates/crudPages/[__model__Id]/page.tsx +52 -0
- package/templates/crudPages/new/page.tsx +42 -0
- package/templates/crudPages/page.tsx +43 -0
- package/templates/crudSinglePage/page.tsx +37 -0
- package/templates/env/_env.server.type.ts +16 -0
- package/templates/facetIndex/index.ts +33 -0
- package/templates/index.ts +10 -0
- package/templates/lib/__lib/lib.constant.ts +38 -0
- package/templates/lib/__lib/lib.dictionary.ts +33 -0
- package/templates/lib/__lib/lib.document.ts +35 -0
- package/templates/lib/__lib/lib.service.ts +33 -0
- package/templates/lib/__lib/lib.signal.ts +34 -0
- package/templates/lib/__lib/lib.store.ts +33 -0
- package/templates/lib/cnst.ts +29 -0
- package/templates/lib/db.ts +32 -0
- package/{esm/src/templates/lib/dict.js → templates/lib/dict.ts} +16 -16
- package/templates/lib/sig.ts +60 -0
- package/templates/lib/srv.ts +34 -0
- package/templates/lib/st.ts +31 -0
- package/templates/lib/useClient.ts +19 -0
- package/templates/lib/useServer.ts +7 -0
- package/templates/libRoot/akan.config.ts +12 -0
- package/templates/libRoot/base/baseLogic.ts +14 -0
- package/templates/libRoot/base/index.ts +8 -0
- package/templates/libRoot/common/commonLogic.ts +14 -0
- package/templates/libRoot/common/index.ts +8 -0
- package/{esm/src/templates/libRoot/lib/___libName__/__libName__.dictionary.js → templates/libRoot/lib/___libName__/__libName__.dictionary.ts} +6 -6
- package/templates/libRoot/lib/___libName__/__libName__.service.ts +13 -0
- package/templates/libRoot/lib/___libName__/__libName__.store.ts +15 -0
- package/templates/libRoot/lib/option.ts +18 -0
- package/templates/libRoot/srvkit/backendLogic.ts +13 -0
- package/templates/libRoot/srvkit/index.ts +8 -0
- package/templates/libRoot/ui/index.ts +8 -0
- package/templates/libRoot/webkit/frontendLogic.ts +13 -0
- package/templates/libRoot/webkit/index.ts +8 -0
- package/templates/localDev/docker-compose.yaml.template +37 -0
- package/{esm/src/templates/module/__Model__.Template.js → templates/module/__Model__.Template.tsx} +11 -8
- package/templates/module/__Model__.Unit.tsx +26 -0
- package/templates/module/__Model__.Util.tsx +30 -0
- package/{esm/src/templates/module/__Model__.View.js → templates/module/__Model__.View.tsx} +11 -8
- package/{esm/src/templates/module/__Model__.Zone.js → templates/module/__Model__.Zone.tsx} +15 -12
- package/{esm/src/templates/module/__model__.constant.js → templates/module/__model__.constant.ts} +9 -6
- package/{esm/src/templates/module/__model__.dictionary.js → templates/module/__model__.dictionary.ts} +12 -9
- package/templates/module/__model__.document.ts +23 -0
- package/templates/module/__model__.service.ts +16 -0
- package/{esm/src/templates/module/__model__.signal.js → templates/module/__model__.signal.ts} +10 -7
- package/templates/module/__model__.store.ts +21 -0
- package/templates/moduleRoot/index.tsx +31 -0
- package/{esm/src/templates/libRoot → templates/pkgRoot}/tsconfig.json.template +2 -3
- package/templates/server.ts +45 -0
- package/templates/service/__model__.dictionary.ts +19 -0
- package/templates/service/__model__.service.ts +13 -0
- package/templates/service/__model__.signal.ts +17 -0
- package/templates/service/__model__.store.ts +17 -0
- package/templates/workspaceRoot/.env.template +14 -0
- package/{cjs/src/templates → templates}/workspaceRoot/.gitignore.template +14 -13
- package/templates/workspaceRoot/.vscode/settings.json.template +23 -0
- package/templates/workspaceRoot/biome.json.template +191 -0
- package/templates/workspaceRoot/bunfig.toml +4 -0
- package/templates/workspaceRoot/package.json.template +7 -0
- package/templates/workspaceRoot/tsconfig.json.template +29 -0
- package/README.md +0 -301
- package/cjs/index.js +0 -7778
- package/cjs/src/guidelines/___library/sharedUiStructureDescription.en.md +0 -767
- package/cjs/src/guidelines/___library/utilUiStructureDescription.en.md +0 -395
- package/cjs/src/guidelines/___lint/lintRuleDescription.en.md +0 -64
- package/cjs/src/guidelines/___module/moduleStructureDescription.en.md +0 -80
- package/cjs/src/guidelines/componentRule/componentRule.generate.json +0 -131
- package/cjs/src/guidelines/componentRule/componentRule.instruction.md +0 -637
- package/cjs/src/guidelines/cssRule/cssRule.generate.json +0 -93
- package/cjs/src/guidelines/cssRule/cssRule.instruction.md +0 -435
- package/cjs/src/guidelines/databaseModule/databaseModule.generate.json +0 -51
- package/cjs/src/guidelines/databaseModule/databaseModule.instruction.md +0 -631
- package/cjs/src/guidelines/docPageRule/docPageRule.generate.json +0 -72
- package/cjs/src/guidelines/docPageRule/docPageRule.instruction.md +0 -389
- package/cjs/src/guidelines/enumConstant/enumConstant.generate.json +0 -24
- package/cjs/src/guidelines/enumConstant/enumConstant.instruction.md +0 -232
- package/cjs/src/guidelines/framework/framework.generate.json +0 -119
- package/cjs/src/guidelines/framework/framework.instruction.md +0 -1110
- package/cjs/src/guidelines/howToUseStore/howToUseStore.generate.json +0 -0
- package/cjs/src/guidelines/modelConstant/modelConstant.generate.json +0 -128
- package/cjs/src/guidelines/modelConstant/modelConstant.instruction.md +0 -506
- package/cjs/src/guidelines/modelDictionary/modelDictionary.generate.json +0 -108
- package/cjs/src/guidelines/modelDictionary/modelDictionary.instruction.md +0 -547
- package/cjs/src/guidelines/modelDocument/modelDocument.generate.json +0 -129
- package/cjs/src/guidelines/modelDocument/modelDocument.instruction.md +0 -659
- package/cjs/src/guidelines/modelService/modelService.generate.json +0 -135
- package/cjs/src/guidelines/modelService/modelService.instruction.md +0 -708
- package/cjs/src/guidelines/modelSignal/modelSignal.generate.json +0 -201
- package/cjs/src/guidelines/modelSignal/modelSignal.instruction.md +0 -552
- package/cjs/src/guidelines/modelStore/modelStore.generate.json +0 -130
- package/cjs/src/guidelines/modelStore/modelStore.instruction.md +0 -590
- package/cjs/src/guidelines/modelTemplate/modelTemplate.generate.json +0 -104
- package/cjs/src/guidelines/modelTemplate/modelTemplate.instruction.md +0 -604
- package/cjs/src/guidelines/modelUnit/modelUnit.generate.json +0 -92
- package/cjs/src/guidelines/modelUnit/modelUnit.instruction.md +0 -541
- package/cjs/src/guidelines/modelUtil/modelUtil.generate.json +0 -93
- package/cjs/src/guidelines/modelUtil/modelUtil.instruction.md +0 -752
- package/cjs/src/guidelines/modelView/modelView.generate.json +0 -80
- package/cjs/src/guidelines/modelView/modelView.instruction.md +0 -1005
- package/cjs/src/guidelines/modelZone/modelZone.generate.json +0 -126
- package/cjs/src/guidelines/modelZone/modelZone.instruction.md +0 -528
- package/cjs/src/guidelines/scalarConstant/scalarConstant.generate.json +0 -106
- package/cjs/src/guidelines/scalarConstant/scalarConstant.instruction.md +0 -442
- package/cjs/src/guidelines/scalarDictionary/scalarDictionary.generate.json +0 -83
- package/cjs/src/guidelines/scalarDictionary/scalarDictionary.instruction.md +0 -273
- package/cjs/src/guidelines/scalarModule/scalarModule.generate.json +0 -35
- package/cjs/src/guidelines/scalarModule/scalarModule.instruction.md +0 -81
- package/cjs/src/guidelines/sharedUiUsage/sharedUiUsage.generate.json +0 -108
- package/cjs/src/guidelines/sharedUiUsage/sharedUiUsage.instruction.md +0 -310
- package/cjs/src/guidelines/utilUiUsage/utilUiUsage.generate.json +0 -140
- package/cjs/src/guidelines/utilUiUsage/utilUiUsage.instruction.md +0 -339
- package/cjs/src/templates/__scalar/__model__/__model__.constant.js +0 -33
- package/cjs/src/templates/__scalar/__model__/__model__.dictionary.js +0 -37
- package/cjs/src/templates/__scalar/__model__/__model__.document.js +0 -33
- package/cjs/src/templates/app/akan.config.js +0 -33
- package/cjs/src/templates/app/app/[lang]/layout.js +0 -55
- package/cjs/src/templates/app/app/[lang]/page.js +0 -111
- package/cjs/src/templates/app/app/[lang]/styles.css.template +0 -20
- package/cjs/src/templates/app/app/csr.js +0 -36
- package/cjs/src/templates/app/app/index.html.template +0 -13
- package/cjs/src/templates/app/app/layout.js +0 -41
- package/cjs/src/templates/app/app/robots.js +0 -40
- package/cjs/src/templates/app/app/sitemap.js +0 -36
- package/cjs/src/templates/app/base/baseLogic.js +0 -35
- package/cjs/src/templates/app/base/index.js +0 -29
- package/cjs/src/templates/app/capacitor.config.ts.template +0 -8
- package/cjs/src/templates/app/common/commonLogic.js +0 -35
- package/cjs/src/templates/app/common/index.js +0 -29
- package/cjs/src/templates/app/env/env.client.debug.ts.template +0 -7
- package/cjs/src/templates/app/env/env.client.develop.ts.template +0 -7
- package/cjs/src/templates/app/env/env.client.js +0 -40
- package/cjs/src/templates/app/env/env.client.local.ts.template +0 -7
- package/cjs/src/templates/app/env/env.client.main.ts.template +0 -7
- package/cjs/src/templates/app/env/env.client.testing.ts.template +0 -7
- package/cjs/src/templates/app/env/env.client.type.js +0 -35
- package/cjs/src/templates/app/env/env.server.debug.ts.template +0 -10
- package/cjs/src/templates/app/env/env.server.develop.ts.template +0 -10
- package/cjs/src/templates/app/env/env.server.js +0 -39
- package/cjs/src/templates/app/env/env.server.local.ts.template +0 -10
- package/cjs/src/templates/app/env/env.server.main.ts.template +0 -10
- package/cjs/src/templates/app/instrumentation.js +0 -32
- package/cjs/src/templates/app/jest.config.js +0 -36
- package/cjs/src/templates/app/lib/___appName__/__appName__.dictionary.js +0 -35
- package/cjs/src/templates/app/lib/___appName__/__appName__.service.js +0 -31
- package/cjs/src/templates/app/lib/___appName__/__appName__.signal.js +0 -35
- package/cjs/src/templates/app/lib/___appName__/__appName__.store.js +0 -35
- package/cjs/src/templates/app/lib/option.js +0 -47
- package/cjs/src/templates/app/main.js +0 -39
- package/cjs/src/templates/app/nest/backendLogic.js +0 -34
- package/cjs/src/templates/app/nest/index.js +0 -29
- package/cjs/src/templates/app/next/frontendLogic.js +0 -34
- package/cjs/src/templates/app/next/index.js +0 -29
- package/cjs/src/templates/app/postcss.config.js.template +0 -8
- package/cjs/src/templates/app/proxy.js +0 -35
- package/cjs/src/templates/app/public/favicon.ico +0 -0
- package/cjs/src/templates/app/public/icons/icon-128x128.png +0 -0
- package/cjs/src/templates/app/public/icons/icon-144x144.png +0 -0
- package/cjs/src/templates/app/public/icons/icon-152x152.png +0 -0
- package/cjs/src/templates/app/public/icons/icon-192x192.png +0 -0
- package/cjs/src/templates/app/public/icons/icon-256x256.png +0 -0
- package/cjs/src/templates/app/public/icons/icon-384x384.png +0 -0
- package/cjs/src/templates/app/public/icons/icon-48x48.png +0 -0
- package/cjs/src/templates/app/public/icons/icon-512x512.png +0 -0
- package/cjs/src/templates/app/public/icons/icon-72x72.png +0 -0
- package/cjs/src/templates/app/public/icons/icon-96x96.png +0 -0
- package/cjs/src/templates/app/public/logo.svg +0 -70
- package/cjs/src/templates/app/public/manifest.json.template +0 -67
- package/cjs/src/templates/app/tsconfig.json.template +0 -22
- package/cjs/src/templates/app/tsconfig.spec.json.template +0 -7
- package/cjs/src/templates/app/ui/UiComponent.js +0 -38
- package/cjs/src/templates/app/ui/index.js +0 -29
- package/cjs/src/templates/client.js +0 -47
- package/cjs/src/templates/crudPages/[__model__Id]/edit/page.js +0 -72
- package/cjs/src/templates/crudPages/[__model__Id]/page.js +0 -78
- package/cjs/src/templates/crudPages/new/page.js +0 -67
- package/cjs/src/templates/crudPages/page.js +0 -68
- package/cjs/src/templates/crudSinglePage/page.js +0 -62
- package/cjs/src/templates/env/_env.server.type.js +0 -39
- package/cjs/src/templates/index.js +0 -29
- package/cjs/src/templates/lib/__lib/lib.constant.js +0 -57
- package/cjs/src/templates/lib/__lib/lib.dictionary.js +0 -50
- package/cjs/src/templates/lib/__lib/lib.document.js +0 -52
- package/cjs/src/templates/lib/__lib/lib.service.js +0 -59
- package/cjs/src/templates/lib/__lib/lib.signal.js +0 -55
- package/cjs/src/templates/lib/__lib/lib.store.js +0 -52
- package/cjs/src/templates/lib/cnst.js +0 -56
- package/cjs/src/templates/lib/db.js +0 -53
- package/cjs/src/templates/lib/dict.js +0 -69
- package/cjs/src/templates/lib/sig.js +0 -71
- package/cjs/src/templates/lib/srv.js +0 -50
- package/cjs/src/templates/lib/st.js +0 -50
- package/cjs/src/templates/lib/useClient.js +0 -40
- package/cjs/src/templates/lib/useServer.js +0 -31
- package/cjs/src/templates/libRoot/akan.config.js +0 -33
- package/cjs/src/templates/libRoot/base/baseLogic.js +0 -35
- package/cjs/src/templates/libRoot/base/index.js +0 -29
- package/cjs/src/templates/libRoot/common/commonLogic.js +0 -35
- package/cjs/src/templates/libRoot/common/index.js +0 -29
- package/cjs/src/templates/libRoot/jest.config.js +0 -36
- package/cjs/src/templates/libRoot/lib/___libName__/__libName__.dictionary.js +0 -35
- package/cjs/src/templates/libRoot/lib/___libName__/__libName__.service.js +0 -33
- package/cjs/src/templates/libRoot/lib/___libName__/__libName__.store.js +0 -35
- package/cjs/src/templates/libRoot/lib/option.js +0 -46
- package/cjs/src/templates/libRoot/nest/backendLogic.js +0 -34
- package/cjs/src/templates/libRoot/nest/index.js +0 -29
- package/cjs/src/templates/libRoot/next/frontendLogic.js +0 -34
- package/cjs/src/templates/libRoot/next/index.js +0 -29
- package/cjs/src/templates/libRoot/tsconfig.spec.json.template +0 -7
- package/cjs/src/templates/libRoot/ui/index.js +0 -29
- package/cjs/src/templates/localDev/docker-compose.yaml.template +0 -42
- package/cjs/src/templates/module/__Model__.Template.js +0 -53
- package/cjs/src/templates/module/__Model__.Unit.js +0 -43
- package/cjs/src/templates/module/__Model__.Util.js +0 -47
- package/cjs/src/templates/module/__Model__.View.js +0 -46
- package/cjs/src/templates/module/__Model__.Zone.js +0 -60
- package/cjs/src/templates/module/__model__.constant.js +0 -41
- package/cjs/src/templates/module/__model__.dictionary.js +0 -47
- package/cjs/src/templates/module/__model__.document.js +0 -46
- package/cjs/src/templates/module/__model__.service.js +0 -33
- package/cjs/src/templates/module/__model__.signal.js +0 -44
- package/cjs/src/templates/module/__model__.store.js +0 -38
- package/cjs/src/templates/module/index.js +0 -61
- package/cjs/src/templates/moduleRoot/index.js +0 -49
- package/cjs/src/templates/pkgRoot/tsconfig.json.template +0 -15
- package/cjs/src/templates/server.js +0 -87
- package/cjs/src/templates/workspaceRoot/.env.template +0 -20
- package/cjs/src/templates/workspaceRoot/.prettierignore.template +0 -10
- package/cjs/src/templates/workspaceRoot/.prettierrc.json.template +0 -6
- package/cjs/src/templates/workspaceRoot/.swcrc.template +0 -9
- package/cjs/src/templates/workspaceRoot/.vscode/settings.json.template +0 -12
- package/cjs/src/templates/workspaceRoot/README.md.template +0 -37
- package/cjs/src/templates/workspaceRoot/eslint.config.ts.template +0 -3
- package/cjs/src/templates/workspaceRoot/infra/app/Chart.yaml.template +0 -6
- package/cjs/src/templates/workspaceRoot/infra/app/templates/frontend.yaml.template +0 -182
- package/cjs/src/templates/workspaceRoot/infra/app/values/_common-values.yaml.template +0 -183
- package/cjs/src/templates/workspaceRoot/package.json.template +0 -47
- package/cjs/src/templates/workspaceRoot/tsconfig.json.template +0 -27
- package/esm/index.js +0 -7758
- package/esm/src/guidelines/___library/sharedUiStructureDescription.en.md +0 -767
- package/esm/src/guidelines/___library/utilUiStructureDescription.en.md +0 -395
- package/esm/src/guidelines/___lint/lintRuleDescription.en.md +0 -64
- package/esm/src/guidelines/___module/moduleStructureDescription.en.md +0 -80
- package/esm/src/guidelines/componentRule/componentRule.generate.json +0 -131
- package/esm/src/guidelines/componentRule/componentRule.instruction.md +0 -637
- package/esm/src/guidelines/cssRule/cssRule.generate.json +0 -93
- package/esm/src/guidelines/cssRule/cssRule.instruction.md +0 -435
- package/esm/src/guidelines/databaseModule/databaseModule.generate.json +0 -51
- package/esm/src/guidelines/databaseModule/databaseModule.instruction.md +0 -631
- package/esm/src/guidelines/docPageRule/docPageRule.generate.json +0 -72
- package/esm/src/guidelines/docPageRule/docPageRule.instruction.md +0 -389
- package/esm/src/guidelines/enumConstant/enumConstant.generate.json +0 -24
- package/esm/src/guidelines/enumConstant/enumConstant.instruction.md +0 -232
- package/esm/src/guidelines/framework/framework.generate.json +0 -119
- package/esm/src/guidelines/framework/framework.instruction.md +0 -1110
- package/esm/src/guidelines/howToUseStore/howToUseStore.generate.json +0 -0
- package/esm/src/guidelines/modelConstant/modelConstant.generate.json +0 -128
- package/esm/src/guidelines/modelConstant/modelConstant.instruction.md +0 -506
- package/esm/src/guidelines/modelDictionary/modelDictionary.generate.json +0 -108
- package/esm/src/guidelines/modelDictionary/modelDictionary.instruction.md +0 -547
- package/esm/src/guidelines/modelDocument/modelDocument.generate.json +0 -129
- package/esm/src/guidelines/modelDocument/modelDocument.instruction.md +0 -659
- package/esm/src/guidelines/modelService/modelService.generate.json +0 -135
- package/esm/src/guidelines/modelService/modelService.instruction.md +0 -708
- package/esm/src/guidelines/modelSignal/modelSignal.generate.json +0 -201
- package/esm/src/guidelines/modelSignal/modelSignal.instruction.md +0 -552
- package/esm/src/guidelines/modelStore/modelStore.generate.json +0 -130
- package/esm/src/guidelines/modelStore/modelStore.instruction.md +0 -590
- package/esm/src/guidelines/modelTemplate/modelTemplate.generate.json +0 -104
- package/esm/src/guidelines/modelTemplate/modelTemplate.instruction.md +0 -604
- package/esm/src/guidelines/modelUnit/modelUnit.generate.json +0 -92
- package/esm/src/guidelines/modelUnit/modelUnit.instruction.md +0 -541
- package/esm/src/guidelines/modelUtil/modelUtil.generate.json +0 -93
- package/esm/src/guidelines/modelUtil/modelUtil.instruction.md +0 -752
- package/esm/src/guidelines/modelView/modelView.generate.json +0 -80
- package/esm/src/guidelines/modelView/modelView.instruction.md +0 -1005
- package/esm/src/guidelines/modelZone/modelZone.generate.json +0 -126
- package/esm/src/guidelines/modelZone/modelZone.instruction.md +0 -528
- package/esm/src/guidelines/scalarConstant/scalarConstant.generate.json +0 -106
- package/esm/src/guidelines/scalarConstant/scalarConstant.instruction.md +0 -442
- package/esm/src/guidelines/scalarDictionary/scalarDictionary.generate.json +0 -83
- package/esm/src/guidelines/scalarDictionary/scalarDictionary.instruction.md +0 -273
- package/esm/src/guidelines/scalarModule/scalarModule.generate.json +0 -35
- package/esm/src/guidelines/scalarModule/scalarModule.instruction.md +0 -81
- package/esm/src/guidelines/sharedUiUsage/sharedUiUsage.generate.json +0 -108
- package/esm/src/guidelines/sharedUiUsage/sharedUiUsage.instruction.md +0 -310
- package/esm/src/guidelines/utilUiUsage/utilUiUsage.generate.json +0 -140
- package/esm/src/guidelines/utilUiUsage/utilUiUsage.instruction.md +0 -339
- package/esm/src/templates/__scalar/__model__/__model__.constant.js +0 -13
- package/esm/src/templates/__scalar/__model__/__model__.dictionary.js +0 -17
- package/esm/src/templates/__scalar/__model__/__model__.document.js +0 -13
- package/esm/src/templates/app/akan.config.js +0 -13
- package/esm/src/templates/app/app/[lang]/layout.js +0 -35
- package/esm/src/templates/app/app/[lang]/page.js +0 -91
- package/esm/src/templates/app/app/[lang]/styles.css.template +0 -20
- package/esm/src/templates/app/app/csr.js +0 -16
- package/esm/src/templates/app/app/index.html.template +0 -13
- package/esm/src/templates/app/app/layout.js +0 -21
- package/esm/src/templates/app/app/robots.js +0 -20
- package/esm/src/templates/app/app/sitemap.js +0 -16
- package/esm/src/templates/app/base/baseLogic.js +0 -15
- package/esm/src/templates/app/base/index.js +0 -9
- package/esm/src/templates/app/capacitor.config.ts.template +0 -8
- package/esm/src/templates/app/common/commonLogic.js +0 -15
- package/esm/src/templates/app/common/index.js +0 -9
- package/esm/src/templates/app/env/env.client.debug.ts.template +0 -7
- package/esm/src/templates/app/env/env.client.develop.ts.template +0 -7
- package/esm/src/templates/app/env/env.client.local.ts.template +0 -7
- package/esm/src/templates/app/env/env.client.main.ts.template +0 -7
- package/esm/src/templates/app/env/env.client.testing.ts.template +0 -7
- package/esm/src/templates/app/env/env.client.type.js +0 -15
- package/esm/src/templates/app/env/env.server.debug.ts.template +0 -10
- package/esm/src/templates/app/env/env.server.develop.ts.template +0 -10
- package/esm/src/templates/app/env/env.server.local.ts.template +0 -10
- package/esm/src/templates/app/env/env.server.main.ts.template +0 -10
- package/esm/src/templates/app/instrumentation.js +0 -12
- package/esm/src/templates/app/jest.config.js +0 -16
- package/esm/src/templates/app/lib/___appName__/__appName__.dictionary.js +0 -15
- package/esm/src/templates/app/lib/___appName__/__appName__.service.js +0 -11
- package/esm/src/templates/app/lib/___appName__/__appName__.signal.js +0 -15
- package/esm/src/templates/app/lib/___appName__/__appName__.store.js +0 -15
- package/esm/src/templates/app/lib/option.js +0 -27
- package/esm/src/templates/app/main.js +0 -19
- package/esm/src/templates/app/nest/backendLogic.js +0 -14
- package/esm/src/templates/app/nest/index.js +0 -9
- package/esm/src/templates/app/next/frontendLogic.js +0 -14
- package/esm/src/templates/app/next/index.js +0 -9
- package/esm/src/templates/app/package.json.template +0 -5
- package/esm/src/templates/app/postcss.config.js.template +0 -8
- package/esm/src/templates/app/proxy.js +0 -15
- package/esm/src/templates/app/public/favicon.ico +0 -0
- package/esm/src/templates/app/public/icons/icon-128x128.png +0 -0
- package/esm/src/templates/app/public/icons/icon-144x144.png +0 -0
- package/esm/src/templates/app/public/icons/icon-152x152.png +0 -0
- package/esm/src/templates/app/public/icons/icon-192x192.png +0 -0
- package/esm/src/templates/app/public/icons/icon-256x256.png +0 -0
- package/esm/src/templates/app/public/icons/icon-384x384.png +0 -0
- package/esm/src/templates/app/public/icons/icon-48x48.png +0 -0
- package/esm/src/templates/app/public/icons/icon-512x512.png +0 -0
- package/esm/src/templates/app/public/icons/icon-72x72.png +0 -0
- package/esm/src/templates/app/public/icons/icon-96x96.png +0 -0
- package/esm/src/templates/app/public/logo.svg +0 -70
- package/esm/src/templates/app/public/manifest.json.template +0 -67
- package/esm/src/templates/app/tsconfig.spec.json.template +0 -7
- package/esm/src/templates/app/ui/UiComponent.js +0 -18
- package/esm/src/templates/app/ui/index.js +0 -9
- package/esm/src/templates/client.js +0 -27
- package/esm/src/templates/crudPages/[__model__Id]/edit/page.js +0 -52
- package/esm/src/templates/crudPages/[__model__Id]/page.js +0 -58
- package/esm/src/templates/crudPages/new/page.js +0 -47
- package/esm/src/templates/crudPages/page.js +0 -48
- package/esm/src/templates/crudSinglePage/page.js +0 -42
- package/esm/src/templates/env/_env.server.type.js +0 -19
- package/esm/src/templates/index.js +0 -9
- package/esm/src/templates/lib/__lib/lib.constant.js +0 -37
- package/esm/src/templates/lib/__lib/lib.dictionary.js +0 -30
- package/esm/src/templates/lib/__lib/lib.document.js +0 -32
- package/esm/src/templates/lib/__lib/lib.service.js +0 -39
- package/esm/src/templates/lib/__lib/lib.signal.js +0 -35
- package/esm/src/templates/lib/__lib/lib.store.js +0 -32
- package/esm/src/templates/lib/cnst.js +0 -36
- package/esm/src/templates/lib/db.js +0 -33
- package/esm/src/templates/lib/sig.js +0 -51
- package/esm/src/templates/lib/srv.js +0 -30
- package/esm/src/templates/lib/st.js +0 -30
- package/esm/src/templates/lib/useClient.js +0 -20
- package/esm/src/templates/lib/useServer.js +0 -11
- package/esm/src/templates/libRoot/.gitignore.template +0 -16
- package/esm/src/templates/libRoot/akan.config.js +0 -13
- package/esm/src/templates/libRoot/base/baseLogic.js +0 -15
- package/esm/src/templates/libRoot/base/index.js +0 -9
- package/esm/src/templates/libRoot/common/commonLogic.js +0 -15
- package/esm/src/templates/libRoot/common/index.js +0 -9
- package/esm/src/templates/libRoot/env/env.server.example.ts.template +0 -6
- package/esm/src/templates/libRoot/env/env.server.testing.ts.template +0 -6
- package/esm/src/templates/libRoot/jest.config.js +0 -16
- package/esm/src/templates/libRoot/lib/___libName__/__libName__.service.js +0 -13
- package/esm/src/templates/libRoot/lib/___libName__/__libName__.store.js +0 -15
- package/esm/src/templates/libRoot/lib/option.js +0 -26
- package/esm/src/templates/libRoot/nest/backendLogic.js +0 -14
- package/esm/src/templates/libRoot/nest/index.js +0 -9
- package/esm/src/templates/libRoot/next/frontendLogic.js +0 -14
- package/esm/src/templates/libRoot/next/index.js +0 -9
- package/esm/src/templates/libRoot/package.json.template +0 -5
- package/esm/src/templates/libRoot/tsconfig.spec.json.template +0 -7
- package/esm/src/templates/libRoot/ui/index.js +0 -9
- package/esm/src/templates/localDev/docker-compose.yaml.template +0 -42
- package/esm/src/templates/module/__Model__.Unit.js +0 -23
- package/esm/src/templates/module/__Model__.Util.js +0 -27
- package/esm/src/templates/module/__model__.document.js +0 -26
- package/esm/src/templates/module/__model__.service.js +0 -13
- package/esm/src/templates/module/__model__.store.js +0 -18
- package/esm/src/templates/module/index.js +0 -41
- package/esm/src/templates/moduleRoot/index.js +0 -29
- package/esm/src/templates/pkgRoot/tsconfig.json.template +0 -15
- package/esm/src/templates/server.js +0 -67
- package/esm/src/templates/workspaceRoot/.env.template +0 -20
- package/esm/src/templates/workspaceRoot/.gitignore.template +0 -119
- package/esm/src/templates/workspaceRoot/.prettierignore.template +0 -10
- package/esm/src/templates/workspaceRoot/.prettierrc.json.template +0 -6
- package/esm/src/templates/workspaceRoot/.swcrc.template +0 -9
- package/esm/src/templates/workspaceRoot/.vscode/settings.json.template +0 -12
- package/esm/src/templates/workspaceRoot/README.md.template +0 -37
- package/esm/src/templates/workspaceRoot/eslint.config.ts.template +0 -3
- package/esm/src/templates/workspaceRoot/infra/app/Chart.yaml.template +0 -6
- package/esm/src/templates/workspaceRoot/infra/app/templates/frontend.yaml.template +0 -182
- package/esm/src/templates/workspaceRoot/infra/app/values/_common-values.yaml.template +0 -183
- package/esm/src/templates/workspaceRoot/package.json.template +0 -47
- package/esm/src/templates/workspaceRoot/tsconfig.json.template +0 -27
- package/index.d.ts +0 -2
- package/src/application/application.command.d.ts +0 -31
- package/src/application/application.interface.d.ts +0 -40
- package/src/application/application.runner.d.ts +0 -73
- package/src/application/application.script.d.ts +0 -83
- package/src/cloud/cloud.command.d.ts +0 -12
- package/src/cloud/cloud.runner.d.ts +0 -11
- package/src/cloud/cloud.script.d.ts +0 -11
- package/src/guideline/guideline.command.d.ts +0 -9
- package/src/guideline/guideline.prompt.d.ts +0 -29
- package/src/guideline/guideline.runner.d.ts +0 -19
- package/src/guideline/guideline.script.d.ts +0 -12
- package/src/guidelines/___library/sharedUiStructureDescription.en.md +0 -767
- package/src/guidelines/___library/utilUiStructureDescription.en.md +0 -395
- package/src/guidelines/___lint/lintRuleDescription.en.md +0 -64
- package/src/guidelines/___module/moduleStructureDescription.en.md +0 -80
- package/src/guidelines/componentRule/componentRule.instruction.md +0 -637
- package/src/guidelines/cssRule/cssRule.instruction.md +0 -435
- package/src/guidelines/databaseModule/databaseModule.instruction.md +0 -631
- package/src/guidelines/docPageRule/docPageRule.instruction.md +0 -389
- package/src/guidelines/enumConstant/enumConstant.instruction.md +0 -232
- package/src/guidelines/framework/framework.instruction.md +0 -1110
- package/src/guidelines/modelConstant/modelConstant.instruction.md +0 -506
- package/src/guidelines/modelDictionary/modelDictionary.instruction.md +0 -547
- package/src/guidelines/modelDocument/modelDocument.instruction.md +0 -659
- package/src/guidelines/modelService/modelService.instruction.md +0 -708
- package/src/guidelines/modelSignal/modelSignal.instruction.md +0 -552
- package/src/guidelines/modelStore/modelStore.instruction.md +0 -590
- package/src/guidelines/modelTemplate/modelTemplate.instruction.md +0 -604
- package/src/guidelines/modelUnit/modelUnit.instruction.md +0 -541
- package/src/guidelines/modelUtil/modelUtil.instruction.md +0 -752
- package/src/guidelines/modelView/modelView.instruction.md +0 -1005
- package/src/guidelines/modelZone/modelZone.instruction.md +0 -528
- package/src/guidelines/scalarConstant/scalarConstant.instruction.md +0 -442
- package/src/guidelines/scalarDictionary/scalarDictionary.instruction.md +0 -273
- package/src/guidelines/scalarModule/scalarModule.instruction.md +0 -81
- package/src/guidelines/sharedUiUsage/sharedUiUsage.instruction.md +0 -310
- package/src/guidelines/utilUiUsage/utilUiUsage.instruction.md +0 -339
- package/src/library/library.command.d.ts +0 -9
- package/src/library/library.runner.d.ts +0 -9
- package/src/library/library.script.d.ts +0 -9
- package/src/module/module.command.d.ts +0 -10
- package/src/module/module.prompt.d.ts +0 -13
- package/src/module/module.request.d.ts +0 -63
- package/src/module/module.runner.d.ts +0 -53
- package/src/module/module.script.d.ts +0 -17
- package/src/package/package.command.d.ts +0 -10
- package/src/package/package.runner.d.ts +0 -9
- package/src/package/package.script.d.ts +0 -10
- package/src/page/page.command.d.ts +0 -6
- package/src/page/page.runner.d.ts +0 -8
- package/src/page/page.script.d.ts +0 -9
- package/src/scalar/scalar.command.d.ts +0 -7
- package/src/scalar/scalar.prompt.d.ts +0 -23
- package/src/scalar/scalar.runner.d.ts +0 -14
- package/src/scalar/scalar.script.d.ts +0 -7
- package/src/templates/__scalar/__model__/__model__.constant.d.ts +0 -7
- package/src/templates/__scalar/__model__/__model__.dictionary.d.ts +0 -7
- package/src/templates/__scalar/__model__/__model__.document.d.ts +0 -7
- package/src/templates/app/akan.config.d.ts +0 -6
- package/src/templates/app/app/[lang]/layout.d.ts +0 -11
- package/src/templates/app/app/[lang]/page.d.ts +0 -9
- package/src/templates/app/app/csr.d.ts +0 -9
- package/src/templates/app/app/layout.d.ts +0 -9
- package/src/templates/app/app/robots.d.ts +0 -6
- package/src/templates/app/app/sitemap.d.ts +0 -6
- package/src/templates/app/base/baseLogic.d.ts +0 -6
- package/src/templates/app/base/index.d.ts +0 -6
- package/src/templates/app/common/commonLogic.d.ts +0 -6
- package/src/templates/app/common/index.d.ts +0 -6
- package/src/templates/app/env/env.client.d.ts +0 -6
- package/src/templates/app/env/env.client.type.d.ts +0 -6
- package/src/templates/app/env/env.server.d.ts +0 -6
- package/src/templates/app/instrumentation.d.ts +0 -6
- package/src/templates/app/jest.config.d.ts +0 -6
- package/src/templates/app/lib/___appName__/__appName__.dictionary.d.ts +0 -7
- package/src/templates/app/lib/___appName__/__appName__.service.d.ts +0 -7
- package/src/templates/app/lib/___appName__/__appName__.signal.d.ts +0 -7
- package/src/templates/app/lib/___appName__/__appName__.store.d.ts +0 -7
- package/src/templates/app/lib/option.d.ts +0 -6
- package/src/templates/app/main.d.ts +0 -6
- package/src/templates/app/nest/backendLogic.d.ts +0 -6
- package/src/templates/app/nest/index.d.ts +0 -6
- package/src/templates/app/next/frontendLogic.d.ts +0 -6
- package/src/templates/app/next/index.d.ts +0 -6
- package/src/templates/app/proxy.d.ts +0 -6
- package/src/templates/app/ui/UiComponent.d.ts +0 -9
- package/src/templates/app/ui/index.d.ts +0 -6
- package/src/templates/client.d.ts +0 -4
- package/src/templates/crudPages/[__model__Id]/edit/page.d.ts +0 -11
- package/src/templates/crudPages/[__model__Id]/page.d.ts +0 -11
- package/src/templates/crudPages/new/page.d.ts +0 -11
- package/src/templates/crudPages/page.d.ts +0 -11
- package/src/templates/crudSinglePage/page.d.ts +0 -11
- package/src/templates/env/_env.server.type.d.ts +0 -7
- package/src/templates/index.d.ts +0 -6
- package/src/templates/lib/__lib/lib.constant.d.ts +0 -4
- package/src/templates/lib/__lib/lib.dictionary.d.ts +0 -4
- package/src/templates/lib/__lib/lib.document.d.ts +0 -4
- package/src/templates/lib/__lib/lib.service.d.ts +0 -4
- package/src/templates/lib/__lib/lib.signal.d.ts +0 -4
- package/src/templates/lib/__lib/lib.store.d.ts +0 -4
- package/src/templates/lib/cnst.d.ts +0 -4
- package/src/templates/lib/db.d.ts +0 -4
- package/src/templates/lib/dict.d.ts +0 -4
- package/src/templates/lib/sig.d.ts +0 -4
- package/src/templates/lib/srv.d.ts +0 -4
- package/src/templates/lib/st.d.ts +0 -4
- package/src/templates/lib/useClient.d.ts +0 -4
- package/src/templates/lib/useServer.d.ts +0 -4
- package/src/templates/libRoot/akan.config.d.ts +0 -5
- package/src/templates/libRoot/base/baseLogic.d.ts +0 -5
- package/src/templates/libRoot/base/index.d.ts +0 -5
- package/src/templates/libRoot/common/commonLogic.d.ts +0 -5
- package/src/templates/libRoot/common/index.d.ts +0 -5
- package/src/templates/libRoot/jest.config.d.ts +0 -6
- package/src/templates/libRoot/lib/___libName__/__libName__.dictionary.d.ts +0 -6
- package/src/templates/libRoot/lib/___libName__/__libName__.service.d.ts +0 -6
- package/src/templates/libRoot/lib/___libName__/__libName__.store.d.ts +0 -6
- package/src/templates/libRoot/lib/option.d.ts +0 -6
- package/src/templates/libRoot/nest/backendLogic.d.ts +0 -5
- package/src/templates/libRoot/nest/index.d.ts +0 -5
- package/src/templates/libRoot/next/frontendLogic.d.ts +0 -5
- package/src/templates/libRoot/next/index.d.ts +0 -5
- package/src/templates/libRoot/ui/index.d.ts +0 -5
- package/src/templates/module/__Model__.Template.d.ts +0 -11
- package/src/templates/module/__Model__.Unit.d.ts +0 -11
- package/src/templates/module/__Model__.Util.d.ts +0 -11
- package/src/templates/module/__Model__.View.d.ts +0 -11
- package/src/templates/module/__Model__.Zone.d.ts +0 -11
- package/src/templates/module/__model__.constant.d.ts +0 -8
- package/src/templates/module/__model__.dictionary.d.ts +0 -8
- package/src/templates/module/__model__.document.d.ts +0 -8
- package/src/templates/module/__model__.service.d.ts +0 -8
- package/src/templates/module/__model__.signal.d.ts +0 -9
- package/src/templates/module/__model__.store.d.ts +0 -8
- package/src/templates/module/index.d.ts +0 -11
- package/src/templates/moduleRoot/index.d.ts +0 -11
- package/src/templates/server.d.ts +0 -4
- package/src/workspace/workspace.command.d.ts +0 -12
- package/src/workspace/workspace.runner.d.ts +0 -13
- package/src/workspace/workspace.script.d.ts +0 -24
- package/ui/MultiScrollList.d.ts +0 -14
- /package/{cjs/src/templates → templates}/app/package.json.template +0 -0
- /package/{cjs/src/templates → templates}/libRoot/.gitignore.template +0 -0
- /package/{cjs/src/templates → templates}/libRoot/env/env.server.example.ts.template +0 -0
- /package/{cjs/src/templates → templates}/libRoot/env/env.server.testing.ts.template +0 -0
- /package/{cjs/src/templates → templates}/libRoot/package.json.template +0 -0
- /package/{cjs/src/templates → templates}/libRoot/tsconfig.json.template +0 -0
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/crudPages/[__model__Id]/edit/page.tsx
|
|
20
|
-
var page_exports = {};
|
|
21
|
-
__export(page_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(page_exports);
|
|
25
|
-
function getContent(scanInfo, dict) {
|
|
26
|
-
return {
|
|
27
|
-
filename: "page.tsx",
|
|
28
|
-
content: `
|
|
29
|
-
import { Load } from "@akanjs/ui";
|
|
30
|
-
import { fetch, usePage, ${dict.Model} } from "${dict.appName}/client";
|
|
31
|
-
import type { CsrConfig } from "@akanjs/client";
|
|
32
|
-
|
|
33
|
-
interface PageProps {
|
|
34
|
-
params: { ${dict.model}Id: string };
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
export default function Page({ params }: PageProps) {
|
|
38
|
-
const { l } = usePage();
|
|
39
|
-
return (
|
|
40
|
-
<Load.Page
|
|
41
|
-
of={Page}
|
|
42
|
-
loader={async () => {
|
|
43
|
-
const { ${dict.model}Id } = await params;
|
|
44
|
-
const { ${dict.model}, ${dict.model}Edit } = await fetch.edit${dict.Model}(${dict.model}Id);
|
|
45
|
-
return { ${dict.model}, ${dict.model}Edit } as const;
|
|
46
|
-
}}
|
|
47
|
-
render={({ ${dict.model}, ${dict.model}Edit }) => (
|
|
48
|
-
<div className="container">
|
|
49
|
-
<div className="flex justify-between m-4 mt-8">
|
|
50
|
-
<div className="text-xl text-primary flex gap-2 items-center">
|
|
51
|
-
{l("base.updateModel", { model: l("${dict.model}.modelName") })}
|
|
52
|
-
</div>
|
|
53
|
-
</div>
|
|
54
|
-
<Load.Edit
|
|
55
|
-
className="flex flex-col items-center"
|
|
56
|
-
sliceName="${dict.model}InPublic"
|
|
57
|
-
edit={${dict.model}Edit}
|
|
58
|
-
type="form"
|
|
59
|
-
onCancel="back"
|
|
60
|
-
onSubmit="/${dict.model}"
|
|
61
|
-
>
|
|
62
|
-
<${dict.Model}.Template.General />
|
|
63
|
-
</Load.Edit>
|
|
64
|
-
</div>
|
|
65
|
-
)}
|
|
66
|
-
/>
|
|
67
|
-
);
|
|
68
|
-
}
|
|
69
|
-
Page.csrConfig = { transition: "none" } satisfies CsrConfig;
|
|
70
|
-
`
|
|
71
|
-
};
|
|
72
|
-
}
|
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/crudPages/[__model__Id]/page.tsx
|
|
20
|
-
var page_exports = {};
|
|
21
|
-
__export(page_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(page_exports);
|
|
25
|
-
function getContent(scanInfo, dict) {
|
|
26
|
-
return {
|
|
27
|
-
filename: "page.tsx",
|
|
28
|
-
content: `
|
|
29
|
-
import { ${dict.Model}, fetch, usePage } from "${dict.appName}/client";
|
|
30
|
-
import { Link, Load } from "@akanjs/ui";
|
|
31
|
-
import type { CsrConfig } from "@akanjs/client";
|
|
32
|
-
|
|
33
|
-
interface PageProps {
|
|
34
|
-
params: { ${dict.model}Id: string };
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
export async function generateMetadata({ params }: PageProps) {
|
|
38
|
-
const { ${dict.model}Id } = await params;
|
|
39
|
-
const { ${dict.model} } = await fetch.view${dict.Model}(${dict.model}Id);
|
|
40
|
-
return {
|
|
41
|
-
title: ${dict.model}.id,
|
|
42
|
-
description: ${dict.model}.id,
|
|
43
|
-
openGraph: {
|
|
44
|
-
title: ${dict.model}.id,
|
|
45
|
-
description: ${dict.model}.id,
|
|
46
|
-
// images: ${dict.model}.thumbnails.map((i) => i.url),
|
|
47
|
-
},
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
export default function Page({ params }: PageProps) {
|
|
51
|
-
const { l } = usePage();
|
|
52
|
-
return (
|
|
53
|
-
<Load.Page
|
|
54
|
-
of={Page}
|
|
55
|
-
loader={async () => {
|
|
56
|
-
const { ${dict.model}Id } = await params;
|
|
57
|
-
const { ${dict.model}, ${dict.model}View } = await fetch.view${dict.Model}(${dict.model}Id);
|
|
58
|
-
return { ${dict.model}, ${dict.model}View } as const;
|
|
59
|
-
}}
|
|
60
|
-
render={({ ${dict.model}, ${dict.model}View }) => (
|
|
61
|
-
<div className="container flex flex-col gap-4">
|
|
62
|
-
<div className="flex gap-4 font-bold text-lg items-center">
|
|
63
|
-
<${dict.Model}.Zone.View view={${dict.model}View} />
|
|
64
|
-
<Link href={\`/${dict.model}/\${${dict.model}.id}/edit\`}>
|
|
65
|
-
<button className="btn">
|
|
66
|
-
{l("base.updateModel", { model: l("${dict.model}.modelName") })}
|
|
67
|
-
</button>
|
|
68
|
-
</Link>
|
|
69
|
-
</div>
|
|
70
|
-
</div>
|
|
71
|
-
)}
|
|
72
|
-
/>
|
|
73
|
-
);
|
|
74
|
-
}
|
|
75
|
-
Page.csrConfig = { transition: "none" } satisfies CsrConfig;
|
|
76
|
-
`
|
|
77
|
-
};
|
|
78
|
-
}
|
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/crudPages/new/page.tsx
|
|
20
|
-
var page_exports = {};
|
|
21
|
-
__export(page_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(page_exports);
|
|
25
|
-
function getContent(scanInfo, dict) {
|
|
26
|
-
return {
|
|
27
|
-
filename: "page.tsx",
|
|
28
|
-
content: `
|
|
29
|
-
import { Load } from "@akanjs/ui";
|
|
30
|
-
import { cnst, fetch, usePage, ${dict.Model} } from "@${dict.appName}/client";
|
|
31
|
-
import type { CsrConfig } from "@akanjs/client";
|
|
32
|
-
|
|
33
|
-
export default function Page() {
|
|
34
|
-
const { l } = usePage();
|
|
35
|
-
return (
|
|
36
|
-
<Load.Page
|
|
37
|
-
of={Page}
|
|
38
|
-
loader={async () => {
|
|
39
|
-
const ${dict.model}Form: Partial<cnst.${dict.Model}> = {};
|
|
40
|
-
return { ${dict.model}Form } as const;
|
|
41
|
-
}}
|
|
42
|
-
render={({ ${dict.model}Form }) => (
|
|
43
|
-
<div className="container">
|
|
44
|
-
<div className="flex justify-between m-4 mt-8">
|
|
45
|
-
<div className="text-xl text-primary flex gap-2 items-center">
|
|
46
|
-
+ {l("base.createModel", { model: l("${dict.model}.modelName") })}
|
|
47
|
-
</div>
|
|
48
|
-
</div>
|
|
49
|
-
<Load.Edit
|
|
50
|
-
className="flex flex-col items-center"
|
|
51
|
-
sliceName="${dict.model}InPublic"
|
|
52
|
-
edit={${dict.model}Form}
|
|
53
|
-
type="form"
|
|
54
|
-
onCancel="back"
|
|
55
|
-
onSubmit="/${dict.model}"
|
|
56
|
-
>
|
|
57
|
-
<${dict.Model}.Template.General />
|
|
58
|
-
</Load.Edit>
|
|
59
|
-
</div>
|
|
60
|
-
)}
|
|
61
|
-
/>
|
|
62
|
-
);
|
|
63
|
-
}
|
|
64
|
-
Page.csrConfig = { transition: "none" } satisfies CsrConfig;
|
|
65
|
-
`
|
|
66
|
-
};
|
|
67
|
-
}
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/crudPages/page.tsx
|
|
20
|
-
var page_exports = {};
|
|
21
|
-
__export(page_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(page_exports);
|
|
25
|
-
function getContent(scanInfo, dict) {
|
|
26
|
-
return {
|
|
27
|
-
filename: "page.tsx",
|
|
28
|
-
content: `
|
|
29
|
-
import { ${dict.Model}, fetch, usePage } from "@${dict.appName}/client";
|
|
30
|
-
import { Link, Load } from "@akanjs/ui";
|
|
31
|
-
import type { CsrConfig } from "@akanjs/client";
|
|
32
|
-
|
|
33
|
-
export default function Page() {
|
|
34
|
-
const { l } = usePage();
|
|
35
|
-
return (
|
|
36
|
-
<Load.Page
|
|
37
|
-
of={Page}
|
|
38
|
-
loader={async () => {
|
|
39
|
-
const { ${dict.model}InitInPublic } = await fetch.init${dict.Model}InPublic();
|
|
40
|
-
return { ${dict.model}InitInPublic } as const;
|
|
41
|
-
}}
|
|
42
|
-
render={({ ${dict.model}InitInPublic }) => (
|
|
43
|
-
<div className="container flex flex-col gap-4">
|
|
44
|
-
<div className="w-full mt-5 px-5 h-full ">
|
|
45
|
-
<div>{l("${dict.model}.modelName")}</div>
|
|
46
|
-
<div className="animate-fadeIn px-4 pt-4 flex gap-4 items-center">
|
|
47
|
-
<div className="font-bold text-lg md:text-4xl">${dict.Model}s</div>
|
|
48
|
-
<Link href={\`/${dict.model}/new\`}>
|
|
49
|
-
<button className="btn">+ {l("base.createModel", { model: l("${dict.model}.modelName") })}</button>
|
|
50
|
-
</Link>
|
|
51
|
-
</div>
|
|
52
|
-
<div>{l("${dict.model}.modelDesc")}</div>
|
|
53
|
-
<div className="flex px-6 mt-3 gap-4">
|
|
54
|
-
<${dict.Model}.Zone.Card
|
|
55
|
-
className="animate-fadeIn grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 2xl:grid-cols-5 justify-center gap-4 w-full"
|
|
56
|
-
init={${dict.model}InitInPublic}
|
|
57
|
-
/>
|
|
58
|
-
</div>
|
|
59
|
-
</div>
|
|
60
|
-
</div>
|
|
61
|
-
)}
|
|
62
|
-
/>
|
|
63
|
-
);
|
|
64
|
-
}
|
|
65
|
-
Page.csrConfig = { transition: "none" } satisfies CsrConfig;
|
|
66
|
-
`
|
|
67
|
-
};
|
|
68
|
-
}
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/crudSinglePage/page.tsx
|
|
20
|
-
var page_exports = {};
|
|
21
|
-
__export(page_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(page_exports);
|
|
25
|
-
function getContent(scanInfo, dict) {
|
|
26
|
-
return {
|
|
27
|
-
filename: "page.tsx",
|
|
28
|
-
content: `
|
|
29
|
-
import type { CsrConfig } from "@akanjs/client";
|
|
30
|
-
import { Load, Model } from "@akanjs/ui";
|
|
31
|
-
import { ${dict.Model}, type cnst, fetch, usePage } from "@${dict.appName}/client";
|
|
32
|
-
|
|
33
|
-
export default function Page() {
|
|
34
|
-
const { l } = usePage();
|
|
35
|
-
return (
|
|
36
|
-
<Load.Page
|
|
37
|
-
of={Page}
|
|
38
|
-
loader={async () => {
|
|
39
|
-
const { ${dict.model}InitInPublic } = await fetch.init${dict.Model}InPublic();
|
|
40
|
-
return { ${dict.model}InitInPublic } as const;
|
|
41
|
-
}}
|
|
42
|
-
render={({ ${dict.model}InitInPublic }) => (
|
|
43
|
-
<>
|
|
44
|
-
<div className="animate-fadeIn flex items-center gap-4 px-4 pt-4">
|
|
45
|
-
<div className="text-lg font-bold md:text-4xl">{l("${dict.model}.modelName")}</div>
|
|
46
|
-
<Model.New className="btn btn-ghost" sliceName="${dict.model}InPublic" renderTitle="id">
|
|
47
|
-
<${dict.Model}.Template.General />
|
|
48
|
-
</Model.New>
|
|
49
|
-
</div>
|
|
50
|
-
<${dict.Model}.Zone.Card
|
|
51
|
-
className="animate-fadeIn mt-2 grid w-full grid-cols-1 justify-center gap-4 md:grid-cols-2 xl:grid-cols-3"
|
|
52
|
-
init={${dict.model}InitInPublic}
|
|
53
|
-
/>
|
|
54
|
-
</>
|
|
55
|
-
)}
|
|
56
|
-
/>
|
|
57
|
-
);
|
|
58
|
-
}
|
|
59
|
-
Page.csrConfig = { transition: "none" } satisfies CsrConfig;
|
|
60
|
-
`
|
|
61
|
-
};
|
|
62
|
-
}
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/env/_env.server.type.ts
|
|
20
|
-
var env_server_type_exports = {};
|
|
21
|
-
__export(env_server_type_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(env_server_type_exports);
|
|
25
|
-
function getContent(scanInfo, dict = {}) {
|
|
26
|
-
if (!scanInfo)
|
|
27
|
-
return null;
|
|
28
|
-
const libs = scanInfo.getLibs();
|
|
29
|
-
return {
|
|
30
|
-
filename: "env.server.type.ts",
|
|
31
|
-
content: `
|
|
32
|
-
${libs.length ? libs.map((lib) => `import { env as ${lib}Option } from "@${lib}/server";`).join("\n") : 'import { baseEnv } from "@akanjs/base";'}
|
|
33
|
-
|
|
34
|
-
export const libEnv = {
|
|
35
|
-
${libs.length ? libs.map((lib) => ` ...${lib}Option,`).join("\n") : " ...baseEnv,"}
|
|
36
|
-
};
|
|
37
|
-
`
|
|
38
|
-
};
|
|
39
|
-
}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/index.ts
|
|
20
|
-
var templates_exports = {};
|
|
21
|
-
__export(templates_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(templates_exports);
|
|
25
|
-
function getContent(scanInfo, dict = {}) {
|
|
26
|
-
return `
|
|
27
|
-
export * as cnst from "./lib/cnst";
|
|
28
|
-
`;
|
|
29
|
-
}
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/lib/__lib/lib.constant.ts
|
|
20
|
-
var lib_constant_exports = {};
|
|
21
|
-
__export(lib_constant_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(lib_constant_exports);
|
|
25
|
-
var capitalize = (str) => str.charAt(0).toUpperCase() + str.slice(1);
|
|
26
|
-
function getContent(scanInfo, dict = {}) {
|
|
27
|
-
if (!scanInfo)
|
|
28
|
-
return null;
|
|
29
|
-
const libs = scanInfo.getLibs();
|
|
30
|
-
const libInfos = scanInfo.getLibInfos();
|
|
31
|
-
const extendedModels = Object.fromEntries(
|
|
32
|
-
[...scanInfo.file.constant.databases].map(
|
|
33
|
-
(modelName) => [
|
|
34
|
-
modelName,
|
|
35
|
-
[...libInfos.values()].filter((libInfo) => libInfo.file.constant.databases.has(modelName)).map((libInfo) => libInfo.name)
|
|
36
|
-
]
|
|
37
|
-
).filter(([_, libNames]) => libNames.length > 0)
|
|
38
|
-
);
|
|
39
|
-
return `
|
|
40
|
-
${libs.map((lib) => `import { cnst as ${lib} } from "@${lib}";`).join("\n")}
|
|
41
|
-
|
|
42
|
-
${libs.map((lib) => `export { cnst as ${lib} } from "@${lib}";`).join("\n")}
|
|
43
|
-
|
|
44
|
-
${Object.entries(extendedModels).map(([modelName, extendedModels2]) => {
|
|
45
|
-
const ModelName = capitalize(modelName);
|
|
46
|
-
return `export const ${modelName} = {
|
|
47
|
-
inputs: [${extendedModels2.map((libName) => `${libName}.${ModelName}Input`).join(", ")}] as const,
|
|
48
|
-
objects: [${extendedModels2.map((libName) => `${libName}.${ModelName}Object`).join(", ")}] as const,
|
|
49
|
-
lights: [${extendedModels2.map((libName) => `${libName}.Light${ModelName}`).join(", ")}] as const,
|
|
50
|
-
models: [${extendedModels2.map((libName) => `${libName}.${ModelName}`).join(", ")}] as const,
|
|
51
|
-
insights: [${extendedModels2.map((libName) => `${libName}.${ModelName}Insight`).join(", ")}] as const,
|
|
52
|
-
}`;
|
|
53
|
-
}).join("\n")}
|
|
54
|
-
|
|
55
|
-
export const allLibs = [${libs.join(", ")}] as const;
|
|
56
|
-
`;
|
|
57
|
-
}
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/lib/__lib/lib.dictionary.ts
|
|
20
|
-
var lib_dictionary_exports = {};
|
|
21
|
-
__export(lib_dictionary_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(lib_dictionary_exports);
|
|
25
|
-
function getContent(scanInfo, dict = {}) {
|
|
26
|
-
if (!scanInfo)
|
|
27
|
-
return null;
|
|
28
|
-
const libs = scanInfo.getLibs();
|
|
29
|
-
const libInfos = scanInfo.getLibInfos();
|
|
30
|
-
const extendedModels = Object.fromEntries(
|
|
31
|
-
[...scanInfo.file.dictionary.databases].map(
|
|
32
|
-
(modelName) => [
|
|
33
|
-
modelName,
|
|
34
|
-
[...libInfos.values()].filter((libInfo) => libInfo.file.dictionary.databases.has(modelName)).map((libInfo) => libInfo.name)
|
|
35
|
-
]
|
|
36
|
-
).filter(([_, libNames]) => libNames.length > 0)
|
|
37
|
-
);
|
|
38
|
-
return `
|
|
39
|
-
${libs.length === 0 ? `import * as base from "@akanjs/dictionary";` : ""}
|
|
40
|
-
${libs.map((lib) => `import { dict as ${lib} } from "@${lib}/server";`).join("\n")}
|
|
41
|
-
|
|
42
|
-
${Object.entries(extendedModels).map(([modelName, extendedModels2]) => {
|
|
43
|
-
return `export const ${modelName} = {
|
|
44
|
-
dictionaries: [${extendedModels2.map((libName) => `${libName}.${modelName}.dictionary`).join(", ")}] as const,
|
|
45
|
-
};`;
|
|
46
|
-
}).join("\n")}
|
|
47
|
-
|
|
48
|
-
export const allLibs = [${libs.length === 0 ? "base.dictionary" : libs.map((lib) => `${lib}.dictionary`).join(", ")}] as const;
|
|
49
|
-
`;
|
|
50
|
-
}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/lib/__lib/lib.document.ts
|
|
20
|
-
var lib_document_exports = {};
|
|
21
|
-
__export(lib_document_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(lib_document_exports);
|
|
25
|
-
function getContent(scanInfo, dict = {}) {
|
|
26
|
-
if (!scanInfo)
|
|
27
|
-
return null;
|
|
28
|
-
const libs = scanInfo.getLibs();
|
|
29
|
-
const libInfos = [...scanInfo.getLibInfos().values()];
|
|
30
|
-
const extendedModels = Object.fromEntries(
|
|
31
|
-
[...scanInfo.file.document.databases].map(
|
|
32
|
-
(modelName) => [
|
|
33
|
-
modelName,
|
|
34
|
-
libInfos.filter((libInfo) => libInfo.file.document.databases.has(modelName)).map((libInfo) => libInfo.name)
|
|
35
|
-
]
|
|
36
|
-
).filter(([_, libNames]) => libNames.length > 0)
|
|
37
|
-
);
|
|
38
|
-
return `
|
|
39
|
-
${libs.map((lib) => `import { db as ${lib} } from "@${lib}/server";`).join("\n")}
|
|
40
|
-
${libs.map((lib) => `export { db as ${lib} } from "@${lib}/server";`).join("\n")}
|
|
41
|
-
|
|
42
|
-
${Object.entries(extendedModels).map(
|
|
43
|
-
([modelName, extendedModels2]) => `export const ${modelName} = {
|
|
44
|
-
inputs: [${extendedModels2.map((libName) => `${libName}.${modelName}.Input`).join(", ")}] as const,
|
|
45
|
-
docs: [${extendedModels2.map((libName) => `${libName}.${modelName}.Doc`).join(", ")}] as const,
|
|
46
|
-
models: [${extendedModels2.map((libName) => `${libName}.${modelName}.Model`).join(", ")}] as const,
|
|
47
|
-
filters: [${extendedModels2.map((libName) => `${libName}.${modelName}.Filter`).join(", ")}] as const,
|
|
48
|
-
}`
|
|
49
|
-
).join("\n")}
|
|
50
|
-
export const allLibs = [${libs.join(", ")}] as const;
|
|
51
|
-
`;
|
|
52
|
-
}
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// pkgs/@akanjs/cli/src/templates/lib/__lib/lib.service.ts
|
|
20
|
-
var lib_service_exports = {};
|
|
21
|
-
__export(lib_service_exports, {
|
|
22
|
-
default: () => getContent
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(lib_service_exports);
|
|
25
|
-
var capitalize = (str) => str.charAt(0).toUpperCase() + str.slice(1);
|
|
26
|
-
function getContent(scanInfo, dict = {}) {
|
|
27
|
-
if (!scanInfo)
|
|
28
|
-
return null;
|
|
29
|
-
const libs = scanInfo.getLibs();
|
|
30
|
-
const libInfos = [...scanInfo.getLibInfos().values()];
|
|
31
|
-
const extendedModels = Object.fromEntries(
|
|
32
|
-
[...scanInfo.file.service.databases].map(
|
|
33
|
-
(modelName) => [
|
|
34
|
-
modelName,
|
|
35
|
-
libInfos.filter((libInfo) => libInfo.file.service.databases.has(modelName)).map((libInfo) => libInfo.name)
|
|
36
|
-
]
|
|
37
|
-
).filter(([_, libNames]) => libNames.length > 0)
|
|
38
|
-
);
|
|
39
|
-
return `
|
|
40
|
-
${libs.length ? `import { serve, Srv } from "@akanjs/service";` : `import type { BackendEnv } from "@akanjs/base";`}
|
|
41
|
-
${libs.map((lib) => `import { option as ${lib}Option, srv as ${lib} } from "@${lib}/server";`).join("\n")}
|
|
42
|
-
|
|
43
|
-
import * as db from "../db";
|
|
44
|
-
import type * as srv from "../srv";
|
|
45
|
-
|
|
46
|
-
${libs.map((lib) => `export { srv as ${lib} } from "@${lib}/server";`).join("\n")}
|
|
47
|
-
|
|
48
|
-
${Object.entries(extendedModels).map(([modelName, extendedModels2]) => {
|
|
49
|
-
const ModelName = capitalize(modelName);
|
|
50
|
-
return `export const ${modelName} = {
|
|
51
|
-
services: [${extendedModels2.map((libName) => `${libName}.${ModelName}Service`).join(", ")}] as const,
|
|
52
|
-
}`;
|
|
53
|
-
}).join("\n")}
|
|
54
|
-
|
|
55
|
-
export const libAllSrvs = { ${libs.map((lib) => `...${lib}.allSrvs`).join(", ")} };
|
|
56
|
-
|
|
57
|
-
export type LibOptions = ${libs.length ? libs.map((lib) => `${lib}Option.ModulesOptions`).join(" & ") : "BackendEnv"};
|
|
58
|
-
`;
|
|
59
|
-
}
|