@vibesdotdev/hq 0.0.0-stage → 1.0.0-rc.2
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/LICENSE +18 -0
- package/README.md +49 -2
- package/dist/agent-events/descriptors.d.ts +33 -0
- package/dist/agent-events/descriptors.d.ts.map +1 -0
- package/dist/agent-events/descriptors.js +34 -0
- package/dist/agent-events/descriptors.js.map +1 -0
- package/dist/app/auth/cloud-sync.consumer.d.ts +12 -0
- package/dist/app/auth/cloud-sync.consumer.d.ts.map +1 -0
- package/dist/app/auth/cloud-sync.consumer.js +31 -0
- package/dist/app/auth/cloud-sync.consumer.js.map +1 -0
- package/dist/app/auth/hq.app-auth-machine.record.descriptor.d.ts +5 -0
- package/dist/app/auth/hq.app-auth-machine.record.descriptor.d.ts.map +1 -0
- package/dist/app/auth/hq.app-auth-machine.record.descriptor.js +39 -0
- package/dist/app/auth/hq.app-auth-machine.record.descriptor.js.map +1 -0
- package/dist/app/auth/hq.app-auth-pairings.record.descriptor.d.ts +5 -0
- package/dist/app/auth/hq.app-auth-pairings.record.descriptor.d.ts.map +1 -0
- package/dist/app/auth/hq.app-auth-pairings.record.descriptor.js +43 -0
- package/dist/app/auth/hq.app-auth-pairings.record.descriptor.js.map +1 -0
- package/dist/app/auth/hq.app-auth-tokens.record.descriptor.d.ts +5 -0
- package/dist/app/auth/hq.app-auth-tokens.record.descriptor.d.ts.map +1 -0
- package/dist/app/auth/hq.app-auth-tokens.record.descriptor.js +42 -0
- package/dist/app/auth/hq.app-auth-tokens.record.descriptor.js.map +1 -0
- package/dist/app/auth/schemas/auth.d.ts +146 -0
- package/dist/app/auth/schemas/auth.d.ts.map +1 -0
- package/dist/app/auth/schemas/auth.js +53 -0
- package/dist/app/auth/schemas/auth.js.map +1 -0
- package/dist/app/auth/service.consumer.d.ts +17 -0
- package/dist/app/auth/service.consumer.d.ts.map +1 -0
- package/dist/app/auth/service.consumer.js +79 -0
- package/dist/app/auth/service.consumer.js.map +1 -0
- package/dist/app/auth/sync.consumer.d.ts +2 -0
- package/dist/app/auth/sync.consumer.d.ts.map +1 -0
- package/dist/app/auth/sync.consumer.js +2 -0
- package/dist/app/auth/sync.consumer.js.map +1 -0
- package/dist/app/auth/sync.d.ts +23 -0
- package/dist/app/auth/sync.d.ts.map +1 -0
- package/dist/app/auth/sync.js +290 -0
- package/dist/app/auth/sync.js.map +1 -0
- package/dist/app/auth/types.d.ts +20 -0
- package/dist/app/auth/types.d.ts.map +1 -0
- package/dist/app/auth/types.js +7 -0
- package/dist/app/auth/types.js.map +1 -0
- package/dist/app/sync/hq.app-auth.sync-bridge.descriptor.d.ts +9 -0
- package/dist/app/sync/hq.app-auth.sync-bridge.descriptor.d.ts.map +1 -0
- package/dist/app/sync/hq.app-auth.sync-bridge.descriptor.js +45 -0
- package/dist/app/sync/hq.app-auth.sync-bridge.descriptor.js.map +1 -0
- package/dist/applets/component-ref.d.ts +6 -0
- package/dist/applets/component-ref.d.ts.map +1 -0
- package/dist/applets/component-ref.js +6 -0
- package/dist/applets/component-ref.js.map +1 -0
- package/dist/applets/index.d.ts +3 -0
- package/dist/applets/index.d.ts.map +1 -0
- package/dist/applets/index.js +3 -0
- package/dist/applets/index.js.map +1 -0
- package/dist/approval/approval-resolved.event.descriptor.d.ts +11 -0
- package/dist/approval/approval-resolved.event.descriptor.d.ts.map +1 -0
- package/dist/approval/approval-resolved.event.descriptor.js +11 -0
- package/dist/approval/approval-resolved.event.descriptor.js.map +1 -0
- package/dist/approval/approval-resolved.job.descriptor.d.ts +36 -0
- package/dist/approval/approval-resolved.job.descriptor.d.ts.map +1 -0
- package/dist/approval/approval-resolved.job.descriptor.js +24 -0
- package/dist/approval/approval-resolved.job.descriptor.js.map +1 -0
- package/dist/approval/approval-resolved.job.impl.d.ts +19 -0
- package/dist/approval/approval-resolved.job.impl.d.ts.map +1 -0
- package/dist/approval/approval-resolved.job.impl.js +26 -0
- package/dist/approval/approval-resolved.job.impl.js.map +1 -0
- package/dist/approval/approval-resolved.subscription.descriptor.d.ts +21 -0
- package/dist/approval/approval-resolved.subscription.descriptor.d.ts.map +1 -0
- package/dist/approval/approval-resolved.subscription.descriptor.js +20 -0
- package/dist/approval/approval-resolved.subscription.descriptor.js.map +1 -0
- package/dist/approval/schemas.d.ts +45 -0
- package/dist/approval/schemas.d.ts.map +1 -0
- package/dist/approval/schemas.js +27 -0
- package/dist/approval/schemas.js.map +1 -0
- package/dist/approval/surface-approval-channel.descriptor.d.ts +14 -0
- package/dist/approval/surface-approval-channel.descriptor.d.ts.map +1 -0
- package/dist/approval/surface-approval-channel.descriptor.js +16 -0
- package/dist/approval/surface-approval-channel.descriptor.js.map +1 -0
- package/dist/approval/surface-approval-channel.impl.d.ts +19 -0
- package/dist/approval/surface-approval-channel.impl.d.ts.map +1 -0
- package/dist/approval/surface-approval-channel.impl.js +101 -0
- package/dist/approval/surface-approval-channel.impl.js.map +1 -0
- package/dist/cli/app/handoff/hq.app.handoff.descriptor.d.ts +40 -0
- package/dist/cli/app/handoff/hq.app.handoff.descriptor.d.ts.map +1 -0
- package/dist/cli/app/handoff/hq.app.handoff.descriptor.js +23 -0
- package/dist/cli/app/handoff/hq.app.handoff.descriptor.js.map +1 -0
- package/dist/cli/app/handoff/hq.app.handoff.impl.consumer.d.ts +7 -0
- package/dist/cli/app/handoff/hq.app.handoff.impl.consumer.d.ts.map +1 -0
- package/dist/cli/app/handoff/hq.app.handoff.impl.consumer.js +107 -0
- package/dist/cli/app/handoff/hq.app.handoff.impl.consumer.js.map +1 -0
- package/dist/cli/app/hq.app.cli-group.descriptor.d.ts +12 -0
- package/dist/cli/app/hq.app.cli-group.descriptor.d.ts.map +1 -0
- package/dist/cli/app/hq.app.cli-group.descriptor.js +12 -0
- package/dist/cli/app/hq.app.cli-group.descriptor.js.map +1 -0
- package/dist/cli/app/pair/hq.app.pair.descriptor.d.ts +43 -0
- package/dist/cli/app/pair/hq.app.pair.descriptor.d.ts.map +1 -0
- package/dist/cli/app/pair/hq.app.pair.descriptor.js +27 -0
- package/dist/cli/app/pair/hq.app.pair.descriptor.js.map +1 -0
- package/dist/cli/app/pair/hq.app.pair.impl.consumer.d.ts +7 -0
- package/dist/cli/app/pair/hq.app.pair.impl.consumer.d.ts.map +1 -0
- package/dist/cli/app/pair/hq.app.pair.impl.consumer.js +89 -0
- package/dist/cli/app/pair/hq.app.pair.impl.consumer.js.map +1 -0
- package/dist/cli/app/shared/options.d.ts +70 -0
- package/dist/cli/app/shared/options.d.ts.map +1 -0
- package/dist/cli/app/shared/options.js +7 -0
- package/dist/cli/app/shared/options.js.map +1 -0
- package/dist/cli/app/token/hq.app.token.descriptor.d.ts +40 -0
- package/dist/cli/app/token/hq.app.token.descriptor.d.ts.map +1 -0
- package/dist/cli/app/token/hq.app.token.descriptor.js +23 -0
- package/dist/cli/app/token/hq.app.token.descriptor.js.map +1 -0
- package/dist/cli/app/token/hq.app.token.impl.consumer.d.ts +7 -0
- package/dist/cli/app/token/hq.app.token.impl.consumer.d.ts.map +1 -0
- package/dist/cli/app/token/hq.app.token.impl.consumer.js +89 -0
- package/dist/cli/app/token/hq.app.token.impl.consumer.js.map +1 -0
- package/dist/cli/channel/hq.channel.cli-group.descriptor.d.ts +12 -0
- package/dist/cli/channel/hq.channel.cli-group.descriptor.d.ts.map +1 -0
- package/dist/cli/channel/hq.channel.cli-group.descriptor.js +12 -0
- package/dist/cli/channel/hq.channel.cli-group.descriptor.js.map +1 -0
- package/dist/cli/channel/hq.channel.enable.descriptor.d.ts +21 -0
- package/dist/cli/channel/hq.channel.enable.descriptor.d.ts.map +1 -0
- package/dist/cli/channel/hq.channel.enable.descriptor.js +16 -0
- package/dist/cli/channel/hq.channel.enable.descriptor.js.map +1 -0
- package/dist/cli/channel/hq.channel.enable.impl.d.ts +7 -0
- package/dist/cli/channel/hq.channel.enable.impl.d.ts.map +1 -0
- package/dist/cli/channel/hq.channel.enable.impl.js +23 -0
- package/dist/cli/channel/hq.channel.enable.impl.js.map +1 -0
- package/dist/cli/channel/hq.channel.fire.descriptor.d.ts +17 -0
- package/dist/cli/channel/hq.channel.fire.descriptor.d.ts.map +1 -0
- package/dist/cli/channel/hq.channel.fire.descriptor.js +13 -0
- package/dist/cli/channel/hq.channel.fire.descriptor.js.map +1 -0
- package/dist/cli/channel/hq.channel.fire.impl.d.ts +7 -0
- package/dist/cli/channel/hq.channel.fire.impl.d.ts.map +1 -0
- package/dist/cli/channel/hq.channel.fire.impl.js +26 -0
- package/dist/cli/channel/hq.channel.fire.impl.js.map +1 -0
- package/dist/cli/channel/hq.channel.list.descriptor.d.ts +16 -0
- package/dist/cli/channel/hq.channel.list.descriptor.d.ts.map +1 -0
- package/dist/cli/channel/hq.channel.list.descriptor.js +13 -0
- package/dist/cli/channel/hq.channel.list.descriptor.js.map +1 -0
- package/dist/cli/channel/hq.channel.list.impl.d.ts +7 -0
- package/dist/cli/channel/hq.channel.list.impl.d.ts.map +1 -0
- package/dist/cli/channel/hq.channel.list.impl.js +30 -0
- package/dist/cli/channel/hq.channel.list.impl.js.map +1 -0
- package/dist/cli/channel/hq.channel.logs.descriptor.d.ts +24 -0
- package/dist/cli/channel/hq.channel.logs.descriptor.d.ts.map +1 -0
- package/dist/cli/channel/hq.channel.logs.descriptor.js +17 -0
- package/dist/cli/channel/hq.channel.logs.descriptor.js.map +1 -0
- package/dist/cli/channel/hq.channel.logs.impl.d.ts +9 -0
- package/dist/cli/channel/hq.channel.logs.impl.d.ts.map +1 -0
- package/dist/cli/channel/hq.channel.logs.impl.js +74 -0
- package/dist/cli/channel/hq.channel.logs.impl.js.map +1 -0
- package/dist/cli/friction/_store-hint.d.ts +7 -0
- package/dist/cli/friction/_store-hint.d.ts.map +1 -0
- package/dist/cli/friction/_store-hint.js +13 -0
- package/dist/cli/friction/_store-hint.js.map +1 -0
- package/dist/cli/friction/hq.friction.cli-group.descriptor.d.ts +11 -0
- package/dist/cli/friction/hq.friction.cli-group.descriptor.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.cli-group.descriptor.js +15 -0
- package/dist/cli/friction/hq.friction.cli-group.descriptor.js.map +1 -0
- package/dist/cli/friction/hq.friction.disposition.d.ts +5 -0
- package/dist/cli/friction/hq.friction.disposition.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.disposition.js +64 -0
- package/dist/cli/friction/hq.friction.disposition.js.map +1 -0
- package/dist/cli/friction/hq.friction.emit.descriptor.d.ts +65 -0
- package/dist/cli/friction/hq.friction.emit.descriptor.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.emit.descriptor.js +70 -0
- package/dist/cli/friction/hq.friction.emit.descriptor.js.map +1 -0
- package/dist/cli/friction/hq.friction.emit.impl.d.ts +7 -0
- package/dist/cli/friction/hq.friction.emit.impl.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.emit.impl.js +85 -0
- package/dist/cli/friction/hq.friction.emit.impl.js.map +1 -0
- package/dist/cli/friction/hq.friction.list.descriptor.d.ts +37 -0
- package/dist/cli/friction/hq.friction.list.descriptor.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.list.descriptor.js +22 -0
- package/dist/cli/friction/hq.friction.list.descriptor.js.map +1 -0
- package/dist/cli/friction/hq.friction.list.impl.d.ts +7 -0
- package/dist/cli/friction/hq.friction.list.impl.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.list.impl.js +73 -0
- package/dist/cli/friction/hq.friction.list.impl.js.map +1 -0
- package/dist/cli/friction/hq.friction.promote.descriptor.d.ts +21 -0
- package/dist/cli/friction/hq.friction.promote.descriptor.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.promote.descriptor.js +14 -0
- package/dist/cli/friction/hq.friction.promote.descriptor.js.map +1 -0
- package/dist/cli/friction/hq.friction.promote.impl.d.ts +7 -0
- package/dist/cli/friction/hq.friction.promote.impl.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.promote.impl.js +47 -0
- package/dist/cli/friction/hq.friction.promote.impl.js.map +1 -0
- package/dist/cli/friction/hq.friction.reassign-org.descriptor.d.ts +25 -0
- package/dist/cli/friction/hq.friction.reassign-org.descriptor.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.reassign-org.descriptor.js +18 -0
- package/dist/cli/friction/hq.friction.reassign-org.descriptor.js.map +1 -0
- package/dist/cli/friction/hq.friction.reassign-org.impl.d.ts +6 -0
- package/dist/cli/friction/hq.friction.reassign-org.impl.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.reassign-org.impl.js +27 -0
- package/dist/cli/friction/hq.friction.reassign-org.impl.js.map +1 -0
- package/dist/cli/friction/hq.friction.reject.descriptor.d.ts +24 -0
- package/dist/cli/friction/hq.friction.reject.descriptor.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.reject.descriptor.js +17 -0
- package/dist/cli/friction/hq.friction.reject.descriptor.js.map +1 -0
- package/dist/cli/friction/hq.friction.reject.impl.d.ts +6 -0
- package/dist/cli/friction/hq.friction.reject.impl.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.reject.impl.js +7 -0
- package/dist/cli/friction/hq.friction.reject.impl.js.map +1 -0
- package/dist/cli/friction/hq.friction.resolve.descriptor.d.ts +27 -0
- package/dist/cli/friction/hq.friction.resolve.descriptor.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.resolve.descriptor.js +18 -0
- package/dist/cli/friction/hq.friction.resolve.descriptor.js.map +1 -0
- package/dist/cli/friction/hq.friction.resolve.impl.d.ts +6 -0
- package/dist/cli/friction/hq.friction.resolve.impl.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.resolve.impl.js +7 -0
- package/dist/cli/friction/hq.friction.resolve.impl.js.map +1 -0
- package/dist/cli/friction/hq.friction.show.descriptor.d.ts +24 -0
- package/dist/cli/friction/hq.friction.show.descriptor.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.show.descriptor.js +17 -0
- package/dist/cli/friction/hq.friction.show.descriptor.js.map +1 -0
- package/dist/cli/friction/hq.friction.show.impl.d.ts +7 -0
- package/dist/cli/friction/hq.friction.show.impl.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.show.impl.js +64 -0
- package/dist/cli/friction/hq.friction.show.impl.js.map +1 -0
- package/dist/cli/friction/hq.friction.sync.descriptor.d.ts +16 -0
- package/dist/cli/friction/hq.friction.sync.descriptor.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.sync.descriptor.js +13 -0
- package/dist/cli/friction/hq.friction.sync.descriptor.js.map +1 -0
- package/dist/cli/friction/hq.friction.sync.impl.d.ts +7 -0
- package/dist/cli/friction/hq.friction.sync.impl.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.sync.impl.js +29 -0
- package/dist/cli/friction/hq.friction.sync.impl.js.map +1 -0
- package/dist/cli/friction/hq.friction.triage.descriptor.d.ts +27 -0
- package/dist/cli/friction/hq.friction.triage.descriptor.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.triage.descriptor.js +18 -0
- package/dist/cli/friction/hq.friction.triage.descriptor.js.map +1 -0
- package/dist/cli/friction/hq.friction.triage.impl.d.ts +6 -0
- package/dist/cli/friction/hq.friction.triage.impl.d.ts.map +1 -0
- package/dist/cli/friction/hq.friction.triage.impl.js +7 -0
- package/dist/cli/friction/hq.friction.triage.impl.js.map +1 -0
- package/dist/cli/friction/invocation.d.ts +17 -0
- package/dist/cli/friction/invocation.d.ts.map +1 -0
- package/dist/cli/friction/invocation.js +76 -0
- package/dist/cli/friction/invocation.js.map +1 -0
- package/dist/cli/health/hq.health.descriptor.d.ts +19 -0
- package/dist/cli/health/hq.health.descriptor.d.ts.map +1 -0
- package/dist/cli/health/hq.health.descriptor.js +16 -0
- package/dist/cli/health/hq.health.descriptor.js.map +1 -0
- package/dist/cli/health/hq.health.impl.d.ts +3 -0
- package/dist/cli/health/hq.health.impl.d.ts.map +1 -0
- package/dist/cli/health/hq.health.impl.js +151 -0
- package/dist/cli/health/hq.health.impl.js.map +1 -0
- package/dist/cli/host-platform.d.ts +14 -0
- package/dist/cli/host-platform.d.ts.map +1 -0
- package/dist/cli/host-platform.js +30 -0
- package/dist/cli/host-platform.js.map +1 -0
- package/dist/cli/hq.cli-group.descriptor.d.ts +11 -0
- package/dist/cli/hq.cli-group.descriptor.d.ts.map +1 -0
- package/dist/cli/hq.cli-group.descriptor.js +11 -0
- package/dist/cli/hq.cli-group.descriptor.js.map +1 -0
- package/dist/cli/init/hq.init.descriptor.d.ts +7 -0
- package/dist/cli/init/hq.init.descriptor.d.ts.map +1 -0
- package/dist/cli/init/hq.init.descriptor.js +36 -0
- package/dist/cli/init/hq.init.descriptor.js.map +1 -0
- package/dist/cli/init/hq.init.impl.d.ts +7 -0
- package/dist/cli/init/hq.init.impl.d.ts.map +1 -0
- package/dist/cli/init/hq.init.impl.js +163 -0
- package/dist/cli/init/hq.init.impl.js.map +1 -0
- package/dist/cli/install/hq.install.descriptor.d.ts +9 -0
- package/dist/cli/install/hq.install.descriptor.d.ts.map +1 -0
- package/dist/cli/install/hq.install.descriptor.js +34 -0
- package/dist/cli/install/hq.install.descriptor.js.map +1 -0
- package/dist/cli/install/hq.install.impl.d.ts +6 -0
- package/dist/cli/install/hq.install.impl.d.ts.map +1 -0
- package/dist/cli/install/hq.install.impl.js +110 -0
- package/dist/cli/install/hq.install.impl.js.map +1 -0
- package/dist/cli/permissions/hq.permissions.descriptor.d.ts +9 -0
- package/dist/cli/permissions/hq.permissions.descriptor.d.ts.map +1 -0
- package/dist/cli/permissions/hq.permissions.descriptor.js +25 -0
- package/dist/cli/permissions/hq.permissions.descriptor.js.map +1 -0
- package/dist/cli/permissions/hq.permissions.impl.d.ts +3 -0
- package/dist/cli/permissions/hq.permissions.impl.d.ts.map +1 -0
- package/dist/cli/permissions/hq.permissions.impl.js +113 -0
- package/dist/cli/permissions/hq.permissions.impl.js.map +1 -0
- package/dist/cli/plugin.d.ts +3 -0
- package/dist/cli/plugin.d.ts.map +1 -0
- package/dist/cli/plugin.js +79 -0
- package/dist/cli/plugin.js.map +1 -0
- package/dist/cli/schemas/input.d.ts +119 -0
- package/dist/cli/schemas/input.d.ts.map +1 -0
- package/dist/cli/schemas/input.js +67 -0
- package/dist/cli/schemas/input.js.map +1 -0
- package/dist/cli/service/hq.service.cli-group.descriptor.d.ts +12 -0
- package/dist/cli/service/hq.service.cli-group.descriptor.d.ts.map +1 -0
- package/dist/cli/service/hq.service.cli-group.descriptor.js +12 -0
- package/dist/cli/service/hq.service.cli-group.descriptor.js.map +1 -0
- package/dist/cli/service/hq.service.list.descriptor.d.ts +16 -0
- package/dist/cli/service/hq.service.list.descriptor.d.ts.map +1 -0
- package/dist/cli/service/hq.service.list.descriptor.js +13 -0
- package/dist/cli/service/hq.service.list.descriptor.js.map +1 -0
- package/dist/cli/service/hq.service.list.impl.d.ts +7 -0
- package/dist/cli/service/hq.service.list.impl.d.ts.map +1 -0
- package/dist/cli/service/hq.service.list.impl.js +31 -0
- package/dist/cli/service/hq.service.list.impl.js.map +1 -0
- package/dist/cli/service/hq.service.manage.descriptor.d.ts +25 -0
- package/dist/cli/service/hq.service.manage.descriptor.d.ts.map +1 -0
- package/dist/cli/service/hq.service.manage.descriptor.js +23 -0
- package/dist/cli/service/hq.service.manage.descriptor.js.map +1 -0
- package/dist/cli/service/hq.service.manage.impl.d.ts +7 -0
- package/dist/cli/service/hq.service.manage.impl.d.ts.map +1 -0
- package/dist/cli/service/hq.service.manage.impl.js +64 -0
- package/dist/cli/service/hq.service.manage.impl.js.map +1 -0
- package/dist/cli/service/hq.service.register.descriptor.d.ts +21 -0
- package/dist/cli/service/hq.service.register.descriptor.d.ts.map +1 -0
- package/dist/cli/service/hq.service.register.descriptor.js +20 -0
- package/dist/cli/service/hq.service.register.descriptor.js.map +1 -0
- package/dist/cli/service/hq.service.register.impl.d.ts +7 -0
- package/dist/cli/service/hq.service.register.impl.d.ts.map +1 -0
- package/dist/cli/service/hq.service.register.impl.js +35 -0
- package/dist/cli/service/hq.service.register.impl.js.map +1 -0
- package/dist/cli/setup/hq.setup.descriptor.d.ts +9 -0
- package/dist/cli/setup/hq.setup.descriptor.d.ts.map +1 -0
- package/dist/cli/setup/hq.setup.descriptor.js +22 -0
- package/dist/cli/setup/hq.setup.descriptor.js.map +1 -0
- package/dist/cli/setup/hq.setup.impl.d.ts +7 -0
- package/dist/cli/setup/hq.setup.impl.d.ts.map +1 -0
- package/dist/cli/setup/hq.setup.impl.js +57 -0
- package/dist/cli/setup/hq.setup.impl.js.map +1 -0
- package/dist/cli/setup/index.d.ts +2 -0
- package/dist/cli/setup/index.d.ts.map +1 -0
- package/dist/cli/setup/index.js +2 -0
- package/dist/cli/setup/index.js.map +1 -0
- package/dist/cli/surface/hq.surface.cli-group.descriptor.d.ts +12 -0
- package/dist/cli/surface/hq.surface.cli-group.descriptor.d.ts.map +1 -0
- package/dist/cli/surface/hq.surface.cli-group.descriptor.js +12 -0
- package/dist/cli/surface/hq.surface.cli-group.descriptor.js.map +1 -0
- package/dist/cli/surface/hq.surface.list.descriptor.d.ts +20 -0
- package/dist/cli/surface/hq.surface.list.descriptor.d.ts.map +1 -0
- package/dist/cli/surface/hq.surface.list.descriptor.js +20 -0
- package/dist/cli/surface/hq.surface.list.descriptor.js.map +1 -0
- package/dist/cli/surface/hq.surface.list.impl.d.ts +7 -0
- package/dist/cli/surface/hq.surface.list.impl.d.ts.map +1 -0
- package/dist/cli/surface/hq.surface.list.impl.js +35 -0
- package/dist/cli/surface/hq.surface.list.impl.js.map +1 -0
- package/dist/cli/surface/hq.surface.resolve.descriptor.d.ts +22 -0
- package/dist/cli/surface/hq.surface.resolve.descriptor.d.ts.map +1 -0
- package/dist/cli/surface/hq.surface.resolve.descriptor.js +20 -0
- package/dist/cli/surface/hq.surface.resolve.descriptor.js.map +1 -0
- package/dist/cli/surface/hq.surface.resolve.impl.d.ts +7 -0
- package/dist/cli/surface/hq.surface.resolve.impl.d.ts.map +1 -0
- package/dist/cli/surface/hq.surface.resolve.impl.js +29 -0
- package/dist/cli/surface/hq.surface.resolve.impl.js.map +1 -0
- package/dist/client/friction/index.d.ts +58 -0
- package/dist/client/friction/index.d.ts.map +1 -0
- package/dist/client/friction/index.js +146 -0
- package/dist/client/friction/index.js.map +1 -0
- package/dist/client/friction.client.descriptor.d.ts +14 -0
- package/dist/client/friction.client.descriptor.d.ts.map +1 -0
- package/dist/client/friction.client.descriptor.js +14 -0
- package/dist/client/friction.client.descriptor.js.map +1 -0
- package/dist/client/hq.client.descriptor.d.ts +14 -0
- package/dist/client/hq.client.descriptor.d.ts.map +1 -0
- package/dist/client/hq.client.descriptor.js +14 -0
- package/dist/client/hq.client.descriptor.js.map +1 -0
- package/dist/client/index.d.ts +95 -0
- package/dist/client/index.d.ts.map +1 -0
- package/dist/client/index.js +144 -0
- package/dist/client/index.js.map +1 -0
- package/dist/config/hq-friction.config.descriptor.d.ts +227 -0
- package/dist/config/hq-friction.config.descriptor.d.ts.map +1 -0
- package/dist/config/hq-friction.config.descriptor.js +116 -0
- package/dist/config/hq-friction.config.descriptor.js.map +1 -0
- package/dist/dashboard.d.ts +133 -0
- package/dist/dashboard.d.ts.map +1 -0
- package/dist/dashboard.js +371 -0
- package/dist/dashboard.js.map +1 -0
- package/dist/docs/hq.machines.docs.descriptor.d.ts +22 -0
- package/dist/docs/hq.machines.docs.descriptor.d.ts.map +1 -0
- package/dist/docs/hq.machines.docs.descriptor.js +65 -0
- package/dist/docs/hq.machines.docs.descriptor.js.map +1 -0
- package/dist/docs/hq.sessions.docs.descriptor.d.ts +22 -0
- package/dist/docs/hq.sessions.docs.descriptor.d.ts.map +1 -0
- package/dist/docs/hq.sessions.docs.descriptor.js +74 -0
- package/dist/docs/hq.sessions.docs.descriptor.js.map +1 -0
- package/dist/docs/hq.surfaces.docs.descriptor.d.ts +38 -0
- package/dist/docs/hq.surfaces.docs.descriptor.d.ts.map +1 -0
- package/dist/docs/hq.surfaces.docs.descriptor.js +161 -0
- package/dist/docs/hq.surfaces.docs.descriptor.js.map +1 -0
- package/dist/docs/hq.terminal.docs.descriptor.d.ts +22 -0
- package/dist/docs/hq.terminal.docs.descriptor.d.ts.map +1 -0
- package/dist/docs/hq.terminal.docs.descriptor.js +86 -0
- package/dist/docs/hq.terminal.docs.descriptor.js.map +1 -0
- package/dist/friction/clusters.d.ts +23 -0
- package/dist/friction/clusters.d.ts.map +1 -0
- package/dist/friction/clusters.js +56 -0
- package/dist/friction/clusters.js.map +1 -0
- package/dist/friction/fingerprint.d.ts +56 -0
- package/dist/friction/fingerprint.d.ts.map +1 -0
- package/dist/friction/fingerprint.js +113 -0
- package/dist/friction/fingerprint.js.map +1 -0
- package/dist/friction/friction-dispositions.record.descriptor.d.ts +4 -0
- package/dist/friction/friction-dispositions.record.descriptor.d.ts.map +1 -0
- package/dist/friction/friction-dispositions.record.descriptor.js +36 -0
- package/dist/friction/friction-dispositions.record.descriptor.js.map +1 -0
- package/dist/friction/friction-signals.record.descriptor.d.ts +12 -0
- package/dist/friction/friction-signals.record.descriptor.d.ts.map +1 -0
- package/dist/friction/friction-signals.record.descriptor.js +52 -0
- package/dist/friction/friction-signals.record.descriptor.js.map +1 -0
- package/dist/friction/intake.d.ts +79 -0
- package/dist/friction/intake.d.ts.map +1 -0
- package/dist/friction/intake.js +459 -0
- package/dist/friction/intake.js.map +1 -0
- package/dist/friction/jobs/friction-clusters.job.descriptor.d.ts +71 -0
- package/dist/friction/jobs/friction-clusters.job.descriptor.d.ts.map +1 -0
- package/dist/friction/jobs/friction-clusters.job.descriptor.js +34 -0
- package/dist/friction/jobs/friction-clusters.job.descriptor.js.map +1 -0
- package/dist/friction/jobs/friction-clusters.job.impl.d.ts +22 -0
- package/dist/friction/jobs/friction-clusters.job.impl.d.ts.map +1 -0
- package/dist/friction/jobs/friction-clusters.job.impl.js +33 -0
- package/dist/friction/jobs/friction-clusters.job.impl.js.map +1 -0
- package/dist/friction/promote-input.d.ts +37 -0
- package/dist/friction/promote-input.d.ts.map +1 -0
- package/dist/friction/promote-input.js +58 -0
- package/dist/friction/promote-input.js.map +1 -0
- package/dist/friction/promotion-visibility.d.ts +34 -0
- package/dist/friction/promotion-visibility.d.ts.map +1 -0
- package/dist/friction/promotion-visibility.js +57 -0
- package/dist/friction/promotion-visibility.js.map +1 -0
- package/dist/friction/read.d.ts +21 -0
- package/dist/friction/read.d.ts.map +1 -0
- package/dist/friction/read.js +23 -0
- package/dist/friction/read.js.map +1 -0
- package/dist/friction/reassign-org.d.ts +21 -0
- package/dist/friction/reassign-org.d.ts.map +1 -0
- package/dist/friction/reassign-org.js +121 -0
- package/dist/friction/reassign-org.js.map +1 -0
- package/dist/friction/schemas/disposition.d.ts +42 -0
- package/dist/friction/schemas/disposition.d.ts.map +1 -0
- package/dist/friction/schemas/disposition.js +22 -0
- package/dist/friction/schemas/disposition.js.map +1 -0
- package/dist/friction/schemas/intake.d.ts +167 -0
- package/dist/friction/schemas/intake.d.ts.map +1 -0
- package/dist/friction/schemas/intake.js +69 -0
- package/dist/friction/schemas/intake.js.map +1 -0
- package/dist/friction/schemas/report.d.ts +138 -0
- package/dist/friction/schemas/report.d.ts.map +1 -0
- package/dist/friction/schemas/report.js +63 -0
- package/dist/friction/schemas/report.js.map +1 -0
- package/dist/friction/schemas/signal.d.ts +170 -0
- package/dist/friction/schemas/signal.d.ts.map +1 -0
- package/dist/friction/schemas/signal.js +77 -0
- package/dist/friction/schemas/signal.js.map +1 -0
- package/dist/friction/signal-recorded.event.descriptor.d.ts +53 -0
- package/dist/friction/signal-recorded.event.descriptor.d.ts.map +1 -0
- package/dist/friction/signal-recorded.event.descriptor.js +38 -0
- package/dist/friction/signal-recorded.event.descriptor.js.map +1 -0
- package/dist/friction/store.d.ts +109 -0
- package/dist/friction/store.d.ts.map +1 -0
- package/dist/friction/store.js +466 -0
- package/dist/friction/store.js.map +1 -0
- package/dist/host-guidance/descriptors/accessibility.host-permission-guidance.descriptor.d.ts +8 -0
- package/dist/host-guidance/descriptors/accessibility.host-permission-guidance.descriptor.d.ts.map +1 -0
- package/dist/host-guidance/descriptors/accessibility.host-permission-guidance.descriptor.js +18 -0
- package/dist/host-guidance/descriptors/accessibility.host-permission-guidance.descriptor.js.map +1 -0
- package/dist/host-guidance/descriptors/disk.host-permission-guidance.descriptor.d.ts +8 -0
- package/dist/host-guidance/descriptors/disk.host-permission-guidance.descriptor.d.ts.map +1 -0
- package/dist/host-guidance/descriptors/disk.host-permission-guidance.descriptor.js +18 -0
- package/dist/host-guidance/descriptors/disk.host-permission-guidance.descriptor.js.map +1 -0
- package/dist/host-guidance/descriptors/homebrew.host-health-check.descriptor.d.ts +8 -0
- package/dist/host-guidance/descriptors/homebrew.host-health-check.descriptor.d.ts.map +1 -0
- package/dist/host-guidance/descriptors/homebrew.host-health-check.descriptor.js +14 -0
- package/dist/host-guidance/descriptors/homebrew.host-health-check.descriptor.js.map +1 -0
- package/dist/host-guidance/descriptors/microphone.host-permission-guidance.descriptor.d.ts +8 -0
- package/dist/host-guidance/descriptors/microphone.host-permission-guidance.descriptor.d.ts.map +1 -0
- package/dist/host-guidance/descriptors/microphone.host-permission-guidance.descriptor.js +18 -0
- package/dist/host-guidance/descriptors/microphone.host-permission-guidance.descriptor.js.map +1 -0
- package/dist/host-guidance/kinds/host-health-check.kind.d.ts +17 -0
- package/dist/host-guidance/kinds/host-health-check.kind.d.ts.map +1 -0
- package/dist/host-guidance/kinds/host-health-check.kind.js +22 -0
- package/dist/host-guidance/kinds/host-health-check.kind.js.map +1 -0
- package/dist/host-guidance/kinds/host-permission-guidance.kind.d.ts +17 -0
- package/dist/host-guidance/kinds/host-permission-guidance.kind.d.ts.map +1 -0
- package/dist/host-guidance/kinds/host-permission-guidance.kind.js +22 -0
- package/dist/host-guidance/kinds/host-permission-guidance.kind.js.map +1 -0
- package/dist/host-guidance/registry.d.ts +16 -0
- package/dist/host-guidance/registry.d.ts.map +1 -0
- package/dist/host-guidance/registry.js +24 -0
- package/dist/host-guidance/registry.js.map +1 -0
- package/dist/hq.cloud.plugin.d.ts +3 -0
- package/dist/hq.cloud.plugin.d.ts.map +1 -0
- package/dist/hq.cloud.plugin.js +40 -0
- package/dist/hq.cloud.plugin.js.map +1 -0
- package/dist/hq.consumer.plugin.d.ts +3 -0
- package/dist/hq.consumer.plugin.d.ts.map +1 -0
- package/dist/hq.consumer.plugin.js +15 -0
- package/dist/hq.consumer.plugin.js.map +1 -0
- package/dist/hq.plugin.d.ts +9 -0
- package/dist/hq.plugin.d.ts.map +1 -0
- package/dist/hq.plugin.js +99 -0
- package/dist/hq.plugin.js.map +1 -0
- package/dist/installers/builtin/ai-runtimes/installer.d.ts +21 -0
- package/dist/installers/builtin/ai-runtimes/installer.d.ts.map +1 -0
- package/dist/installers/builtin/ai-runtimes/installer.js +244 -0
- package/dist/installers/builtin/ai-runtimes/installer.js.map +1 -0
- package/dist/installers/builtin/index.d.ts +9 -0
- package/dist/installers/builtin/index.d.ts.map +1 -0
- package/dist/installers/builtin/index.js +15 -0
- package/dist/installers/builtin/index.js.map +1 -0
- package/dist/installers/builtin/language-servers/installer.d.ts +18 -0
- package/dist/installers/builtin/language-servers/installer.d.ts.map +1 -0
- package/dist/installers/builtin/language-servers/installer.js +139 -0
- package/dist/installers/builtin/language-servers/installer.js.map +1 -0
- package/dist/installers/builtin/system-deps/installer.d.ts +8 -0
- package/dist/installers/builtin/system-deps/installer.d.ts.map +1 -0
- package/dist/installers/builtin/system-deps/installer.js +78 -0
- package/dist/installers/builtin/system-deps/installer.js.map +1 -0
- package/dist/installers/compatibility.consumer.plugin.d.ts +3 -0
- package/dist/installers/compatibility.consumer.plugin.d.ts.map +1 -0
- package/dist/installers/compatibility.consumer.plugin.js +26 -0
- package/dist/installers/compatibility.consumer.plugin.js.map +1 -0
- package/dist/installers/core/index.d.ts +3 -0
- package/dist/installers/core/index.d.ts.map +1 -0
- package/dist/installers/core/index.js +3 -0
- package/dist/installers/core/index.js.map +1 -0
- package/dist/installers/core/installer-result.d.ts +10 -0
- package/dist/installers/core/installer-result.d.ts.map +1 -0
- package/dist/installers/core/installer-result.js +14 -0
- package/dist/installers/core/installer-result.js.map +1 -0
- package/dist/installers/core/installer-runtime.d.ts +18 -0
- package/dist/installers/core/installer-runtime.d.ts.map +1 -0
- package/dist/installers/core/installer-runtime.js +5 -0
- package/dist/installers/core/installer-runtime.js.map +1 -0
- package/dist/installers/core/platform.d.ts +6 -0
- package/dist/installers/core/platform.d.ts.map +1 -0
- package/dist/installers/core/platform.js +19 -0
- package/dist/installers/core/platform.js.map +1 -0
- package/dist/installers/core/workspace.d.ts +4 -0
- package/dist/installers/core/workspace.d.ts.map +1 -0
- package/dist/installers/core/workspace.js +11 -0
- package/dist/installers/core/workspace.js.map +1 -0
- package/dist/installers/index.d.ts +6 -0
- package/dist/installers/index.d.ts.map +1 -0
- package/dist/installers/index.js +6 -0
- package/dist/installers/index.js.map +1 -0
- package/dist/installers/schemas/index.d.ts +2 -0
- package/dist/installers/schemas/index.d.ts.map +1 -0
- package/dist/installers/schemas/index.js +2 -0
- package/dist/installers/schemas/index.js.map +1 -0
- package/dist/installers/schemas/platform.d.ts +10 -0
- package/dist/installers/schemas/platform.d.ts.map +1 -0
- package/dist/installers/schemas/platform.js +9 -0
- package/dist/installers/schemas/platform.js.map +1 -0
- package/dist/installers/schemas/types.d.ts +4 -0
- package/dist/installers/schemas/types.d.ts.map +1 -0
- package/dist/installers/schemas/types.js +4 -0
- package/dist/installers/schemas/types.js.map +1 -0
- package/dist/os-wall/channels.wall.d.ts +9 -0
- package/dist/os-wall/channels.wall.d.ts.map +1 -0
- package/dist/os-wall/channels.wall.js +9 -0
- package/dist/os-wall/channels.wall.js.map +1 -0
- package/dist/os-wall/surface-store.wall.d.ts +3 -0
- package/dist/os-wall/surface-store.wall.d.ts.map +1 -0
- package/dist/os-wall/surface-store.wall.js +3 -0
- package/dist/os-wall/surface-store.wall.js.map +1 -0
- package/dist/runtime-path.d.ts +7 -0
- package/dist/runtime-path.d.ts.map +1 -0
- package/dist/runtime-path.js +7 -0
- package/dist/runtime-path.js.map +1 -0
- package/dist/schemas/host-guidance.d.ts +48 -0
- package/dist/schemas/host-guidance.d.ts.map +1 -0
- package/dist/schemas/host-guidance.js +48 -0
- package/dist/schemas/host-guidance.js.map +1 -0
- package/dist/services/backends/index.d.ts +24 -0
- package/dist/services/backends/index.d.ts.map +1 -0
- package/dist/services/backends/index.js +17 -0
- package/dist/services/backends/index.js.map +1 -0
- package/dist/services/builtin/index.d.ts +78 -0
- package/dist/services/builtin/index.d.ts.map +1 -0
- package/dist/services/builtin/index.js +44 -0
- package/dist/services/builtin/index.js.map +1 -0
- package/dist/services/descriptors/vibes-bridge.os-service.descriptor.d.ts +8 -0
- package/dist/services/descriptors/vibes-bridge.os-service.descriptor.d.ts.map +1 -0
- package/dist/services/descriptors/vibes-bridge.os-service.descriptor.js +21 -0
- package/dist/services/descriptors/vibes-bridge.os-service.descriptor.js.map +1 -0
- package/dist/services/descriptors/vibes-mcp.os-service.descriptor.d.ts +8 -0
- package/dist/services/descriptors/vibes-mcp.os-service.descriptor.d.ts.map +1 -0
- package/dist/services/descriptors/vibes-mcp.os-service.descriptor.js +20 -0
- package/dist/services/descriptors/vibes-mcp.os-service.descriptor.js.map +1 -0
- package/dist/services/descriptors/vibes-pm.os-service.descriptor.d.ts +8 -0
- package/dist/services/descriptors/vibes-pm.os-service.descriptor.d.ts.map +1 -0
- package/dist/services/descriptors/vibes-pm.os-service.descriptor.js +20 -0
- package/dist/services/descriptors/vibes-pm.os-service.descriptor.js.map +1 -0
- package/dist/services/index.d.ts +14 -0
- package/dist/services/index.d.ts.map +1 -0
- package/dist/services/index.js +12 -0
- package/dist/services/index.js.map +1 -0
- package/dist/services/kinds/os-service.kind.d.ts +19 -0
- package/dist/services/kinds/os-service.kind.d.ts.map +1 -0
- package/dist/services/kinds/os-service.kind.js +24 -0
- package/dist/services/kinds/os-service.kind.js.map +1 -0
- package/dist/services/registry.d.ts +45 -0
- package/dist/services/registry.d.ts.map +1 -0
- package/dist/services/registry.js +141 -0
- package/dist/services/registry.js.map +1 -0
- package/dist/services/schemas/service.d.ts +79 -0
- package/dist/services/schemas/service.d.ts.map +1 -0
- package/dist/services/schemas/service.js +82 -0
- package/dist/services/schemas/service.js.map +1 -0
- package/dist/svelte/report/ReportProblemDialog.svelte +205 -0
- package/dist/svelte/report/ReportProblemDialog.svelte.d.ts +5 -0
- package/dist/svelte/report/ReportProblemDialog.svelte.d.ts.map +1 -0
- package/dist/svelte/report/capture-context.d.ts +61 -0
- package/dist/svelte/report/capture-context.d.ts.map +1 -0
- package/dist/svelte/report/capture-context.js +100 -0
- package/dist/svelte/report/report.plugin.d.ts +68 -0
- package/dist/svelte/report/report.plugin.d.ts.map +1 -0
- package/dist/svelte/report/report.plugin.js +109 -0
- package/dist/svelte/report/severity.d.ts +32 -0
- package/dist/svelte/report/severity.d.ts.map +1 -0
- package/dist/svelte/report/severity.js +13 -0
- package/dist/tools/applet/applet.schemas.d.ts +6 -0
- package/dist/tools/applet/applet.schemas.d.ts.map +1 -0
- package/dist/tools/applet/applet.schemas.js +6 -0
- package/dist/tools/applet/applet.schemas.js.map +1 -0
- package/dist/utils/exec.d.ts +22 -0
- package/dist/utils/exec.d.ts.map +1 -0
- package/dist/utils/exec.js +38 -0
- package/dist/utils/exec.js.map +1 -0
- package/dist/utils/fs.d.ts +10 -0
- package/dist/utils/fs.d.ts.map +1 -0
- package/dist/utils/fs.js +25 -0
- package/dist/utils/fs.js.map +1 -0
- package/package.json +268 -4
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Report capture: the page facts a "Report a problem" submit carries, read
|
|
3
|
+
* through the handed runtime only. Page facts come from the runtime browser
|
|
4
|
+
* host (`runtime/browser-host` `readPage`), the version from the host fact
|
|
5
|
+
* `hostVersion`, and recent errors from logging's ring-buffer reader. Nothing
|
|
6
|
+
* here reads `window`, `document` or `navigator`.
|
|
7
|
+
*
|
|
8
|
+
* `buildFrictionReportBody` produces the one parsed body the dialog previews
|
|
9
|
+
* and submits, so the preview is exactly what is sent.
|
|
10
|
+
*/
|
|
11
|
+
import { CapabilityError, getRuntimeBrowserHost } from '@vibesdotdev/kernel';
|
|
12
|
+
import { readRecentBrowserErrors } from '@vibesdotdev/logging/browser';
|
|
13
|
+
import { FRICTION_REPORT_MAX_ERRORS, FrictionReportErrorSchema } from "../../friction/schemas/report.js";
|
|
14
|
+
import { FrictionReportInputSchema } from "../../friction/schemas/intake.js";
|
|
15
|
+
const MESSAGE_MAX = FrictionReportErrorSchema.shape.message.maxLength ?? 2000;
|
|
16
|
+
const STACK_MAX = 8000;
|
|
17
|
+
/** The page URL without its query or fragment, which may carry tokens or personal data. */
|
|
18
|
+
export function stripQueryAndFragment(url) {
|
|
19
|
+
const parsed = new URL(url);
|
|
20
|
+
parsed.search = '';
|
|
21
|
+
parsed.hash = '';
|
|
22
|
+
return parsed.toString();
|
|
23
|
+
}
|
|
24
|
+
/** Errors older than this are not this page's problem; the ring buffer keeps days of them. */
|
|
25
|
+
export const REPORT_ERROR_WINDOW_MS = 60 * 60 * 1000;
|
|
26
|
+
const ID_LIKE_SEGMENT = /^(?:\d+|[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}|[0-9a-z_-]{20,}|[0-9a-f]{12,})$/i;
|
|
27
|
+
/**
|
|
28
|
+
* A route template for a path when the host hands none: every id-like segment
|
|
29
|
+
* (numbers, UUIDs, long hex or opaque tokens) and anything carrying `@` or `%`
|
|
30
|
+
* becomes `[id]`, so reports on different entities group together and the
|
|
31
|
+
* route never carries an identifier the redactor does not see.
|
|
32
|
+
*/
|
|
33
|
+
export function routeTemplateFromPath(pathname) {
|
|
34
|
+
const segments = pathname.split('/').map(segment => (segment && (ID_LIKE_SEGMENT.test(segment) || /[@%]/.test(segment)) ? '[id]' : segment));
|
|
35
|
+
return segments.join('/') || '/';
|
|
36
|
+
}
|
|
37
|
+
function surfaceErrorEntry(error, at) {
|
|
38
|
+
const message = error.message?.trim() ? `${error.status}: ${error.message.trim()}` : `HTTP ${error.status}`;
|
|
39
|
+
return { message: message.slice(0, MESSAGE_MAX), at, source: 'sveltekit' };
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Capture the current page. A host with no page facts refuses
|
|
43
|
+
* `UNAVAILABLE browser-page-unavailable`; a host with no browser host refuses
|
|
44
|
+
* `UNAVAILABLE browser-host-unavailable`. On an error surface, the surface's
|
|
45
|
+
* own error is included even when no boundary recorded it, so a signed-out
|
|
46
|
+
* visitor's report always carries its error condition.
|
|
47
|
+
*/
|
|
48
|
+
export async function captureReportContext(runtime, options = {}) {
|
|
49
|
+
const host = await getRuntimeBrowserHost(runtime);
|
|
50
|
+
if (!host.readPage) {
|
|
51
|
+
throw new CapabilityError('The selected browser host offers no page facts.', 'UNAVAILABLE', {
|
|
52
|
+
reason: 'browser-page-unavailable', retryable: false
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
const page = host.readPage();
|
|
56
|
+
const url = stripQueryAndFragment(page.url);
|
|
57
|
+
const now = (options.now ?? (() => new Date()))();
|
|
58
|
+
const since = new Date(now.getTime() - REPORT_ERROR_WINDOW_MS).toISOString();
|
|
59
|
+
const recorded = await readRecentBrowserErrors(runtime, { limit: FRICTION_REPORT_MAX_ERRORS, since });
|
|
60
|
+
const errors = recorded.filter(event => event.message.trim()).map(event => {
|
|
61
|
+
const entry = { message: event.message.slice(0, MESSAGE_MAX), at: event.timestamp, source: event.source };
|
|
62
|
+
if (event.stack)
|
|
63
|
+
entry.stack = event.stack.slice(0, STACK_MAX);
|
|
64
|
+
return entry;
|
|
65
|
+
});
|
|
66
|
+
const surfaceError = options.error;
|
|
67
|
+
if (surfaceError) {
|
|
68
|
+
const already = recorded.some(event => event.status === surfaceError.status && (!surfaceError.message || event.message === surfaceError.message));
|
|
69
|
+
if (!already)
|
|
70
|
+
errors.push(surfaceErrorEntry(surfaceError, now.toISOString()));
|
|
71
|
+
}
|
|
72
|
+
const capture = {
|
|
73
|
+
route: options.route?.trim() || routeTemplateFromPath(new URL(url).pathname),
|
|
74
|
+
url,
|
|
75
|
+
viewport: { width: Math.round(page.viewport.width), height: Math.round(page.viewport.height) },
|
|
76
|
+
userAgent: page.userAgent.slice(0, 500),
|
|
77
|
+
locale: page.locale.slice(0, 35),
|
|
78
|
+
errors: errors.slice(-FRICTION_REPORT_MAX_ERRORS),
|
|
79
|
+
attachments: []
|
|
80
|
+
};
|
|
81
|
+
const appVersion = runtime.localEnvironment.hostVersion?.();
|
|
82
|
+
if (appVersion)
|
|
83
|
+
capture.appVersion = appVersion;
|
|
84
|
+
return capture;
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* The one body the dialog previews and submits. It is parsed through the
|
|
88
|
+
* intake's own schema, so defaults and trimming are already applied, and a
|
|
89
|
+
* body the intake would refuse is refused here, before anything is sent.
|
|
90
|
+
*/
|
|
91
|
+
export function buildFrictionReportBody(form, capture, occurrenceId) {
|
|
92
|
+
return FrictionReportInputSchema.safeParse({
|
|
93
|
+
severity: form.severity,
|
|
94
|
+
observed: form.description,
|
|
95
|
+
// The intake schema trims it and drops an empty answer.
|
|
96
|
+
expected: form.expected,
|
|
97
|
+
context: capture,
|
|
98
|
+
occurrenceId
|
|
99
|
+
});
|
|
100
|
+
}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* HQ "Report a problem" on every page.
|
|
3
|
+
*
|
|
4
|
+
* Contributes the `hq.report-problem` utility to Kit's `app-shell/utility`
|
|
5
|
+
* kind (Kit renders the trigger and mounts `ReportProblemDialog`), and a
|
|
6
|
+
* `command-palette/source` entry that asks Kit to open the same utility.
|
|
7
|
+
* Visibility is Kit's `on-error` rule: signed-in viewers always see it;
|
|
8
|
+
* signed-out visitors see it only on Kit's error surface.
|
|
9
|
+
*
|
|
10
|
+
* Compose `@vibesdotdev/hq/svelte/report.plugin` into an app's browser
|
|
11
|
+
* runtime; suite apps get it through `VibesAppShell`.
|
|
12
|
+
*/
|
|
13
|
+
import { type RuntimeRef } from '@vibesdotdev/kernel';
|
|
14
|
+
import type { KindContext } from '@vibesdotdev/kernel/schemas/kind';
|
|
15
|
+
import type { CommandPaletteResult, CommandPaletteSourceDescriptor, CommandPaletteSourceImplementation, SourceContext } from '@vibesdotdev/command-palette/schemas';
|
|
16
|
+
export declare const REPORT_PROBLEM_UTILITY_ID = "hq.report-problem";
|
|
17
|
+
export declare const reportProblemUtilityDescriptor: {
|
|
18
|
+
kind: "app-shell/utility";
|
|
19
|
+
id: string;
|
|
20
|
+
name: string;
|
|
21
|
+
icon: string;
|
|
22
|
+
placement: "header" | "user-menu";
|
|
23
|
+
order: number;
|
|
24
|
+
visibility: "always" | "signed-in" | "on-error";
|
|
25
|
+
enabled: boolean;
|
|
26
|
+
tags?: string[] | undefined;
|
|
27
|
+
hardware?: string[] | undefined;
|
|
28
|
+
priority?: number | undefined;
|
|
29
|
+
capabilityId?: string | undefined;
|
|
30
|
+
requiredContext?: string[] | undefined;
|
|
31
|
+
optionalContext?: string[] | undefined;
|
|
32
|
+
config?: unknown;
|
|
33
|
+
retention?: string | {
|
|
34
|
+
reason: string;
|
|
35
|
+
maxAgeDays?: number | undefined;
|
|
36
|
+
maxEntries?: number | undefined;
|
|
37
|
+
maxBytes?: number | undefined;
|
|
38
|
+
cascadeFrom?: string | undefined;
|
|
39
|
+
ageField?: string | undefined;
|
|
40
|
+
enforcedBy?: string | undefined;
|
|
41
|
+
} | undefined;
|
|
42
|
+
description?: string | undefined;
|
|
43
|
+
};
|
|
44
|
+
/** The palette entry matches an empty query or any keyword prefix. */
|
|
45
|
+
export declare function matchesReportQuery(query: string): boolean;
|
|
46
|
+
/** One palette result that opens the report utility through Kit's runtime-scoped open request. */
|
|
47
|
+
export declare function createReportProblemPaletteSource(runtime: RuntimeRef): CommandPaletteSourceImplementation;
|
|
48
|
+
export declare class ReportProblemPaletteSource implements CommandPaletteSourceImplementation {
|
|
49
|
+
private readonly _descriptor;
|
|
50
|
+
private readonly context;
|
|
51
|
+
constructor(_descriptor: CommandPaletteSourceDescriptor, context: KindContext);
|
|
52
|
+
search(query: string, context: SourceContext): Promise<CommandPaletteResult[]>;
|
|
53
|
+
}
|
|
54
|
+
export declare const reportProblemPaletteSourceDescriptor: {
|
|
55
|
+
id: string;
|
|
56
|
+
kind: "command-palette/source";
|
|
57
|
+
enabled: true;
|
|
58
|
+
sourceId: string;
|
|
59
|
+
resultType: string;
|
|
60
|
+
label: string;
|
|
61
|
+
priority: number;
|
|
62
|
+
surfaces: string[];
|
|
63
|
+
name: string;
|
|
64
|
+
description: string;
|
|
65
|
+
};
|
|
66
|
+
export declare const reportProblemPlugin: import("@vibesdotdev/kernel").RuntimePlugin;
|
|
67
|
+
export default reportProblemPlugin;
|
|
68
|
+
//# sourceMappingURL=report.plugin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"report.plugin.d.ts","sourceRoot":"","sources":["../../../src/svelte/report/report.plugin.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAA+B,KAAK,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACnF,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kCAAkC,CAAC;AAGpE,OAAO,KAAK,EACX,oBAAoB,EACpB,8BAA8B,EAC9B,kCAAkC,EAClC,aAAa,EACb,MAAM,sCAAsC,CAAC;AAE9C,eAAO,MAAM,yBAAyB,sBAAsB,CAAC;AAE7D,eAAO,MAAM,8BAA8B;;;;;;;;;;;;;;;;;;;;;;;;;;CAQzC,CAAC;AAIH,sEAAsE;AACtE,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAIzD;AAED,kGAAkG;AAClG,wBAAgB,gCAAgC,CAAC,OAAO,EAAE,UAAU,GAAG,kCAAkC,CAuBxG;AAED,qBAAa,0BAA2B,YAAW,kCAAkC;IAEnF,OAAO,CAAC,QAAQ,CAAC,WAAW;IAC5B,OAAO,CAAC,QAAQ,CAAC,OAAO;gBADP,WAAW,EAAE,8BAA8B,EAC3C,OAAO,EAAE,WAAW;IAGtC,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,aAAa,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;CAG9E;AAED,eAAO,MAAM,oCAAoC;;;;;;;;;;;CAWP,CAAC;AAE3C,eAAO,MAAM,mBAAmB,6CAwB9B,CAAC;AAEH,eAAe,mBAAmB,CAAC"}
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* HQ "Report a problem" on every page.
|
|
3
|
+
*
|
|
4
|
+
* Contributes the `hq.report-problem` utility to Kit's `app-shell/utility`
|
|
5
|
+
* kind (Kit renders the trigger and mounts `ReportProblemDialog`), and a
|
|
6
|
+
* `command-palette/source` entry that asks Kit to open the same utility.
|
|
7
|
+
* Visibility is Kit's `on-error` rule: signed-in viewers always see it;
|
|
8
|
+
* signed-out visitors see it only on Kit's error surface.
|
|
9
|
+
*
|
|
10
|
+
* Compose `@vibesdotdev/hq/svelte/report.plugin` into an app's browser
|
|
11
|
+
* runtime; suite apps get it through `VibesAppShell`.
|
|
12
|
+
*/
|
|
13
|
+
import { createRuntimePlugin, loader } from '@vibesdotdev/kernel';
|
|
14
|
+
import { APP_SHELL_PLUGIN_ID, defineAppShellUtility } from '@vibesdotdev/kit/app-shell/utility';
|
|
15
|
+
import frictionClientDescriptor from "../../client/friction.client.descriptor.js";
|
|
16
|
+
export const REPORT_PROBLEM_UTILITY_ID = 'hq.report-problem';
|
|
17
|
+
export const reportProblemUtilityDescriptor = defineAppShellUtility({
|
|
18
|
+
id: REPORT_PROBLEM_UTILITY_ID,
|
|
19
|
+
name: 'Report a problem',
|
|
20
|
+
description: 'Tell us what went wrong on this page.',
|
|
21
|
+
icon: 'lucide:bug',
|
|
22
|
+
placement: 'header',
|
|
23
|
+
order: 100,
|
|
24
|
+
visibility: 'on-error'
|
|
25
|
+
});
|
|
26
|
+
const PALETTE_KEYWORDS = ['report', 'problem', 'bug', 'issue', 'feedback', 'broken', 'error'];
|
|
27
|
+
/** The palette entry matches an empty query or any keyword prefix. */
|
|
28
|
+
export function matchesReportQuery(query) {
|
|
29
|
+
const words = query.trim().toLowerCase().split(/\s+/).filter(Boolean);
|
|
30
|
+
if (words.length === 0)
|
|
31
|
+
return true;
|
|
32
|
+
return words.every(word => PALETTE_KEYWORDS.some(keyword => keyword.startsWith(word) || 'report a problem'.includes(word)));
|
|
33
|
+
}
|
|
34
|
+
/** One palette result that opens the report utility through Kit's runtime-scoped open request. */
|
|
35
|
+
export function createReportProblemPaletteSource(runtime) {
|
|
36
|
+
return {
|
|
37
|
+
async search(query, _context) {
|
|
38
|
+
if (!matchesReportQuery(query))
|
|
39
|
+
return [];
|
|
40
|
+
return [{
|
|
41
|
+
id: REPORT_PROBLEM_UTILITY_ID,
|
|
42
|
+
sourceId: REPORT_PROBLEM_UTILITY_ID,
|
|
43
|
+
resultType: 'action',
|
|
44
|
+
title: 'Report a problem',
|
|
45
|
+
description: 'Tell us what went wrong on this page',
|
|
46
|
+
icon: 'lucide:bug',
|
|
47
|
+
keywords: PALETTE_KEYWORDS,
|
|
48
|
+
action: {
|
|
49
|
+
type: 'execute',
|
|
50
|
+
handler: async () => {
|
|
51
|
+
const { openAppShellUtility } = await import('@vibesdotdev/kit/app-shell/utility');
|
|
52
|
+
// Resolves false when no mounted surface shows the utility to this viewer: a no-op by Kit's contract.
|
|
53
|
+
await openAppShellUtility(runtime, REPORT_PROBLEM_UTILITY_ID);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}];
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
export class ReportProblemPaletteSource {
|
|
61
|
+
_descriptor;
|
|
62
|
+
context;
|
|
63
|
+
constructor(_descriptor, context) {
|
|
64
|
+
this._descriptor = _descriptor;
|
|
65
|
+
this.context = context;
|
|
66
|
+
}
|
|
67
|
+
search(query, context) {
|
|
68
|
+
return createReportProblemPaletteSource(this.context.runtime).search(query, context);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
export const reportProblemPaletteSourceDescriptor = {
|
|
72
|
+
id: REPORT_PROBLEM_UTILITY_ID,
|
|
73
|
+
kind: 'command-palette/source',
|
|
74
|
+
enabled: true,
|
|
75
|
+
sourceId: REPORT_PROBLEM_UTILITY_ID,
|
|
76
|
+
resultType: 'action',
|
|
77
|
+
label: 'Report a problem',
|
|
78
|
+
priority: 40,
|
|
79
|
+
surfaces: ['web'],
|
|
80
|
+
name: 'Report a problem',
|
|
81
|
+
description: 'Open the HQ report dialog from the command palette'
|
|
82
|
+
};
|
|
83
|
+
export const reportProblemPlugin = createRuntimePlugin({
|
|
84
|
+
id: '@vibesdotdev/hq/svelte/report',
|
|
85
|
+
name: 'HQ Report a problem',
|
|
86
|
+
description: 'Adds "Report a problem" to every page through the app shell and, where composed, the command palette',
|
|
87
|
+
dependencies: [APP_SHELL_PLUGIN_ID, 'runtime-client'],
|
|
88
|
+
// The palette is optional: an app without it still gets the shell utility.
|
|
89
|
+
optionalDependencies: ['command-palette'],
|
|
90
|
+
descriptors: [reportProblemUtilityDescriptor],
|
|
91
|
+
loaders: [
|
|
92
|
+
loader(REPORT_PROBLEM_UTILITY_ID, { kind: 'app-shell/utility', scope: 'browser' }, async () => ({
|
|
93
|
+
impl: (await import('./ReportProblemDialog.svelte')).default
|
|
94
|
+
}))
|
|
95
|
+
],
|
|
96
|
+
onRegister(runtime) {
|
|
97
|
+
// The dialog submits through the runtime's `friction` client. An app that
|
|
98
|
+
// already composes HQ's client keeps its own; any other gets it here.
|
|
99
|
+
if (runtime.query('runtime/client').withId('friction').descriptors().length === 0) {
|
|
100
|
+
runtime.registerDescriptor('runtime/client', frictionClientDescriptor);
|
|
101
|
+
runtime.registerLoader('runtime/client', 'friction', async () => ({ impl: (await import("../../client/friction/index.js")).FrictionClient }));
|
|
102
|
+
}
|
|
103
|
+
if (!runtime.hasKind('command-palette/source'))
|
|
104
|
+
return;
|
|
105
|
+
runtime.registerDescriptor('command-palette/source', reportProblemPaletteSourceDescriptor);
|
|
106
|
+
runtime.registerLoader('command-palette/source', REPORT_PROBLEM_UTILITY_ID, async () => ({ impl: ReportProblemPaletteSource }));
|
|
107
|
+
}
|
|
108
|
+
});
|
|
109
|
+
export default reportProblemPlugin;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The dialog's severity choices, each mapped to exactly one friction
|
|
3
|
+
* severity. The reporter picks how the problem affects them; the stored
|
|
4
|
+
* signal carries the friction severity that promotion reads.
|
|
5
|
+
*/
|
|
6
|
+
import type { FrictionSeverity } from '../../friction/schemas/signal.ts';
|
|
7
|
+
export interface ReportSeverityOption {
|
|
8
|
+
/** The friction severity this choice records. */
|
|
9
|
+
readonly severity: FrictionSeverity;
|
|
10
|
+
readonly label: string;
|
|
11
|
+
readonly hint: string;
|
|
12
|
+
}
|
|
13
|
+
/** In display order; the default is `annoyance`, matching the intake's default. */
|
|
14
|
+
export declare const REPORT_SEVERITY_OPTIONS: readonly [{
|
|
15
|
+
readonly severity: "blocker";
|
|
16
|
+
readonly label: "It's stopping me";
|
|
17
|
+
readonly hint: "I can't finish what I was doing.";
|
|
18
|
+
}, {
|
|
19
|
+
readonly severity: "annoyance";
|
|
20
|
+
readonly label: "It's getting in my way";
|
|
21
|
+
readonly hint: "Something is broken, but I can work around it.";
|
|
22
|
+
}, {
|
|
23
|
+
readonly severity: "confusion";
|
|
24
|
+
readonly label: "I'm not sure what happened";
|
|
25
|
+
readonly hint: "Something was unclear or unexpected.";
|
|
26
|
+
}, {
|
|
27
|
+
readonly severity: "nice-to-have";
|
|
28
|
+
readonly label: "It could be better";
|
|
29
|
+
readonly hint: "An idea or a small improvement.";
|
|
30
|
+
}];
|
|
31
|
+
export declare const DEFAULT_REPORT_SEVERITY: FrictionSeverity;
|
|
32
|
+
//# sourceMappingURL=severity.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"severity.d.ts","sourceRoot":"","sources":["../../../src/svelte/report/severity.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AAEzE,MAAM,WAAW,oBAAoB;IACpC,iDAAiD;IACjD,QAAQ,CAAC,QAAQ,EAAE,gBAAgB,CAAC;IACpC,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;CACtB;AAED,mFAAmF;AACnF,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;EAKgB,CAAC;AAErD,eAAO,MAAM,uBAAuB,EAAE,gBAA8B,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The dialog's severity choices, each mapped to exactly one friction
|
|
3
|
+
* severity. The reporter picks how the problem affects them; the stored
|
|
4
|
+
* signal carries the friction severity that promotion reads.
|
|
5
|
+
*/
|
|
6
|
+
/** In display order; the default is `annoyance`, matching the intake's default. */
|
|
7
|
+
export const REPORT_SEVERITY_OPTIONS = [
|
|
8
|
+
{ severity: 'blocker', label: "It's stopping me", hint: "I can't finish what I was doing." },
|
|
9
|
+
{ severity: 'annoyance', label: "It's getting in my way", hint: 'Something is broken, but I can work around it.' },
|
|
10
|
+
{ severity: 'confusion', label: "I'm not sure what happened", hint: 'Something was unclear or unexpected.' },
|
|
11
|
+
{ severity: 'nice-to-have', label: 'It could be better', hint: 'An idea or a small improvement.' }
|
|
12
|
+
];
|
|
13
|
+
export const DEFAULT_REPORT_SEVERITY = 'annoyance';
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Re-export from @vibesdotdev/applets — ownership moved in Tranche 3 Task 3.4.
|
|
3
|
+
* Kept as a local shim so existing HQ-internal imports don't all change at once.
|
|
4
|
+
*/
|
|
5
|
+
export { AppletSourceFormatSchema, AppletOwnerSchema, AppletStoreSchema, AppletAdoptionSchema, AppletActionInputSchema, AppletSummarySchema, AppletTemplateSummarySchema, AppletActionOutputSchema, type AppletActionInput, type AppletActionOutput, type AppletSummary, type AppletTemplateSummary, type AppletOwner, type AppletStore, type AppletAdoption, type SurfaceArtifactInput } from '@vibesdotdev/applets/tools';
|
|
6
|
+
//# sourceMappingURL=applet.schemas.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"applet.schemas.d.ts","sourceRoot":"","sources":["../../../src/tools/applet/applet.schemas.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EACN,wBAAwB,EACxB,iBAAiB,EACjB,iBAAiB,EACjB,oBAAoB,EACpB,uBAAuB,EACvB,mBAAmB,EACnB,2BAA2B,EAC3B,wBAAwB,EACxB,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,EACvB,KAAK,aAAa,EAClB,KAAK,qBAAqB,EAC1B,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,cAAc,EACnB,KAAK,oBAAoB,EACzB,MAAM,4BAA4B,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Re-export from @vibesdotdev/applets — ownership moved in Tranche 3 Task 3.4.
|
|
3
|
+
* Kept as a local shim so existing HQ-internal imports don't all change at once.
|
|
4
|
+
*/
|
|
5
|
+
export { AppletSourceFormatSchema, AppletOwnerSchema, AppletStoreSchema, AppletAdoptionSchema, AppletActionInputSchema, AppletSummarySchema, AppletTemplateSummarySchema, AppletActionOutputSchema } from '@vibesdotdev/applets/tools';
|
|
6
|
+
//# sourceMappingURL=applet.schemas.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"applet.schemas.js","sourceRoot":"","sources":["../../../src/tools/applet/applet.schemas.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EACN,wBAAwB,EACxB,iBAAiB,EACjB,iBAAiB,EACjB,oBAAoB,EACpB,uBAAuB,EACvB,mBAAmB,EACnB,2BAA2B,EAC3B,wBAAwB,EASxB,MAAM,4BAA4B,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* hq's process-spawn composition the `runtime/execution` kind does not
|
|
3
|
+
* offer: run a command with inherited stdio and await its exit code.
|
|
4
|
+
* Capture and command discovery come straight from
|
|
5
|
+
* `@vibesdotdev/kernel/execution` (`runCapture`, `whichCommand`); nothing
|
|
6
|
+
* here duplicates them (hq PROPOSAL X8).
|
|
7
|
+
*/
|
|
8
|
+
import type { RuntimeRef } from '@vibesdotdev/kernel';
|
|
9
|
+
import { type ExecutionEnvironmentMode } from '@vibesdotdev/kernel/execution';
|
|
10
|
+
export type RunInheritOptions = {
|
|
11
|
+
cwd?: string;
|
|
12
|
+
env?: Record<string, string | undefined>;
|
|
13
|
+
envMode: ExecutionEnvironmentMode;
|
|
14
|
+
inheritReason?: string;
|
|
15
|
+
};
|
|
16
|
+
/**
|
|
17
|
+
* Spawn a command with stdout/stderr inherited and await its exit code.
|
|
18
|
+
* A signal kill (no exit code) answers -1. A launch failure rejects with
|
|
19
|
+
* the execution owner's typed refusal.
|
|
20
|
+
*/
|
|
21
|
+
export declare function runInherit(runtime: RuntimeRef, cmd: string, args: readonly string[], options: RunInheritOptions): Promise<number>;
|
|
22
|
+
//# sourceMappingURL=exec.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exec.d.ts","sourceRoot":"","sources":["../../src/utils/exec.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACtD,OAAO,EAEN,KAAK,wBAAwB,EAC7B,MAAM,+BAA+B,CAAC;AAEvC,MAAM,MAAM,iBAAiB,GAAG;IAC/B,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAC;IACzC,OAAO,EAAE,wBAAwB,CAAC;IAClC,aAAa,CAAC,EAAE,MAAM,CAAC;CACvB,CAAC;AAEF;;;;GAIG;AACH,wBAAsB,UAAU,CAC/B,OAAO,EAAE,UAAU,EACnB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,SAAS,MAAM,EAAE,EACvB,OAAO,EAAE,iBAAiB,GACxB,OAAO,CAAC,MAAM,CAAC,CAqBjB"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* hq's process-spawn composition the `runtime/execution` kind does not
|
|
3
|
+
* offer: run a command with inherited stdio and await its exit code.
|
|
4
|
+
* Capture and command discovery come straight from
|
|
5
|
+
* `@vibesdotdev/kernel/execution` (`runCapture`, `whichCommand`); nothing
|
|
6
|
+
* here duplicates them (hq PROPOSAL X8).
|
|
7
|
+
*/
|
|
8
|
+
import { getRuntimeExecution } from '@vibesdotdev/kernel/execution';
|
|
9
|
+
/**
|
|
10
|
+
* Spawn a command with stdout/stderr inherited and await its exit code.
|
|
11
|
+
* A signal kill (no exit code) answers -1. A launch failure rejects with
|
|
12
|
+
* the execution owner's typed refusal.
|
|
13
|
+
*/
|
|
14
|
+
export async function runInherit(runtime, cmd, args, options) {
|
|
15
|
+
const execution = await getRuntimeExecution(runtime);
|
|
16
|
+
const env = {};
|
|
17
|
+
const unsetEnv = [];
|
|
18
|
+
for (const [key, value] of Object.entries(options.env ?? {})) {
|
|
19
|
+
if (value === undefined)
|
|
20
|
+
unsetEnv.push(key);
|
|
21
|
+
else
|
|
22
|
+
env[key] = value;
|
|
23
|
+
}
|
|
24
|
+
const handle = await execution.spawn({
|
|
25
|
+
command: cmd,
|
|
26
|
+
args: [...args],
|
|
27
|
+
cwd: options.cwd,
|
|
28
|
+
env,
|
|
29
|
+
unsetEnv,
|
|
30
|
+
envMode: options.envMode,
|
|
31
|
+
inheritReason: options.inheritReason,
|
|
32
|
+
stdout: 'inherit',
|
|
33
|
+
stderr: 'inherit'
|
|
34
|
+
});
|
|
35
|
+
const { code } = await handle.exited;
|
|
36
|
+
return code ?? -1;
|
|
37
|
+
}
|
|
38
|
+
//# sourceMappingURL=exec.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exec.js","sourceRoot":"","sources":["../../src/utils/exec.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,EACN,mBAAmB,EAEnB,MAAM,+BAA+B,CAAC;AASvC;;;;GAIG;AACH,MAAM,CAAC,KAAK,UAAU,UAAU,CAC/B,OAAmB,EACnB,GAAW,EACX,IAAuB,EACvB,OAA0B;IAE1B,MAAM,SAAS,GAAG,MAAM,mBAAmB,CAAC,OAAO,CAAC,CAAC;IACrD,MAAM,GAAG,GAA2B,EAAE,CAAC;IACvC,MAAM,QAAQ,GAAa,EAAE,CAAC;IAC9B,KAAK,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,GAAG,IAAI,EAAE,CAAC,EAAE,CAAC;QAC9D,IAAI,KAAK,KAAK,SAAS;YAAE,QAAQ,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;;YACvC,GAAG,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC;IACvB,CAAC;IACD,MAAM,MAAM,GAAG,MAAM,SAAS,CAAC,KAAK,CAAC;QACpC,OAAO,EAAE,GAAG;QACZ,IAAI,EAAE,CAAC,GAAG,IAAI,CAAC;QACf,GAAG,EAAE,OAAO,CAAC,GAAG;QAChB,GAAG;QACH,QAAQ;QACR,OAAO,EAAE,OAAO,CAAC,OAAO;QACxB,aAAa,EAAE,OAAO,CAAC,aAAa;QACpC,MAAM,EAAE,SAAS;QACjB,MAAM,EAAE,SAAS;KACjB,CAAC,CAAC;IACH,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,MAAM,CAAC;IACrC,OAAO,IAAI,IAAI,CAAC,CAAC,CAAC;AACnB,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Whether a path exists as a regular file (`Bun.file(p).exists()`
|
|
3
|
+
* replacement), through the runtime's unbound `filesystem/adapter`: these
|
|
4
|
+
* are host-home paths, not workspace paths. Matches Bun's semantics:
|
|
5
|
+
* false for directories and for missing paths. Only confirmed absence
|
|
6
|
+
* answers false; every other failure propagates whole.
|
|
7
|
+
*/
|
|
8
|
+
import { type RuntimeRef } from '@vibesdotdev/kernel';
|
|
9
|
+
export declare function fileExists(runtime: RuntimeRef, path: string): Promise<boolean>;
|
|
10
|
+
//# sourceMappingURL=fs.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fs.d.ts","sourceRoot":"","sources":["../../src/utils/fs.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAA6C,KAAK,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAGjG,wBAAsB,UAAU,CAAC,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAgBpF"}
|
package/dist/utils/fs.js
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Whether a path exists as a regular file (`Bun.file(p).exists()`
|
|
3
|
+
* replacement), through the runtime's unbound `filesystem/adapter`: these
|
|
4
|
+
* are host-home paths, not workspace paths. Matches Bun's semantics:
|
|
5
|
+
* false for directories and for missing paths. Only confirmed absence
|
|
6
|
+
* answers false; every other failure propagates whole.
|
|
7
|
+
*/
|
|
8
|
+
import { CapabilityError, settle, valueFreeFailure } from '@vibesdotdev/kernel';
|
|
9
|
+
import { resolveFileSystemAdapter } from '@vibesdotdev/filesystem';
|
|
10
|
+
export async function fileExists(runtime, path) {
|
|
11
|
+
if (!runtime.hasKind('filesystem/adapter')) {
|
|
12
|
+
throw new CapabilityError("fileExists has no filesystem backend: no 'filesystem/adapter' is registered", 'UNAVAILABLE', { reason: 'file-exists-no-filesystem' });
|
|
13
|
+
}
|
|
14
|
+
const fs = await resolveFileSystemAdapter(runtime, { binding: false });
|
|
15
|
+
// Settle the real stat: only confirmed absence answers false, even if the
|
|
16
|
+
// path vanishes mid-read; every other failure propagates whole.
|
|
17
|
+
const stated = await settle(() => fs.stat(path));
|
|
18
|
+
if (stated.ok)
|
|
19
|
+
return stated.value.kind === 'file';
|
|
20
|
+
const code = valueFreeFailure(stated.cause).code;
|
|
21
|
+
if (code === 'ENOENT' || code === 'ENOTDIR')
|
|
22
|
+
return false;
|
|
23
|
+
throw stated.cause;
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=fs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fs.js","sourceRoot":"","sources":["../../src/utils/fs.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,eAAe,EAAE,MAAM,EAAE,gBAAgB,EAAmB,MAAM,qBAAqB,CAAC;AACjG,OAAO,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AAEnE,MAAM,CAAC,KAAK,UAAU,UAAU,CAAC,OAAmB,EAAE,IAAY;IACjE,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,oBAAoB,CAAC,EAAE,CAAC;QAC5C,MAAM,IAAI,eAAe,CACxB,6EAA6E,EAC7E,aAAa,EACb,EAAE,MAAM,EAAE,2BAA2B,EAAE,CACvC,CAAC;IACH,CAAC;IACD,MAAM,EAAE,GAAG,MAAM,wBAAwB,CAAC,OAAO,EAAE,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC,CAAC;IACvE,0EAA0E;IAC1E,gEAAgE;IAChE,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC;IACjD,IAAI,MAAM,CAAC,EAAE;QAAE,OAAO,MAAM,CAAC,KAAK,CAAC,IAAI,KAAK,MAAM,CAAC;IACnD,MAAM,IAAI,GAAG,gBAAgB,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC;IACjD,IAAI,IAAI,KAAK,QAAQ,IAAI,IAAI,KAAK,SAAS;QAAE,OAAO,KAAK,CAAC;IAC1D,MAAM,MAAM,CAAC,KAAK,CAAC;AACpB,CAAC"}
|