@papit/create 0.0.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/README.md +198 -0
- package/asset/component-templates/browser/src/component.ts +7 -0
- package/asset/component-templates/browser/src/index.ts +3 -0
- package/asset/component-templates/browser/src/types.ts +1 -0
- package/asset/component-templates/browser/tests/index.html +15 -0
- package/asset/component-templates/browser/tests/main.js +1 -0
- package/asset/component-templates/browser/tests/public/icons/.gitkeep +0 -0
- package/asset/component-templates/browser/tests/public/images/.gitkeep +0 -0
- package/asset/component-templates/browser/tests/public/translations/en.json +7 -0
- package/asset/component-templates/browser/tests/snapshot.test.ts +12 -0
- package/asset/component-templates/browser/tests/unit.test.ts +69 -0
- package/asset/component-templates/browser/views/index.html +29 -0
- package/asset/component-templates/browser/views/main.js +13 -0
- package/asset/component-templates/browser/views/public/icons/.gitkeep +0 -0
- package/asset/component-templates/browser/views/public/images/.gitkeep +0 -0
- package/asset/component-templates/browser/views/public/translations/en.json +7 -0
- package/asset/component-templates/browser/views/style.css +28 -0
- package/asset/component-templates/game/src/component.ts +7 -0
- package/asset/component-templates/game/src/index.ts +3 -0
- package/asset/component-templates/game/src/types.ts +1 -0
- package/asset/component-templates/game/tests/index.html +15 -0
- package/asset/component-templates/game/tests/main.js +34 -0
- package/asset/component-templates/game/tests/public/models/.gitkeep +0 -0
- package/asset/component-templates/game/tests/public/textures/.gitkeep +0 -0
- package/asset/component-templates/game/tests/public/translations/en.json +7 -0
- package/asset/component-templates/game/tests/snapshot.test.ts +12 -0
- package/asset/component-templates/game/tests/unit.test.ts +18 -0
- package/asset/component-templates/game/views/index.html +22 -0
- package/asset/component-templates/game/views/main.js +34 -0
- package/asset/component-templates/game/views/public/models/.gitkeep +0 -0
- package/asset/component-templates/game/views/public/textures/.gitkeep +0 -0
- package/asset/component-templates/game/views/public/translations/en.json +7 -0
- package/asset/component-templates/game/views/style.css +9 -0
- package/asset/component-templates/node/src/component.ts +7 -0
- package/asset/component-templates/node/src/index.ts +3 -0
- package/asset/component-templates/node/src/types.ts +1 -0
- package/asset/component-templates/node/tests/unit.test.js +10 -0
- package/asset/component-templates/theme/lib/theme.css +80 -0
- package/asset/component-templates/theme/src/theme.css +205 -0
- package/asset/component-templates/theme/tests/index.html +15 -0
- package/asset/component-templates/theme/tests/main.js +1 -0
- package/asset/component-templates/theme/tests/public/icons/.gitkeep +0 -0
- package/asset/component-templates/theme/tests/public/images/.gitkeep +0 -0
- package/asset/component-templates/theme/tests/public/translations/en.json +7 -0
- package/asset/component-templates/theme/tests/snapshot.test.ts +12 -0
- package/asset/component-templates/theme/tests/unit.test.ts +67 -0
- package/asset/component-templates/theme/views/index.html +110 -0
- package/asset/component-templates/theme/views/main.js +14 -0
- package/asset/component-templates/theme/views/style.css +241 -0
- package/asset/component-templates/web-component/src/component.ts +31 -0
- package/asset/component-templates/web-component/src/index.ts +15 -0
- package/asset/component-templates/web-component/src/style.css +4 -0
- package/asset/component-templates/web-component/src/types.ts +1 -0
- package/asset/component-templates/web-component/tests/index.html +17 -0
- package/asset/component-templates/web-component/tests/main.js +1 -0
- package/asset/component-templates/web-component/tests/public/icons/.gitkeep +0 -0
- package/asset/component-templates/web-component/tests/public/images/.gitkeep +0 -0
- package/asset/component-templates/web-component/tests/public/translations/en.json +7 -0
- package/asset/component-templates/web-component/tests/snapshot.test.ts +12 -0
- package/asset/component-templates/web-component/tests/unit.test.ts +69 -0
- package/asset/component-templates/web-component/views/index.html +28 -0
- package/asset/component-templates/web-component/views/main.js +14 -0
- package/asset/component-templates/web-component/views/public/icons/.gitkeep +0 -0
- package/asset/component-templates/web-component/views/public/images/.gitkeep +0 -0
- package/asset/component-templates/web-component/views/public/translations/en.json +7 -0
- package/asset/component-templates/web-component/views/style.css +28 -0
- package/asset/package-templates/browser/README.md +44 -0
- package/asset/package-templates/browser/asset/icons/.gitkeep +0 -0
- package/asset/package-templates/browser/asset/images/.gitkeep +0 -0
- package/asset/package-templates/browser/asset/translations/en.json +7 -0
- package/asset/package-templates/browser/package.json +76 -0
- package/asset/package-templates/browser/src/.gitkeep +0 -0
- package/asset/package-templates/browser/tests/playwright.config.ts +81 -0
- package/asset/package-templates/browser/tests/tsconfig.json +9 -0
- package/asset/package-templates/browser/tsconfig.json +41 -0
- package/asset/package-templates/browser/tsconfig.prod.json +9 -0
- package/asset/package-templates/game/README.md +40 -0
- package/asset/package-templates/game/asset/models/.gitkeep +0 -0
- package/asset/package-templates/game/asset/textures/.gitkeep +0 -0
- package/asset/package-templates/game/asset/translations/en.json +7 -0
- package/asset/package-templates/game/package.json +78 -0
- package/asset/package-templates/game/src/.gitkeep +0 -0
- package/asset/package-templates/game/tests/playwright.config.ts +80 -0
- package/asset/package-templates/game/tests/tsconfig.json +9 -0
- package/asset/package-templates/game/tsconfig.json +41 -0
- package/asset/package-templates/game/tsconfig.prod.json +9 -0
- package/asset/package-templates/game/views/.gitkeep +0 -0
- package/asset/package-templates/game/views/tsconfig.json +9 -0
- package/asset/package-templates/node/README.md +40 -0
- package/asset/package-templates/node/asset/translations/en.json +7 -0
- package/asset/package-templates/node/package.json +70 -0
- package/asset/package-templates/node/src/.gitkeep +0 -0
- package/asset/package-templates/node/tests/.gitkeep +0 -0
- package/asset/package-templates/node/tests/tsconfig.json +9 -0
- package/asset/package-templates/node/tsconfig.json +38 -0
- package/asset/package-templates/node/tsconfig.prod.json +9 -0
- package/asset/package-templates/theme/README.md +44 -0
- package/asset/package-templates/theme/asset/icons/.gitkeep +0 -0
- package/asset/package-templates/theme/asset/images/.gitkeep +0 -0
- package/asset/package-templates/theme/asset/translations/en.json +7 -0
- package/asset/package-templates/theme/package.json +70 -0
- package/asset/package-templates/theme/tests/playwright.config.ts +81 -0
- package/asset/package-templates/theme/tsconfig.json +39 -0
- package/asset/package-templates/theme/tsconfig.prod.json +9 -0
- package/asset/package-templates/web-component/README.md +55 -0
- package/asset/package-templates/web-component/asset/icons/.gitkeep +0 -0
- package/asset/package-templates/web-component/asset/images/.gitkeep +0 -0
- package/asset/package-templates/web-component/asset/translations/en.json +7 -0
- package/asset/package-templates/web-component/package.json +79 -0
- package/asset/package-templates/web-component/src/global-css.d.ts +4 -0
- package/asset/package-templates/web-component/tests/playwright.config.ts +81 -0
- package/asset/package-templates/web-component/tests/tsconfig.json +9 -0
- package/asset/package-templates/web-component/tsconfig.json +42 -0
- package/asset/package-templates/web-component/tsconfig.prod.json +9 -0
- package/asset/package-templates/web-component/views/.gitkeep +0 -0
- package/asset/package-templates/web-component/views/tsconfig.json +9 -0
- package/asset/project-template/.eslintrc +26 -0
- package/asset/project-template/.gitattributes +1 -0
- package/asset/project-template/.github/ISSUE_TEMPLATE/CONTRIBUTING.md +101 -0
- package/asset/project-template/.github/workflows/build-cache.yml +30 -0
- package/asset/project-template/.github/workflows/initialise.yml +49 -0
- package/asset/project-template/.github/workflows/publish.yml +59 -0
- package/asset/project-template/.github/workflows/pull-request.yml +73 -0
- package/asset/project-template/.github/workflows/update-snapshots.yml +80 -0
- package/asset/project-template/.nvmrc +1 -0
- package/asset/project-template/.vscode/settings.json +19 -0
- package/asset/project-template/.vscode/web-components.code-workspace +25 -0
- package/asset/project-template/README.md +45 -0
- package/asset/project-template/bin/clean.mjs +28 -0
- package/asset/project-template/bin/runners/example-runner/runner.js +4 -0
- package/asset/project-template/bin/spawn-command.mjs +31 -0
- package/asset/project-template/bin/test.mjs +94 -0
- package/asset/project-template/package.json +42 -0
- package/asset/project-template/packages/atoms/.gitkeep +0 -0
- package/asset/project-template/packages/molecules/.gitkeep +0 -0
- package/asset/project-template/packages/organisms/.gitkeep +0 -0
- package/asset/project-template/packages/pages/.gitkeep +0 -0
- package/asset/project-template/packages/templates/.gitkeep +0 -0
- package/lib/bundle.d.ts +1 -0
- package/lib/bundle.js +4 -0
- package/package.json +72 -0
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { Arguments } from "@papit/arguments";
|
|
2
|
+
import { Information, PackageGraph } from "@papit/information";
|
|
3
|
+
import { defineConfig, devices } from '@playwright/test';
|
|
4
|
+
import path from "node:path";
|
|
5
|
+
|
|
6
|
+
const dirname = path.join(PackageGraph.get("VARIABLE_FULL_NAME").location, "tests");
|
|
7
|
+
// const relative = path.relative(Information.root.location, PackageGraph.get("@papit/web-component").location);
|
|
8
|
+
|
|
9
|
+
export default defineConfig({
|
|
10
|
+
// Look for test files in the "tests" directory, relative to this configuration file.
|
|
11
|
+
testDir: dirname,
|
|
12
|
+
|
|
13
|
+
// Run all tests in parallel.
|
|
14
|
+
fullyParallel: true,
|
|
15
|
+
|
|
16
|
+
// Fail the build on CI if you accidentally left test.only in the source code.
|
|
17
|
+
forbidOnly: !!process.env.CI,
|
|
18
|
+
|
|
19
|
+
// Retry on CI only.
|
|
20
|
+
retries: 0,
|
|
21
|
+
|
|
22
|
+
// Opt out of parallel tests on CI.
|
|
23
|
+
workers: !!process.env.CI ? 1 : undefined,
|
|
24
|
+
|
|
25
|
+
// reporter, with output path for HTML reports.
|
|
26
|
+
reporter: [[
|
|
27
|
+
!!process.env.CI ? "github" : "html",
|
|
28
|
+
{
|
|
29
|
+
open: "never",
|
|
30
|
+
outputFolder: path.join(dirname, "test-reports"),
|
|
31
|
+
}
|
|
32
|
+
]],
|
|
33
|
+
|
|
34
|
+
outputDir: path.join(dirname, "test-results"),
|
|
35
|
+
|
|
36
|
+
snapshotPathTemplate: '{testDir}/snapshots/{projectName}/{testFilePath}/{arg}-{platform}{ext}',
|
|
37
|
+
|
|
38
|
+
use: {
|
|
39
|
+
// Base URL to use in actions like `await page.goto('/')`.
|
|
40
|
+
baseURL: process.env.LOCATION ? `http://localhost:3500/${process.env.LOCATION}/` : 'http://localhost:3500/',
|
|
41
|
+
|
|
42
|
+
// Collect trace when retrying the failed test.
|
|
43
|
+
trace: 'on-first-retry',
|
|
44
|
+
screenshot: 'only-on-failure',
|
|
45
|
+
},
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
expect: {
|
|
49
|
+
toHaveScreenshot: {
|
|
50
|
+
maxDiffPixels: 100,
|
|
51
|
+
maxDiffPixelRatio: 0.2,
|
|
52
|
+
},
|
|
53
|
+
},
|
|
54
|
+
testIgnore: process.env.SKIP_SNAPSHOTS === "true"
|
|
55
|
+
? ["**/snapshot.test.ts"]
|
|
56
|
+
: [],
|
|
57
|
+
|
|
58
|
+
// Configure projects for major browsers.
|
|
59
|
+
projects: [
|
|
60
|
+
{
|
|
61
|
+
name: 'chromium',
|
|
62
|
+
use: { ...devices['Desktop Chrome'] },
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
name: 'firefox',
|
|
66
|
+
use: { ...devices['Desktop Firefox'] },
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
name: 'webkit',
|
|
70
|
+
use: { ...devices['Desktop Safari'] },
|
|
71
|
+
},
|
|
72
|
+
],
|
|
73
|
+
// running web-server before starting tests
|
|
74
|
+
webServer: {
|
|
75
|
+
command: 'npx @papit/server --serve --port=3500 --bundle',
|
|
76
|
+
url: 'http://localhost:3500',
|
|
77
|
+
reuseExistingServer: true,
|
|
78
|
+
stdout: 'pipe',
|
|
79
|
+
stderr: 'pipe'
|
|
80
|
+
},
|
|
81
|
+
});
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "es2018",
|
|
4
|
+
"module": "esnext",
|
|
5
|
+
"moduleResolution": "bundler",
|
|
6
|
+
// "moduleDetection": "force",
|
|
7
|
+
"noEmitOnError": true,
|
|
8
|
+
"skipLibCheck": true,
|
|
9
|
+
"lib": [
|
|
10
|
+
"es2020",
|
|
11
|
+
"dom",
|
|
12
|
+
"dom.iterable",
|
|
13
|
+
"esnext"
|
|
14
|
+
],
|
|
15
|
+
"strict": true,
|
|
16
|
+
"verbatimModuleSyntax": false,
|
|
17
|
+
"noUncheckedIndexedAccess": false, // use me for strict array/object access checks
|
|
18
|
+
"esModuleInterop": true,
|
|
19
|
+
"allowSyntheticDefaultImports": true,
|
|
20
|
+
"experimentalDecorators": true,
|
|
21
|
+
"useDefineForClassFields": false,
|
|
22
|
+
"outDir": "lib",
|
|
23
|
+
"rootDir": "src",
|
|
24
|
+
"declaration": true,
|
|
25
|
+
"resolveJsonModule": true,
|
|
26
|
+
"allowJs": true,
|
|
27
|
+
"baseUrl": "src",
|
|
28
|
+
"paths": {
|
|
29
|
+
"VARIABLE_FULL_NAME": [
|
|
30
|
+
"./index"
|
|
31
|
+
]
|
|
32
|
+
},
|
|
33
|
+
"sourceMap": true,
|
|
34
|
+
"inlineSources": true,
|
|
35
|
+
"incremental": true,
|
|
36
|
+
"tsBuildInfoFile": ".temp/build/tsconfig.tsbuildinfo",
|
|
37
|
+
},
|
|
38
|
+
"include": [
|
|
39
|
+
"src"
|
|
40
|
+
]
|
|
41
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# VARIABLE_FULL_NAME
|
|
2
|
+
|
|
3
|
+
VARIABLE_DESCRIPTION
|
|
4
|
+
|
|
5
|
+

