{"_id":"@stll/conditions","_rev":"6-0b95e3094a3e8ac10db43873cb9987b9","name":"@stll/conditions","dist-tags":{"placeholder":"0.0.1-placeholder.0","latest":"0.4.0"},"versions":{"0.0.1-placeholder.0":{"name":"@stll/conditions","version":"0.0.1-placeholder.0","_id":"@stll/conditions@0.0.1-placeholder.0","maintainers":[{"name":"jan-kubica","email":"npm@stll.app"}],"dist":{"shasum":"ccf229179c1134b636ac7e014930166700156930","tarball":"https://registry.npmjs.org/@stll/conditions/-/conditions-0.0.1-placeholder.0.tgz","fileCount":1,"integrity":"sha512-EwB73j7d2MsFZV+jSjPLP2zwV45Y2Rf6Ef0tXgCfMp8cwlYHZS47sndFJj18AHLadF3DyH8xHI2M7h/CPXgiKA==","signatures":[{"sig":"MEUCIQCkfomKqtUEikFrtgYnBgbFv9a7xLuS57Su/INiPEeArgIgOoIIyuaXNk3ZzluiqCwWjKDnFwOfapWlddy0HDT1A98=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":188},"_npmUser":{"name":"jan-kubica","email":"npm@stll.app"},"_npmVersion":"11.11.0","description":"Placeholder to bootstrap npm trusted publishing. The real package ships via the next @stll release.","directories":{},"_nodeVersion":"24.14.1","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/conditions_0.0.1-placeholder.0_1782762259141_0.6136559401490098","host":"s3://npm-registry-packages-npm-production"}},"0.1.0":{"name":"@stll/conditions","version":"0.1.0","keywords":["ast","boolean","condition","evaluate","predicate","rules","schema"],"license":"Apache-2.0","_id":"@stll/conditions@0.1.0","maintainers":[{"name":"jan-kubica","email":"npm@stll.app"}],"homepage":"https://github.com/stella/stella/tree/main/packages/conditions","bugs":{"url":"https://github.com/stella/stella/issues"},"dist":{"shasum":"dfcf5f27b8550516e0b8849ae1d335cfc1498125","tarball":"https://registry.npmjs.org/@stll/conditions/-/conditions-0.1.0.tgz","fileCount":4,"integrity":"sha512-38y+hAAQsOfniDr9xt03mbW4ShYKL9dUE50p9eo8ExXlRen08VAaeVt8Z2tDl9qPM45052XHJT8VoABp//MJ0w==","signatures":[{"sig":"MEYCIQDJ+tmhOZ3tMzVIT1guUg+bBWHsTXZ/Xm8oKqjRvxfBvQIhAOIvNv9T8aofPY3AuMZCHUT782Ho6mOt4mAUNYgm6u3g","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@stll%2fconditions@0.1.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":17942},"main":"./dist/index.js","type":"module","_from":"file:/home/runner/work/stella/stella/release-artifacts/conditions/stll-conditions-0.1.0.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"lint":"cd ../.. && bun --bun oxlint -c oxlint.config.ts --report-unused-disable-directives-severity=error --deny-warnings --type-aware packages/conditions","test":"bun test src","build":"tsdown","clean":"git clean -xdf dist .cache .turbo node_modules","format":"oxfmt .","prepack":"bun run build","lint:fix":"cd ../.. && bun --bun oxlint -c oxlint.config.ts --type-aware --fix packages/conditions","typecheck":"tsgo --noEmit","pack:dry-run":"bun pm pack --dry-run","test:property":"bun test $(grep -rlF 'fc.assert' src --include='*.test.ts')"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:4b71a120-bfa3-4929-badf-52cf1e7244ec"}},"_resolved":"/home/runner/work/stella/stella/release-artifacts/conditions/stll-conditions-0.1.0.tgz","_integrity":"sha512-38y+hAAQsOfniDr9xt03mbW4ShYKL9dUE50p9eo8ExXlRen08VAaeVt8Z2tDl9qPM45052XHJT8VoABp//MJ0w==","repository":{"url":"git+https://github.com/stella/stella.git","type":"git","directory":"packages/conditions"},"_npmVersion":"11.11.1","description":"A generic boolean/predicate condition engine: schema, evaluate, walk.","directories":{},"sideEffects":false,"_nodeVersion":"22.23.0","dependencies":{"valibot":"1.4.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsdown":"0.22.3","@types/bun":"1.3.14","fast-check":"^4.8.0","@stll/property-testing":"0.0.0","@stll/typescript-config":"0.0.0"},"_npmOperationalInternal":{"tmp":"tmp/conditions_0.1.0_1782763958506_0.3294879836680986","host":"s3://npm-registry-packages-npm-production"}},"0.2.0":{"name":"@stll/conditions","version":"0.2.0","keywords":["ast","boolean","condition","evaluate","predicate","rules","schema"],"license":"Apache-2.0","_id":"@stll/conditions@0.2.0","maintainers":[{"name":"jan-kubica","email":"npm@stll.app"}],"homepage":"https://github.com/stella/stella/tree/main/packages/conditions","bugs":{"url":"https://github.com/stella/stella/issues"},"dist":{"shasum":"78abeafeae008cb0d49dffb14ea4069a5c95b4c8","tarball":"https://registry.npmjs.org/@stll/conditions/-/conditions-0.2.0.tgz","fileCount":4,"integrity":"sha512-Gvll876/MRhmpbgNZN2IQGxDwiVwk349yKElCPQrsjyHECrs+rKz5sxPl904q37g8JtBrmkDODJfGowP8MBGCA==","signatures":[{"sig":"MEYCIQCr7ulLmdgUrDKSE0WGh4mf8bfHvYFI/RO7fCCtii0XAgIhAMfgn0UCdSnJDN9PVlknk9VjwM+i+QNDZ01PgvXPh4b0","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@stll%2fconditions@0.2.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":19278},"main":"./dist/index.js","type":"module","_from":"file:/home/runner/work/stella/stella/release-artifacts/npm-tarball-conditions/stll-conditions-0.2.0.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"lint":"cd ../.. && bun --bun oxlint -c oxlint.config.ts --report-unused-disable-directives-severity=error --deny-warnings --type-aware packages/conditions","test":"bun test src","build":"tsdown","clean":"git clean -xdf dist .cache .turbo node_modules","format":"oxfmt .","prepack":"bun run build","lint:fix":"cd ../.. && bun --bun oxlint -c oxlint.config.ts --type-aware --fix packages/conditions","typecheck":"bun ../../packages/scripts/src/tsc-native.ts --noEmit","pack:dry-run":"bun pm pack --dry-run","test:property":"bun test $(grep -rlF 'fc.assert' src --include='*.test.ts')"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:4b71a120-bfa3-4929-badf-52cf1e7244ec"}},"_resolved":"/home/runner/work/stella/stella/release-artifacts/npm-tarball-conditions/stll-conditions-0.2.0.tgz","_integrity":"sha512-Gvll876/MRhmpbgNZN2IQGxDwiVwk349yKElCPQrsjyHECrs+rKz5sxPl904q37g8JtBrmkDODJfGowP8MBGCA==","repository":{"url":"git+https://github.com/stella/stella.git","type":"git","directory":"packages/conditions"},"_npmVersion":"11.11.1","description":"A generic boolean/predicate condition engine: schema, evaluate, walk.","directories":{},"sideEffects":false,"_nodeVersion":"22.23.1","dependencies":{"valibot":"1.4.2","better-result":"3.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsdown":"0.22.14","@types/bun":"1.3.14","fast-check":"^4.9.0","@stll/property-testing":"0.0.0","@stll/typescript-config":"0.0.0"},"_npmOperationalInternal":{"tmp":"tmp/conditions_0.2.0_1786399015032_0.22141181990803993","host":"s3://npm-registry-packages-npm-production"}},"0.3.0":{"name":"@stll/conditions","version":"0.3.0","keywords":["ast","boolean","condition","evaluate","predicate","rules","schema"],"license":"Apache-2.0","_id":"@stll/conditions@0.3.0","maintainers":[{"name":"jan-kubica","email":"npm@stll.app"}],"homepage":"https://github.com/stella/stella/tree/main/packages/conditions","bugs":{"url":"https://github.com/stella/stella/issues"},"dist":{"shasum":"919a57f55ea5dbc23200b945b051a25bd3715756","tarball":"https://registry.npmjs.org/@stll/conditions/-/conditions-0.3.0.tgz","fileCount":4,"integrity":"sha512-WZ8cPT2zpSxVVQa+piEeteECexAv9OI0+F2vM18MsFB5gyHJ954tSNw0OvCg9fbLUz8oqYdTqussXfLQeqQKbQ==","signatures":[{"sig":"MEUCIQClZZTbd5trtasi2IWuW/Ry/iHo82s05zlP8SIbTUCq9wIgAk5kkdirK5y5UYHhVQsDVZ/8RJRT1d/IjDKZga1Xlqs=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@stll%2fconditions@0.3.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":25112},"main":"./dist/index.js","type":"module","_from":"file:/home/runner/work/stella/stella/release-artifacts/npm-tarball-conditions/stll-conditions-0.3.0.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"lint":"cd ../.. && bun --bun oxlint -c oxlint.config.ts --report-unused-disable-directives-severity=error --deny-warnings --type-aware packages/conditions","test":"bun test src","build":"tsdown","clean":"git clean -xdf dist .cache .turbo node_modules","format":"oxfmt .","prepack":"bun run build","lint:fix":"cd ../.. && bun --bun oxlint -c oxlint.config.ts --type-aware --fix packages/conditions","typecheck":"bun ../../packages/scripts/src/tsc-native.ts --noEmit","pack:dry-run":"bun pm pack --dry-run","test:property":"bun test --preload @stll/property-testing/preload $(grep -rlF 'fc.assert' src --include='*.test.ts')"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:4b71a120-bfa3-4929-badf-52cf1e7244ec"}},"_resolved":"/home/runner/work/stella/stella/release-artifacts/npm-tarball-conditions/stll-conditions-0.3.0.tgz","_integrity":"sha512-WZ8cPT2zpSxVVQa+piEeteECexAv9OI0+F2vM18MsFB5gyHJ954tSNw0OvCg9fbLUz8oqYdTqussXfLQeqQKbQ==","repository":{"url":"git+https://github.com/stella/stella.git","type":"git","directory":"packages/conditions"},"_npmVersion":"11.11.1","description":"A generic boolean/predicate condition engine: schema, evaluate, walk.","directories":{},"sideEffects":false,"_nodeVersion":"22.21.1","dependencies":{"valibot":"1.4.2","better-result":"3.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsdown":"0.22.14","bun-types":"1.4.0","fast-check":"^4.9.0","@stll/property-testing":"0.0.0","@stll/typescript-config":"0.0.0"},"_npmOperationalInternal":{"tmp":"tmp/conditions_0.3.0_1788373194151_0.0992064711166798","host":"s3://npm-registry-packages-npm-production"}},"0.3.1":{"name":"@stll/conditions","version":"0.3.1","keywords":["ast","boolean","condition","evaluate","predicate","rules","schema"],"license":"Apache-2.0","_id":"@stll/conditions@0.3.1","maintainers":[{"name":"jan-kubica","email":"npm@stll.app"}],"homepage":"https://github.com/stella/stella/tree/main/packages/conditions","bugs":{"url":"https://github.com/stella/stella/issues"},"dist":{"shasum":"a47a31de29ff6e2f660fe829e21d64ba7a265bb3","tarball":"https://registry.npmjs.org/@stll/conditions/-/conditions-0.3.1.tgz","fileCount":4,"integrity":"sha512-zAAi0wo78t74HkrrGEUPUHGvB4Rp6PM0y4DB2De/UExdqLn4RIvT94fHvq6FnRZPhQBvcN1bjjQJEmTFp9y2jQ==","signatures":[{"sig":"MEQCIBNHaNUCT8cD+x/bvuvqe+/f0AX52zbeRmU5xUu9B1peAiAzdW7PZylXxyZiWVAJLoIkKoAkwLJk9NPsW5i3c5MPow==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEQCICsEspjW9/K0r2zcZ2P/09HKU4W3sf1A0/uPyTuhbMsXAiBBGR+4PeGfG+8eXzQVfu1hCZqHZZObknoBS2lE6NZtIg==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@stll%2fconditions@0.3.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":25300},"main":"./dist/index.js","type":"module","_from":"file:/home/runner/work/stella/stella/release-artifacts/npm-tarball-conditions/stll-conditions-0.3.1.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"lint":"cd ../.. && bun --bun oxlint -c oxlint.config.ts --report-unused-disable-directives-severity=error --deny-warnings --type-aware packages/conditions","test":"bun test src","build":"tsdown","clean":"git clean -xdf dist .cache .turbo node_modules","format":"bun ../../scripts/run-oxfmt.ts .","prepack":"bun run build","lint:fix":"cd ../.. && bun --bun oxlint -c oxlint.config.ts --type-aware --fix packages/conditions","typecheck":"bun ../../packages/scripts/src/tsc-native.ts --noEmit","pack:dry-run":"bun pm pack --dry-run","test:property":"bun test --preload @stll/property-testing/preload $(grep -rlF 'fc.assert' src --include='*.test.ts')"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:4b71a120-bfa3-4929-badf-52cf1e7244ec"}},"_resolved":"/home/runner/work/stella/stella/release-artifacts/npm-tarball-conditions/stll-conditions-0.3.1.tgz","_integrity":"sha512-zAAi0wo78t74HkrrGEUPUHGvB4Rp6PM0y4DB2De/UExdqLn4RIvT94fHvq6FnRZPhQBvcN1bjjQJEmTFp9y2jQ==","repository":{"url":"git+https://github.com/stella/stella.git","type":"git","directory":"packages/conditions"},"_npmVersion":"11.11.1","description":"A generic boolean/predicate condition engine: schema, evaluate, walk.","directories":{},"sideEffects":false,"_nodeVersion":"22.21.1","dependencies":{"valibot":"1.4.2","better-result":"3.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsdown":"0.22.14","bun-types":"1.4.2","fast-check":"^4.9.0","@stll/property-testing":"0.0.0","@stll/typescript-config":"0.0.0"},"_npmOperationalInternal":{"tmp":"tmp/conditions_0.3.1_1788620326138_0.6607289831025172","host":"s3://npm-registry-packages-npm-production"}},"0.4.0":{"_id":"@stll/conditions@0.4.0","bugs":{"url":"https://github.com/stella/stella/issues"},"dist":{"shasum":"e02d2b04aeda40138ccd64be9cc29a570cfbf144","tarball":"https://registry.npmjs.org/@stll/conditions/-/conditions-0.4.0.tgz","fileCount":4,"integrity":"sha512-p6mqIAdr//HyDQBOB8Z0eAcCfkSqqU4xTMRoE8st0x4I9V8vgkt0XvB34Iclqf3stsMjy7t9D3CoGUwhhXX9zw==","signatures":[{"sig":"MEUCIQCdCJ5GqiKbLuBIUEnCnMMJA3LBzId4Tg/ppQwYblqJ9QIgfse6hCBCKa68pLM1fpExJbJLmkHygjR1O6jB03B6usY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCjLQXVidNplE7hdMAJOYtf54T1tQ4nfDaQayS9Ioln5QIgYuosAtCsmcHVexJqYJOUpfWpfsfCfXUeSx8m61YyfYc="}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@stll%2fconditions@0.4.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":25081},"main":"./dist/index.js","name":"@stll/conditions","type":"module","_from":"file:/home/runner/work/stella/stella/release-artifacts/npm-tarball-conditions/stll-conditions-0.4.0.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"license":"Apache-2.0","scripts":{"lint":"cd ../.. && bun --bun oxlint -c oxlint.config.ts --report-unused-disable-directives-severity=error --deny-warnings --type-aware packages/conditions","test":"bun test src","build":"tsdown","clean":"git clean -xdf dist .cache .turbo node_modules","format":"bun ../../scripts/run-oxfmt.ts .","prepack":"bun run build","lint:fix":"cd ../.. && bun --bun oxlint -c oxlint.config.ts --type-aware --fix packages/conditions","typecheck":"bun ../../packages/scripts/src/tsc-native.ts --noEmit","pack:dry-run":"bun pm pack --dry-run","test:property":"bun test --preload @stll/property-testing/preload $(grep -rlF 'fc.assert' src --include='*.test.ts')"},"version":"0.4.0","_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:4b71a120-bfa3-4929-badf-52cf1e7244ec"}},"homepage":"https://github.com/stella/stella/tree/main/packages/conditions","keywords":["ast","boolean","condition","evaluate","predicate","rules","schema"],"_resolved":"/home/runner/work/stella/stella/release-artifacts/npm-tarball-conditions/stll-conditions-0.4.0.tgz","_integrity":"sha512-p6mqIAdr//HyDQBOB8Z0eAcCfkSqqU4xTMRoE8st0x4I9V8vgkt0XvB34Iclqf3stsMjy7t9D3CoGUwhhXX9zw==","repository":{"url":"git+https://github.com/stella/stella.git","type":"git","directory":"packages/conditions"},"_npmVersion":"11.11.1","description":"A generic boolean/predicate condition engine: schema, evaluate, walk.","directories":{},"maintainers":[{"name":"jan-kubica","email":"npm@stll.app"}],"sideEffects":false,"_nodeVersion":"22.21.1","dependencies":{"valibot":"1.4.2","better-result":"3.0.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsdown":"0.23.0","bun-types":"1.4.2","fast-check":"^4.9.0","@stll/property-testing":"0.0.0","@stll/typescript-config":"0.0.0"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/conditions_0.4.0_1789555263412_0.9145102679602357"}}},"time":{"created":"2026-06-29T19:44:18.974Z","modified":"2026-09-16T10:41:03.871Z","0.0.1-placeholder.0":"2026-06-29T19:44:19.273Z","0.1.0":"2026-06-29T20:12:38.637Z","0.2.0":"2026-08-10T21:56:55.193Z","0.3.0":"2026-09-02T18:19:54.316Z","0.3.1":"2026-09-05T14:58:46.236Z","0.4.0":"2026-09-16T10:41:03.484Z"},"bugs":{"url":"https://github.com/stella/stella/issues"},"license":"Apache-2.0","homepage":"https://github.com/stella/stella/tree/main/packages/conditions","keywords":["ast","boolean","condition","evaluate","predicate","rules","schema"],"repository":{"url":"git+https://github.com/stella/stella.git","type":"git","directory":"packages/conditions"},"description":"A generic boolean/predicate condition engine: schema, evaluate, walk.","maintainers":[{"name":"jan-kubica","email":"npm@stll.app"}],"readme":"# @stll/conditions\n\nA generic, side-effect-free boolean/predicate condition engine: a typed\ncondition AST, its single evaluator, and a walker.\n\nThe package owns one canonical structured-condition shape (compare, predicate,\nand group nodes combined with `and`/`or` and negation) so that different\nconsumers — filters, gating, templates — share one set of operators and\nsemantics and never drift apart. Domain code supplies a small `resolve`\nadapter that turns a non-literal operand into a concrete value; the evaluator\nhandles operators, boolean combination, and negation.\n\n```ts\nimport { evaluateCondition, type Condition } from \"@stll/conditions\";\n\nconst condition: Condition = {\n  type: \"group\",\n  combinator: \"and\",\n  negated: false,\n  children: [\n    {\n      type: \"compare\",\n      op: \"eq\",\n      left: { type: \"path\", path: \"status\" },\n      right: { type: \"literal\", value: \"open\" },\n    },\n  ],\n};\n\nconst result = evaluateCondition(condition, (operand) =>\n  operand.type === \"path\" ? data[operand.path] : undefined,\n);\n```\n\n## Install\n\n```sh\nbun add @stll/conditions\n```\n\n## API\n\nEverything is exported from the package root (`@stll/conditions`). The surface\nis organised into three areas:\n\n- **schema** — the condition AST types and Valibot schemas\n  (`conditionSchema`, `conditionNodeSchema`, `emptyCondition`).\n- **evaluate** — the single evaluator (`evaluateCondition`, `OperandResolver`,\n  `pruneIncomplete`).\n- **walk** — AST traversal helpers (`conditionHasFormula`).\n\n## License\n\nApache-2.0\n","readmeFilename":"README.md"}