@loopstack/contracts 0.16.2 → 0.18.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/dist/enums/registry.enum.d.ts +1 -2
- package/dist/enums/registry.enum.js +0 -1
- package/dist/schemas/assignment.schema.d.ts +2 -2
- package/dist/schemas/assignment.schema.js +2 -2
- package/dist/schemas/block.schema.d.ts +1 -1
- package/dist/schemas/document.schema.d.ts +111 -742
- package/dist/schemas/json-schema.schema.d.ts +42 -1
- package/dist/schemas/json-schema.schema.js +6 -6
- package/dist/schemas/main.schema.d.ts +88 -1019
- package/dist/schemas/pipeline.schema.d.ts +62 -827
- package/dist/schemas/startup.schema.d.ts +23 -544
- package/dist/schemas/tool-call.schema.d.ts +4 -24
- package/dist/schemas/tool-config.schema.d.ts +10 -160
- package/dist/schemas/transition-payload.schema.d.ts +1 -11
- package/dist/schemas/ui-form-element.schema.d.ts +4 -64
- package/dist/schemas/ui-form.schema.d.ts +25 -249
- package/dist/schemas/ui-form.schema.js +3 -3
- package/dist/schemas/ui-properties-schema.js +1 -1
- package/dist/schemas/workflow-transition.schema.d.ts +18 -84
- package/dist/schemas/workflow.schema.d.ts +30 -398
- package/dist/schemas/workspace.schema.d.ts +1 -9
- package/dist/types/interfaces/namespace-create.interface.d.ts +3 -1
- package/dist/types/types/main.type.d.ts +1 -1
- package/package.json +14 -35
- package/.github/workflows/publish-npm.yml +0 -83
- package/.husky/pre-commit +0 -3
- package/.prettierignore +0 -15
- package/LICENSE +0 -43
- package/README.md +0 -7
- package/eslint.config.mjs +0 -21
- package/prettier.config.mjs +0 -19
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@loopstack/contracts",
|
|
3
3
|
"displayName": "Loopstack Contracts",
|
|
4
4
|
"description": "A collection of types and schemas shared between projects",
|
|
5
|
-
"version": "0.
|
|
5
|
+
"version": "0.18.0-rc.0",
|
|
6
6
|
"license": "BSL",
|
|
7
7
|
"author": {
|
|
8
8
|
"name": "Jakob Klippel",
|
|
@@ -24,6 +24,19 @@
|
|
|
24
24
|
"default": "./dist/schemas/index.js"
|
|
25
25
|
}
|
|
26
26
|
},
|
|
27
|
+
"scripts": {
|
|
28
|
+
"build": "tsc",
|
|
29
|
+
"compile": "tsc --noEmit",
|
|
30
|
+
"format": "prettier --write .",
|
|
31
|
+
"lint": "eslint .",
|
|
32
|
+
"watch": "tsc --watch"
|
|
33
|
+
},
|
|
34
|
+
"dependencies": {
|
|
35
|
+
"zod": "^4.3.5"
|
|
36
|
+
},
|
|
37
|
+
"files": [
|
|
38
|
+
"dist"
|
|
39
|
+
],
|
|
27
40
|
"typesVersions": {
|
|
28
41
|
"*": {
|
|
29
42
|
"types": [
|
|
@@ -36,39 +49,5 @@
|
|
|
36
49
|
"./dist/schemas/index.d.ts"
|
|
37
50
|
]
|
|
38
51
|
}
|
|
39
|
-
},
|
|
40
|
-
"scripts": {
|
|
41
|
-
"build": "tsc -p tsconfig.json",
|
|
42
|
-
"watch": "tsc --watch",
|
|
43
|
-
"compile": "tsc --noEmit",
|
|
44
|
-
"lint": "eslint .",
|
|
45
|
-
"format": "prettier --write .",
|
|
46
|
-
"prepare": "husky"
|
|
47
|
-
},
|
|
48
|
-
"peerDependencies": {
|
|
49
|
-
"zod": "^3.25.76"
|
|
50
|
-
},
|
|
51
|
-
"devDependencies": {
|
|
52
|
-
"@eslint/js": "^9.39.1",
|
|
53
|
-
"@trivago/prettier-plugin-sort-imports": "^6.0.1",
|
|
54
|
-
"@types/node": "^22.13.4",
|
|
55
|
-
"eslint": "^9.39.1",
|
|
56
|
-
"eslint-config-prettier": "^10.1.5",
|
|
57
|
-
"eslint-plugin-prettier": "^5.4.1",
|
|
58
|
-
"globals": "^16.5.0",
|
|
59
|
-
"husky": "^9.1.7",
|
|
60
|
-
"lint-staged": "^16.2.7",
|
|
61
|
-
"prettier": "^3.7.4",
|
|
62
|
-
"typescript": "^5.7.3",
|
|
63
|
-
"typescript-eslint": "^8.46.3",
|
|
64
|
-
"zod": "^3.25.76"
|
|
65
|
-
},
|
|
66
|
-
"lint-staged": {
|
|
67
|
-
"*.{ts,tsx}": [
|
|
68
|
-
"eslint"
|
|
69
|
-
],
|
|
70
|
-
"*.{json,md,css,yaml,yml}": [
|
|
71
|
-
"prettier --check"
|
|
72
|
-
]
|
|
73
52
|
}
|
|
74
53
|
}
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
name: 'Publish to NPM Workflow'
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
tags:
|
|
6
|
-
- 'v*.*.*'
|
|
7
|
-
|
|
8
|
-
jobs:
|
|
9
|
-
publish:
|
|
10
|
-
name: 'Build & Publish to NPM'
|
|
11
|
-
runs-on: ubuntu-latest
|
|
12
|
-
timeout-minutes: 15
|
|
13
|
-
permissions:
|
|
14
|
-
contents: write
|
|
15
|
-
id-token: write
|
|
16
|
-
steps:
|
|
17
|
-
- name: Checkout Code
|
|
18
|
-
uses: actions/checkout@v4
|
|
19
|
-
with:
|
|
20
|
-
fetch-depth: 0
|
|
21
|
-
|
|
22
|
-
- name: Check if tag is on main branch
|
|
23
|
-
run: |
|
|
24
|
-
git fetch origin main
|
|
25
|
-
if ! git branch -r --contains ${{ github.ref }} | grep -q 'origin/main'; then
|
|
26
|
-
echo "❌ Tag is not on main branch"
|
|
27
|
-
exit 1
|
|
28
|
-
fi
|
|
29
|
-
echo "✅ Tag is on main branch"
|
|
30
|
-
|
|
31
|
-
- name: Setup Node.js
|
|
32
|
-
uses: actions/setup-node@v4
|
|
33
|
-
with:
|
|
34
|
-
node-version: '20'
|
|
35
|
-
cache: 'npm'
|
|
36
|
-
registry-url: 'https://registry.npmjs.org'
|
|
37
|
-
|
|
38
|
-
- name: Extract Package Version
|
|
39
|
-
id: package
|
|
40
|
-
run: |
|
|
41
|
-
echo "name=$(node -p "require('./package.json').name")" >> $GITHUB_OUTPUT
|
|
42
|
-
echo "version=$(node -p "require('./package.json').version")" >> $GITHUB_OUTPUT
|
|
43
|
-
|
|
44
|
-
- name: Validate Version Matches Tag
|
|
45
|
-
run: |
|
|
46
|
-
TAG_VERSION=${GITHUB_REF#refs/tags/v}
|
|
47
|
-
PKG_VERSION=${{ steps.package.outputs.version }}
|
|
48
|
-
if [ "$TAG_VERSION" != "$PKG_VERSION" ]; then
|
|
49
|
-
echo "❌ Tag version ($TAG_VERSION) does not match package.json version ($PKG_VERSION)"
|
|
50
|
-
exit 1
|
|
51
|
-
fi
|
|
52
|
-
echo "✅ Versions match"
|
|
53
|
-
|
|
54
|
-
- name: Install Dependencies
|
|
55
|
-
run: npm ci
|
|
56
|
-
|
|
57
|
-
- name: Build Package
|
|
58
|
-
run: npm run build --if-present
|
|
59
|
-
|
|
60
|
-
- name: Publish to NPM
|
|
61
|
-
run: npm publish --access public
|
|
62
|
-
env:
|
|
63
|
-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
64
|
-
|
|
65
|
-
- name: Create GitHub Release
|
|
66
|
-
uses: softprops/action-gh-release@v2
|
|
67
|
-
if: success()
|
|
68
|
-
with:
|
|
69
|
-
tag_name: ${{ github.ref_name }}
|
|
70
|
-
body: |
|
|
71
|
-
## 📦 NPM Package
|
|
72
|
-
|
|
73
|
-
**Package:** [${{ steps.package.outputs.name }}](https://www.npmjs.com/package/${{ steps.package.outputs.name }}/v/${{ steps.package.outputs.version }})
|
|
74
|
-
**Version:** ${{ steps.package.outputs.version }}
|
|
75
|
-
|
|
76
|
-
Install with:
|
|
77
|
-
```bash
|
|
78
|
-
npm install ${{ steps.package.outputs.name }}@${{ steps.package.outputs.version }}
|
|
79
|
-
```
|
|
80
|
-
draft: false
|
|
81
|
-
prerelease: false
|
|
82
|
-
env:
|
|
83
|
-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
package/.husky/pre-commit
DELETED
package/.prettierignore
DELETED
package/LICENSE
DELETED
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
Business Source License 1.1
|
|
2
|
-
|
|
3
|
-
Parameters
|
|
4
|
-
----------
|
|
5
|
-
Licensor: Loopstack GmbH
|
|
6
|
-
Licensed Work: Loopstack Shared Module (the "Licensed Work")
|
|
7
|
-
Additional Use Grant: You may freely use, copy, modify, and distribute the Licensed Work
|
|
8
|
-
for both personal and commercial purposes, subject to the conditions below.
|
|
9
|
-
Change Date: Four years after the release date of each version.
|
|
10
|
-
Change License: Apache License, Version 2.0
|
|
11
|
-
|
|
12
|
-
Terms
|
|
13
|
-
-----
|
|
14
|
-
1. License Grant
|
|
15
|
-
The Licensed Work is made available under the terms of this Business Source License (the "License").
|
|
16
|
-
You are granted the right to use, copy, modify, and distribute the Licensed Work for any
|
|
17
|
-
personal or commercial purpose, provided that:
|
|
18
|
-
|
|
19
|
-
- You do not provide the Licensed Work to third parties as a managed or hosted service
|
|
20
|
-
where the primary value of the service is the Licensed Work itself, or a substantial
|
|
21
|
-
substitute for it.
|
|
22
|
-
- You comply with attribution requirements by including this License file with any distribution.
|
|
23
|
-
|
|
24
|
-
2. Change License
|
|
25
|
-
On the Change Date, each version of the Licensed Work will automatically be
|
|
26
|
-
made available under the Change License (Apache License 2.0).
|
|
27
|
-
|
|
28
|
-
3. Contributions
|
|
29
|
-
Any contributions to the Licensed Work will be licensed under the terms of this License
|
|
30
|
-
until the Change Date, and under the Change License thereafter.
|
|
31
|
-
|
|
32
|
-
4. Disclaimer
|
|
33
|
-
The Licensed Work is provided "as is," without warranty of any kind, express or implied.
|
|
34
|
-
|
|
35
|
-
Additional Terms
|
|
36
|
-
----------------
|
|
37
|
-
- This License does not grant you any rights to use the Licensor's trademarks or brand.
|
|
38
|
-
- This License explicitly permits both personal and commercial use of the Licensed Work,
|
|
39
|
-
including incorporation into commercial products and services, subject to the restrictions
|
|
40
|
-
outlined in Section 1.
|
|
41
|
-
|
|
42
|
-
For details on the Apache License 2.0 (effective after the Change Date), see:
|
|
43
|
-
https://www.apache.org/licenses/LICENSE-2.0
|
package/README.md
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
# Loopstack Contracts: Types and Schemas
|
|
2
|
-
|
|
3
|
-
This is a submodule of the **Loopstack** framework.
|
|
4
|
-
|
|
5
|
-
For full documentation, contribution guidelines, and to get started with Loopstack, please visit the main repository:
|
|
6
|
-
|
|
7
|
-
👉 [github.com/loopstack-ai/loopstack](https://github.com/loopstack-ai/loopstack)
|
package/eslint.config.mjs
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import js from '@eslint/js';
|
|
2
|
-
import prettier from 'eslint-plugin-prettier/recommended';
|
|
3
|
-
import { defineConfig, globalIgnores } from 'eslint/config';
|
|
4
|
-
import globals from 'globals';
|
|
5
|
-
import tseslint from 'typescript-eslint';
|
|
6
|
-
|
|
7
|
-
export default defineConfig([
|
|
8
|
-
globalIgnores(['dist', 'src/components/ai-elements']),
|
|
9
|
-
{
|
|
10
|
-
files: ['**/*.{ts,tsx}'],
|
|
11
|
-
extends: [js.configs.recommended, tseslint.configs.recommended, prettier],
|
|
12
|
-
languageOptions: {
|
|
13
|
-
ecmaVersion: 2020,
|
|
14
|
-
globals: globals.browser,
|
|
15
|
-
},
|
|
16
|
-
rules: {
|
|
17
|
-
//for now we ignore this, fix later
|
|
18
|
-
'@typescript-eslint/no-explicit-any': 'off',
|
|
19
|
-
},
|
|
20
|
-
},
|
|
21
|
-
]);
|
package/prettier.config.mjs
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
export default {
|
|
2
|
-
plugins: ['@trivago/prettier-plugin-sort-imports'],
|
|
3
|
-
importOrder: [
|
|
4
|
-
'<THIRD_PARTY_MODULES>', // Imports not matched by other special phrases
|
|
5
|
-
'^@loopstack/(.*)$', // Internal packages
|
|
6
|
-
'^@/(.*)$', // Path aliases
|
|
7
|
-
'^[./]', // Relative imports
|
|
8
|
-
],
|
|
9
|
-
importOrderSortSpecifiers: true,
|
|
10
|
-
importOrderParserPlugins: ['typescript', 'jsx', 'decorators-legacy'],
|
|
11
|
-
printWidth: 120,
|
|
12
|
-
singleQuote: true,
|
|
13
|
-
trailingComma: 'all',
|
|
14
|
-
semi: true,
|
|
15
|
-
tabWidth: 2,
|
|
16
|
-
bracketSpacing: true,
|
|
17
|
-
arrowParens: 'always',
|
|
18
|
-
endOfLine: 'lf',
|
|
19
|
-
};
|