|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+

|
|
10
|
+
[](VARIABLE_GITHUB_REPO/actions/workflows/pull-request.yml)
|
|
11
|
+
[](https://www.npmjs.com/package/VARIABLE_FULL_NAME)
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## installation
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
npm install VARIABLE_FULL_NAME
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Contributing
|
|
22
|
+
|
|
23
|
+
Contributions are welcome! Please follow the development guidelines above and ensure all tests pass before submitting a pull request.
|
|
24
|
+
|
|
25
|
+
## License
|
|
26
|
+
|
|
27
|
+
Licensed under the @Papit License 1.0 - Copyright (c) 2024 Henry Pap (@onkelhoy)
|
|
28
|
+
|
|
29
|
+
**Key points:**
|
|
30
|
+
|
|
31
|
+
- ✅ Free to use in commercial projects
|
|
32
|
+
- ✅ Free to modify and distribute
|
|
33
|
+
- ✅ Attribution required
|
|
34
|
+
- ❌ Cannot resell the component itself as a standalone product
|
|
35
|
+
|
|
36
|
+
See the [LICENSE](https://github.com/onkelhoy/papit/blob/main/LICENSE) file for full details.
|
|
37
|
+
|
|
38
|
+
## Support
|
|
39
|
+
|
|
40
|
+
For issues, questions, or contributions, please visit the [GitHub repository](https://github.com/onkelhoy/papit).
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "VARIABLE_FULL_NAME",
|
|
3
|
+
"description": "VARIABLE_DESCRIPTION",
|
|
4
|
+
"keywords": [
|
|
5
|
+
"papit",
|
|
6
|
+
"game",
|
|
7
|
+
"typescript",
|
|
8
|
+
"VARIABLE_NAME"
|
|
9
|
+
],
|
|
10
|
+
"version": "0.0.1",
|
|
11
|
+
"scripts": {
|
|
12
|
+
"build": "npx @papit/build -- --error --ancestors",
|
|
13
|
+
"watch": "tsc -w",
|
|
14
|
+
"start": "npx @papit/server --info --live",
|
|
15
|
+
"test": "npx playwright test -c tests/playwright.config.ts $@",
|
|
16
|
+
"preversion": "papit-version",
|
|
17
|
+
"postversion": "papit-version",
|
|
18
|
+
"component": "npm create @papit -- --component",
|
|
19
|
+
"test:update-snapshots": "npx playwright test --update-snapshots -c tests/playwright.config.ts",
|
|
20
|
+
"test:chrome": "npm test -- --project=chromium"
|
|
21
|
+
},
|
|
22
|
+
"main": "./lib/bundle.js",
|
|
23
|
+
"types": "./lib/bundle.d.ts",
|
|
24
|
+
"type": "module",
|
|
25
|
+
"files": [
|
|
26
|
+
"asset/",
|
|
27
|
+
"lib/"
|
|
28
|
+
],
|
|
29
|
+
"exports": {
|
|
30
|
+
".": {
|
|
31
|
+
"import": "./lib/bundle.js",
|
|
32
|
+
"types": "./lib/bundle.d.ts"
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
"author": "VARIABLE_USER",
|
|
36
|
+
"private": false,
|
|
37
|
+
"publishConfig": {
|
|
38
|
+
"access": "public",
|
|
39
|
+
"registry": "https://registry.npmjs.org/"
|
|
40
|
+
},
|
|
41
|
+
"license": "VARIABLE_PROJECTLICENSE",
|
|
42
|
+
"homepage": "VARIABLE_GITHUB_REPO/tree/main/VARIABLE_LOCAL_DESTINATION",
|
|
43
|
+
"bugs": {
|
|
44
|
+
"url": "VARIABLE_GITHUB_REPO/issues"
|
|
45
|
+
},
|
|
46
|
+
"repository": {
|
|
47
|
+
"type": "git",
|
|
48
|
+
"url": "VARIABLE_GITHUB_REPO.git",
|
|
49
|
+
"directory": "VARIABLE_LOCAL_DESTINATION"
|
|
50
|
+
},
|
|
51
|
+
"sideEffects": true,
|
|
52
|
+
"engines": {
|
|
53
|
+
"node": ">=18"
|
|
54
|
+
},
|
|
55
|
+
"dependencies": {},
|
|
56
|
+
"devDependencies": {
|
|
57
|
+
"@playwright/test": "1.58.0",
|
|
58
|
+
"playwright": "1.58.0",
|
|
59
|
+
"typescript": "5.9.3",
|
|
60
|
+
"@papit/theme": "*",
|
|
61
|
+
"@papit/translator": "*",
|
|
62
|
+
"@papit/codeblock": "*",
|
|
63
|
+
"@papit/game-engine": "*",
|
|
64
|
+
"@papit/game-input-events": "*",
|
|
65
|
+
"@papit/game-vector": "*"
|
|
66
|
+
},
|
|
67
|
+
"browserslist": [
|
|
68
|
+
"defaults",
|
|
69
|
+
"not IE 11",
|
|
70
|
+
"not dead"
|
|
71
|
+
],
|
|
72
|
+
"papit": {
|
|
73
|
+
"publish": true,
|
|
74
|
+
"type": "game",
|
|
75
|
+
"main": "VARIABLE_NAME",
|
|
76
|
+
"components": {}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
File without changes
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { defineConfig, devices } from '@playwright/test';
|
|
2
|
+
import path from "node:path";
|
|
3
|
+
import { fileURLToPath } from 'node:url';
|
|
4
|
+
|
|
5
|
+
// Resolve the directory name and base path for ES modules
|
|
6
|
+
const __filename = fileURLToPath(import.meta.url);
|
|
7
|
+
const __dirname = path.dirname(__filename);
|
|
8
|
+
|
|
9
|
+
export default defineConfig({
|
|
10
|
+
// Look for test files in the "tests" directory, relative to this configuration file.
|
|
11
|
+
testDir: __dirname,
|
|
12
|
+
|
|
13
|
+
// Run all tests in parallel.
|
|
14
|
+
fullyParallel: true,
|
|
15
|
+
|
|
16
|
+
// Fail the build on CI if you accidentally left test.only in the source code.
|
|
17
|
+
forbidOnly: !!process.env.CI,
|
|
18
|
+
|
|
19
|
+
// Retry on CI only.
|
|
20
|
+
retries: 0,
|
|
21
|
+
|
|
22
|
+
// Opt out of parallel tests on CI.
|
|
23
|
+
workers: process.env.CI ? 1 : undefined,
|
|
24
|
+
|
|
25
|
+
// reporter, with output path for HTML reports.
|
|
26
|
+
reporter: [
|
|
27
|
+
process.env.CI ? ['github', {
|
|
28
|
+
open: 'never',
|
|
29
|
+
outputFolder: path.join(__dirname, 'test-reports'),
|
|
30
|
+
}] : ['html', {
|
|
31
|
+
open: 'never',
|
|
32
|
+
outputFolder: path.join(__dirname, 'test-reports'),
|
|
33
|
+
}],
|
|
34
|
+
],
|
|
35
|
+
|
|
36
|
+
outputDir: path.join(__dirname, "test-results"),
|
|
37
|
+
|
|
38
|
+
snapshotPathTemplate: '{testDir}/snapshots/{projectName}/{testFilePath}/{arg}-{platform}{ext}',
|
|
39
|
+
|
|
40
|
+
use: {
|
|
41
|
+
// Base URL to use in actions like `await page.goto('/')`.
|
|
42
|
+
baseURL: process.env.CI ? `http://localhost:3500/${process.env.LAYER_FOLDER}/${process.env.NAME}/tests/` : 'http://localhost:3500/',
|
|
43
|
+
|
|
44
|
+
// Collect trace when retrying the failed test.
|
|
45
|
+
trace: 'on-first-retry',
|
|
46
|
+
screenshot: 'only-on-failure',
|
|
47
|
+
},
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
expect: {
|
|
51
|
+
toHaveScreenshot: {
|
|
52
|
+
maxDiffPixels: 100,
|
|
53
|
+
maxDiffPixelRatio: 0.2,
|
|
54
|
+
},
|
|
55
|
+
},
|
|
56
|
+
|
|
57
|
+
// Configure projects for major browsers.
|
|
58
|
+
projects: [
|
|
59
|
+
{
|
|
60
|
+
name: 'chromium',
|
|
61
|
+
use: { ...devices['Desktop Chrome'] },
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
name: 'firefox',
|
|
65
|
+
use: { ...devices['Desktop Firefox'] },
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
name: 'webkit',
|
|
69
|
+
use: { ...devices['Desktop Safari'] },
|
|
70
|
+
},
|
|
71
|
+
],
|
|
72
|
+
// running web-server before starting tests
|
|
73
|
+
webServer: {
|
|
74
|
+
command: 'npm run server --include-workspace-root=true --workspace="$(npm prefix)" -- --rootdir="$(npm prefix)" --log-level=debug --location=$(pwd) --nosig --port=3500',
|
|
75
|
+
url: 'http://localhost:3500',
|
|
76
|
+
reuseExistingServer: true,
|
|
77
|
+
stdout: 'ignore',
|
|
78
|
+
stderr: 'pipe'
|
|
79
|
+
},
|
|
80
|
+
});
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "es2018",
|
|
4
|
+
"module": "esnext",
|
|
5
|
+
"moduleResolution": "bundler",
|
|
6
|
+
// "moduleDetection": "force",
|
|
7
|
+
"noEmitOnError": true,
|
|
8
|
+
"skipLibCheck": true,
|
|
9
|
+
"lib": [
|
|
10
|
+
"es2020",
|
|
11
|
+
"dom",
|
|
12
|
+
"dom.iterable",
|
|
13
|
+
"esnext"
|
|
14
|
+
],
|
|
15
|
+
"strict": true,
|
|
16
|
+
"verbatimModuleSyntax": false,
|
|
17
|
+
"noUncheckedIndexedAccess": false, // use me for strict array/object access checks
|
|
18
|
+
"esModuleInterop": true,
|
|
19
|
+
"allowSyntheticDefaultImports": true,
|
|
20
|
+
"experimentalDecorators": true,
|
|
21
|
+
"useDefineForClassFields": false,
|
|
22
|
+
"outDir": "lib",
|
|
23
|
+
"rootDir": "src",
|
|
24
|
+
"declaration": true,
|
|
25
|
+
"resolveJsonModule": true,
|
|
26
|
+
"allowJs": true,
|
|
27
|
+
"baseUrl": "src",
|
|
28
|
+
"paths": {
|
|
29
|
+
"VARIABLE_FULL_NAME": [
|
|
30
|
+
"./index"
|
|
31
|
+
]
|
|
32
|
+
},
|
|
33
|
+
"sourceMap": true,
|
|
34
|
+
"inlineSources": true,
|
|
35
|
+
"incremental": true,
|
|
36
|
+
"tsBuildInfoFile": ".temp/build/tsconfig.tsbuildinfo",
|
|
37
|
+
},
|
|
38
|
+
"include": [
|
|
39
|
+
"src"
|
|
40
|
+
]
|
|
41
|
+
}
|
|
File without changes
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# VARIABLE_FULL_NAME
|
|
2
|
+
|
|
3
|
+
VARIABLE_DESCRIPTION
|
|
4
|
+
|
|
5
|
+

|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+

|
|
10
|
+
[](VARIABLE_GITHUB_REPO/actions/workflows/pull-request.yml)
|
|
11
|
+
[](https://www.npmjs.com/package/VARIABLE_FULL_NAME)
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## installation
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
npm install VARIABLE_FULL_NAME
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Contributing
|
|
22
|
+
|
|
23
|
+
Contributions are welcome! Please follow the development guidelines above and ensure all tests pass before submitting a pull request.
|
|
24
|
+
|
|
25
|
+
## License
|
|
26
|
+
|
|
27
|
+
Licensed under the @Papit License 1.0 - Copyright (c) 2024 Henry Pap (@onkelhoy)
|
|
28
|
+
|
|
29
|
+
**Key points:**
|
|
30
|
+
|
|
31
|
+
- ✅ Free to use in commercial projects
|
|
32
|
+
- ✅ Free to modify and distribute
|
|
33
|
+
- ✅ Attribution required
|
|
34
|
+
- ❌ Cannot resell the component itself as a standalone product
|
|
35
|
+
|
|
36
|
+
See the [LICENSE](https://github.com/onkelhoy/papit/blob/main/LICENSE) file for full details.
|
|
37
|
+
|
|
38
|
+
## Support
|
|
39
|
+
|
|
40
|
+
For issues, questions, or contributions, please visit the [GitHub repository](https://github.com/onkelhoy/papit).
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "VARIABLE_FULL_NAME",
|
|
3
|
+
"description": "VARIABLE_DESCRIPTION",
|
|
4
|
+
"keywords": [
|
|
5
|
+
"papit",
|
|
6
|
+
"node",
|
|
7
|
+
"typescript",
|
|
8
|
+
"VARIABLE_NAME"
|
|
9
|
+
],
|
|
10
|
+
"version": "0.0.1",
|
|
11
|
+
"scripts": {
|
|
12
|
+
"build": "npx @papit/build --error",
|
|
13
|
+
"watch": "tsc -w",
|
|
14
|
+
"start": "npm run build -- --dev && node ./lib/bundle.js",
|
|
15
|
+
"test": "node --test tests/**/*.test.js",
|
|
16
|
+
"test:only": "node --test --test-only tests/**/*.test.js",
|
|
17
|
+
"preversion": "papit-version",
|
|
18
|
+
"postversion": "papit-version",
|
|
19
|
+
"component": "npm create @papit -- --component"
|
|
20
|
+
},
|
|
21
|
+
"main": "./lib/bundle.js",
|
|
22
|
+
"types": "./lib/bundle.d.ts",
|
|
23
|
+
"type": "module",
|
|
24
|
+
"files": [
|
|
25
|
+
"asset/",
|
|
26
|
+
"lib/"
|
|
27
|
+
],
|
|
28
|
+
"exports": {
|
|
29
|
+
".": {
|
|
30
|
+
"import": "./lib/bundle.js",
|
|
31
|
+
"types": "./lib/bundle.d.ts"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"author": "VARIABLE_USER",
|
|
35
|
+
"private": false,
|
|
36
|
+
"publishConfig": {
|
|
37
|
+
"access": "public",
|
|
38
|
+
"registry": "https://registry.npmjs.org/"
|
|
39
|
+
},
|
|
40
|
+
"license": "VARIABLE_PROJECTLICENSE",
|
|
41
|
+
"homepage": "VARIABLE_GITHUB_REPO/tree/main/VARIABLE_LOCAL_DESTINATION",
|
|
42
|
+
"bugs": {
|
|
43
|
+
"url": "VARIABLE_GITHUB_REPO/issues"
|
|
44
|
+
},
|
|
45
|
+
"repository": {
|
|
46
|
+
"type": "git",
|
|
47
|
+
"url": "VARIABLE_GITHUB_REPO.git",
|
|
48
|
+
"directory": "VARIABLE_LOCAL_DESTINATION"
|
|
49
|
+
},
|
|
50
|
+
"sideEffects": true,
|
|
51
|
+
"engines": {
|
|
52
|
+
"node": ">=18"
|
|
53
|
+
},
|
|
54
|
+
"dependencies": {},
|
|
55
|
+
"devDependencies": {
|
|
56
|
+
"@types/node": "22.10.2",
|
|
57
|
+
"typescript": "5.9.3"
|
|
58
|
+
},
|
|
59
|
+
"browserslist": [
|
|
60
|
+
"defaults",
|
|
61
|
+
"not IE 11",
|
|
62
|
+
"not dead"
|
|
63
|
+
],
|
|
64
|
+
"papit": {
|
|
65
|
+
"publish": true,
|
|
66
|
+
"type": "node",
|
|
67
|
+
"main": "VARIABLE_NAME",
|
|
68
|
+
"components": {}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "es2022",
|
|
4
|
+
"module": "esnext",
|
|
5
|
+
"moduleResolution": "bundler",
|
|
6
|
+
// "moduleDetection": "force",
|
|
7
|
+
"noEmitOnError": true,
|
|
8
|
+
"skipLibCheck": true,
|
|
9
|
+
"lib": [
|
|
10
|
+
"es2022"
|
|
11
|
+
],
|
|
12
|
+
"strict": true,
|
|
13
|
+
"verbatimModuleSyntax": false,
|
|
14
|
+
"noUncheckedIndexedAccess": false, // use me for strict array/object access checks
|
|
15
|
+
"esModuleInterop": true,
|
|
16
|
+
"allowSyntheticDefaultImports": true,
|
|
17
|
+
"experimentalDecorators": true,
|
|
18
|
+
"useDefineForClassFields": false,
|
|
19
|
+
"outDir": "lib",
|
|
20
|
+
"rootDir": "src",
|
|
21
|
+
"declaration": true,
|
|
22
|
+
"resolveJsonModule": true,
|
|
23
|
+
"allowJs": true,
|
|
24
|
+
"baseUrl": "src",
|
|
25
|
+
"paths": {
|
|
26
|
+
"VARIABLE_FULL_NAME": [
|
|
27
|
+
"./index"
|
|
28
|
+
]
|
|
29
|
+
},
|
|
30
|
+
"sourceMap": true,
|
|
31
|
+
"inlineSources": true,
|
|
32
|
+
"incremental": true,
|
|
33
|
+
"tsBuildInfoFile": ".temp/build/tsconfig.tsbuildinfo",
|
|
34
|
+
},
|
|
35
|
+
"include": [
|
|
36
|
+
"src"
|
|
37
|
+
]
|
|
38
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# VARIABLE_FULL_NAME
|
|
2
|
+
|
|
3
|
+
VARIABLE_DESCRIPTION
|
|
4
|
+
|
|
5
|
+

|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+

|
|
10
|
+
[](VARIABLE_GITHUB_REPO/actions/workflows/pull-request.yml)
|
|
11
|
+
[](https://www.npmjs.com/package/VARIABLE_FULL_NAME)
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## installation
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
npm install VARIABLE_FULL_NAME
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Contributing
|
|
22
|
+
|
|
23
|
+
Contributions are welcome! Please follow the development guidelines above and ensure all tests pass before submitting a pull request.
|
|
24
|
+
|
|
25
|
+
## License
|
|
26
|
+
|
|
27
|
+
Licensed under the @Papit License 1.0 - Copyright (c) 2024 Henry Pap (@onkelhoy)
|
|
28
|
+
|
|
29
|
+
**Key points:**
|
|
30
|
+
|
|
31
|
+
- ✅ Free to use in commercial projects
|
|
32
|
+
- ✅ Free to modify and distribute
|
|
33
|
+
- ✅ Attribution required
|
|
34
|
+
- ❌ Cannot resell the component itself as a standalone product
|
|
35
|
+
|
|
36
|
+
See the [LICENSE](https://github.com/onkelhoy/papit/blob/main/LICENSE) file for full details.
|
|
37
|
+
|
|
38
|
+
## Related Components
|
|
39
|
+
|
|
40
|
+
- [@papit/web-component](https://github.com/onkelhoy/papit/tree/main/packages/system/core): Core utilities, decorators, and base component class
|
|
41
|
+
|
|
42
|
+
## Support
|
|
43
|
+
|
|
44
|
+
For issues, questions, or contributions, please visit the [GitHub repository](https://github.com/onkelhoy/papit).
|
|
File without changes
|
|
File without changes
|