@ttctl/cli 0.0.0 → 0.1.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/README.md +44 -9
- package/dist/commands/applications/index.d.ts +21 -0
- package/dist/commands/applications/index.d.ts.map +1 -0
- package/dist/commands/applications/index.js +87 -0
- package/dist/commands/applications/index.js.map +1 -0
- package/dist/commands/applications/list.d.ts +55 -0
- package/dist/commands/applications/list.d.ts.map +1 -0
- package/dist/commands/applications/list.js +106 -0
- package/dist/commands/applications/list.js.map +1 -0
- package/dist/commands/applications/shared.d.ts +14 -0
- package/dist/commands/applications/shared.d.ts.map +1 -0
- package/dist/commands/applications/shared.js +19 -0
- package/dist/commands/applications/shared.js.map +1 -0
- package/dist/commands/applications/show.d.ts +51 -0
- package/dist/commands/applications/show.d.ts.map +1 -0
- package/dist/commands/applications/show.js +154 -0
- package/dist/commands/applications/show.js.map +1 -0
- package/dist/commands/applications/stats.d.ts +42 -0
- package/dist/commands/applications/stats.d.ts.map +1 -0
- package/dist/commands/applications/stats.js +69 -0
- package/dist/commands/applications/stats.js.map +1 -0
- package/dist/commands/auth/index.d.ts +17 -0
- package/dist/commands/auth/index.d.ts.map +1 -0
- package/dist/commands/auth/index.js +69 -0
- package/dist/commands/auth/index.js.map +1 -0
- package/dist/commands/auth/init.d.ts +98 -0
- package/dist/commands/auth/init.d.ts.map +1 -0
- package/dist/commands/auth/init.js +387 -0
- package/dist/commands/auth/init.js.map +1 -0
- package/dist/commands/auth/signin.d.ts +81 -0
- package/dist/commands/auth/signin.d.ts.map +1 -0
- package/dist/commands/auth/signin.js +145 -0
- package/dist/commands/auth/signin.js.map +1 -0
- package/dist/commands/auth/signout.d.ts +133 -0
- package/dist/commands/auth/signout.d.ts.map +1 -0
- package/dist/commands/auth/signout.js +172 -0
- package/dist/commands/auth/signout.js.map +1 -0
- package/dist/commands/auth/status.d.ts +62 -0
- package/dist/commands/auth/status.d.ts.map +1 -0
- package/dist/commands/auth/status.js +98 -0
- package/dist/commands/auth/status.js.map +1 -0
- package/dist/commands/availability/allocated-hours.d.ts +27 -0
- package/dist/commands/availability/allocated-hours.d.ts.map +1 -0
- package/dist/commands/availability/allocated-hours.js +61 -0
- package/dist/commands/availability/allocated-hours.js.map +1 -0
- package/dist/commands/availability/index.d.ts +30 -0
- package/dist/commands/availability/index.d.ts.map +1 -0
- package/dist/commands/availability/index.js +124 -0
- package/dist/commands/availability/index.js.map +1 -0
- package/dist/commands/availability/shared.d.ts +11 -0
- package/dist/commands/availability/shared.d.ts.map +1 -0
- package/dist/commands/availability/shared.js +30 -0
- package/dist/commands/availability/shared.js.map +1 -0
- package/dist/commands/availability/show.d.ts +32 -0
- package/dist/commands/availability/show.d.ts.map +1 -0
- package/dist/commands/availability/show.js +86 -0
- package/dist/commands/availability/show.js.map +1 -0
- package/dist/commands/availability/working-hours.d.ts +53 -0
- package/dist/commands/availability/working-hours.d.ts.map +1 -0
- package/dist/commands/availability/working-hours.js +151 -0
- package/dist/commands/availability/working-hours.js.map +1 -0
- package/dist/commands/contracts/index.d.ts +69 -0
- package/dist/commands/contracts/index.d.ts.map +1 -0
- package/dist/commands/contracts/index.js +198 -0
- package/dist/commands/contracts/index.js.map +1 -0
- package/dist/commands/engagements/breaks.d.ts +81 -0
- package/dist/commands/engagements/breaks.d.ts.map +1 -0
- package/dist/commands/engagements/breaks.js +229 -0
- package/dist/commands/engagements/breaks.js.map +1 -0
- package/dist/commands/engagements/index.d.ts +29 -0
- package/dist/commands/engagements/index.d.ts.map +1 -0
- package/dist/commands/engagements/index.js +172 -0
- package/dist/commands/engagements/index.js.map +1 -0
- package/dist/commands/engagements/list.d.ts +49 -0
- package/dist/commands/engagements/list.d.ts.map +1 -0
- package/dist/commands/engagements/list.js +95 -0
- package/dist/commands/engagements/list.js.map +1 -0
- package/dist/commands/engagements/shared.d.ts +10 -0
- package/dist/commands/engagements/shared.d.ts.map +1 -0
- package/dist/commands/engagements/shared.js +31 -0
- package/dist/commands/engagements/shared.js.map +1 -0
- package/dist/commands/engagements/show.d.ts +19 -0
- package/dist/commands/engagements/show.d.ts.map +1 -0
- package/dist/commands/engagements/show.js +150 -0
- package/dist/commands/engagements/show.js.map +1 -0
- package/dist/commands/engagements/stats.d.ts +24 -0
- package/dist/commands/engagements/stats.d.ts.map +1 -0
- package/dist/commands/engagements/stats.js +51 -0
- package/dist/commands/engagements/stats.js.map +1 -0
- package/dist/commands/jobs/index.d.ts +49 -0
- package/dist/commands/jobs/index.d.ts.map +1 -0
- package/dist/commands/jobs/index.js +304 -0
- package/dist/commands/jobs/index.js.map +1 -0
- package/dist/commands/jobs/interest.d.ts +65 -0
- package/dist/commands/jobs/interest.d.ts.map +1 -0
- package/dist/commands/jobs/interest.js +172 -0
- package/dist/commands/jobs/interest.js.map +1 -0
- package/dist/commands/jobs/list.d.ts +81 -0
- package/dist/commands/jobs/list.d.ts.map +1 -0
- package/dist/commands/jobs/list.js +157 -0
- package/dist/commands/jobs/list.js.map +1 -0
- package/dist/commands/jobs/search.d.ts +71 -0
- package/dist/commands/jobs/search.d.ts.map +1 -0
- package/dist/commands/jobs/search.js +163 -0
- package/dist/commands/jobs/search.js.map +1 -0
- package/dist/commands/jobs/shared.d.ts +79 -0
- package/dist/commands/jobs/shared.d.ts.map +1 -0
- package/dist/commands/jobs/shared.js +133 -0
- package/dist/commands/jobs/shared.js.map +1 -0
- package/dist/commands/jobs/show.d.ts +20 -0
- package/dist/commands/jobs/show.d.ts.map +1 -0
- package/dist/commands/jobs/show.js +135 -0
- package/dist/commands/jobs/show.js.map +1 -0
- package/dist/commands/payments/index.d.ts +34 -0
- package/dist/commands/payments/index.d.ts.map +1 -0
- package/dist/commands/payments/index.js +160 -0
- package/dist/commands/payments/index.js.map +1 -0
- package/dist/commands/payments/methods.d.ts +17 -0
- package/dist/commands/payments/methods.d.ts.map +1 -0
- package/dist/commands/payments/methods.js +79 -0
- package/dist/commands/payments/methods.js.map +1 -0
- package/dist/commands/payments/payouts.d.ts +44 -0
- package/dist/commands/payments/payouts.d.ts.map +1 -0
- package/dist/commands/payments/payouts.js +147 -0
- package/dist/commands/payments/payouts.js.map +1 -0
- package/dist/commands/payments/rate.d.ts +48 -0
- package/dist/commands/payments/rate.d.ts.map +1 -0
- package/dist/commands/payments/rate.js +229 -0
- package/dist/commands/payments/rate.js.map +1 -0
- package/dist/commands/payments/shared.d.ts +10 -0
- package/dist/commands/payments/shared.d.ts.map +1 -0
- package/dist/commands/payments/shared.js +27 -0
- package/dist/commands/payments/shared.js.map +1 -0
- package/dist/commands/profile/basic/index.d.ts +18 -0
- package/dist/commands/profile/basic/index.d.ts.map +1 -0
- package/dist/commands/profile/basic/index.js +79 -0
- package/dist/commands/profile/basic/index.js.map +1 -0
- package/dist/commands/profile/basic/photo-show.d.ts +28 -0
- package/dist/commands/profile/basic/photo-show.d.ts.map +1 -0
- package/dist/commands/profile/basic/photo-show.js +112 -0
- package/dist/commands/profile/basic/photo-show.js.map +1 -0
- package/dist/commands/profile/basic/photo-upload.d.ts +10 -0
- package/dist/commands/profile/basic/photo-upload.d.ts.map +1 -0
- package/dist/commands/profile/basic/photo-upload.js +61 -0
- package/dist/commands/profile/basic/photo-upload.js.map +1 -0
- package/dist/commands/profile/basic/set.d.ts +54 -0
- package/dist/commands/profile/basic/set.d.ts.map +1 -0
- package/dist/commands/profile/basic/set.js +174 -0
- package/dist/commands/profile/basic/set.js.map +1 -0
- package/dist/commands/profile/basic/show.d.ts +95 -0
- package/dist/commands/profile/basic/show.d.ts.map +1 -0
- package/dist/commands/profile/basic/show.js +310 -0
- package/dist/commands/profile/basic/show.js.map +1 -0
- package/dist/commands/profile/certifications/index.d.ts +40 -0
- package/dist/commands/profile/certifications/index.d.ts.map +1 -0
- package/dist/commands/profile/certifications/index.js +350 -0
- package/dist/commands/profile/certifications/index.js.map +1 -0
- package/dist/commands/profile/education/index.d.ts +37 -0
- package/dist/commands/profile/education/index.d.ts.map +1 -0
- package/dist/commands/profile/education/index.js +331 -0
- package/dist/commands/profile/education/index.js.map +1 -0
- package/dist/commands/profile/employment/index.d.ts +49 -0
- package/dist/commands/profile/employment/index.d.ts.map +1 -0
- package/dist/commands/profile/employment/index.js +425 -0
- package/dist/commands/profile/employment/index.js.map +1 -0
- package/dist/commands/profile/external/_shared.d.ts +35 -0
- package/dist/commands/profile/external/_shared.d.ts.map +1 -0
- package/dist/commands/profile/external/_shared.js +59 -0
- package/dist/commands/profile/external/_shared.js.map +1 -0
- package/dist/commands/profile/external/advanced-wizard-show.d.ts +15 -0
- package/dist/commands/profile/external/advanced-wizard-show.d.ts.map +1 -0
- package/dist/commands/profile/external/advanced-wizard-show.js +82 -0
- package/dist/commands/profile/external/advanced-wizard-show.js.map +1 -0
- package/dist/commands/profile/external/custom-requirements-set.d.ts +32 -0
- package/dist/commands/profile/external/custom-requirements-set.d.ts.map +1 -0
- package/dist/commands/profile/external/custom-requirements-set.js +116 -0
- package/dist/commands/profile/external/custom-requirements-set.js.map +1 -0
- package/dist/commands/profile/external/custom-requirements-show.d.ts +16 -0
- package/dist/commands/profile/external/custom-requirements-show.d.ts.map +1 -0
- package/dist/commands/profile/external/custom-requirements-show.js +84 -0
- package/dist/commands/profile/external/custom-requirements-show.js.map +1 -0
- package/dist/commands/profile/external/index.d.ts +21 -0
- package/dist/commands/profile/external/index.d.ts.map +1 -0
- package/dist/commands/profile/external/index.js +113 -0
- package/dist/commands/profile/external/index.js.map +1 -0
- package/dist/commands/profile/external/readiness.d.ts +15 -0
- package/dist/commands/profile/external/readiness.d.ts.map +1 -0
- package/dist/commands/profile/external/readiness.js +104 -0
- package/dist/commands/profile/external/readiness.js.map +1 -0
- package/dist/commands/profile/external/recommendations.d.ts +17 -0
- package/dist/commands/profile/external/recommendations.d.ts.map +1 -0
- package/dist/commands/profile/external/recommendations.js +97 -0
- package/dist/commands/profile/external/recommendations.js.map +1 -0
- package/dist/commands/profile/external/show.d.ts +22 -0
- package/dist/commands/profile/external/show.d.ts.map +1 -0
- package/dist/commands/profile/external/show.js +83 -0
- package/dist/commands/profile/external/show.js.map +1 -0
- package/dist/commands/profile/external/update.d.ts +37 -0
- package/dist/commands/profile/external/update.d.ts.map +1 -0
- package/dist/commands/profile/external/update.js +125 -0
- package/dist/commands/profile/external/update.js.map +1 -0
- package/dist/commands/profile/index.d.ts +16 -0
- package/dist/commands/profile/index.d.ts.map +1 -0
- package/dist/commands/profile/index.js +81 -0
- package/dist/commands/profile/index.js.map +1 -0
- package/dist/commands/profile/industries/index.d.ts +43 -0
- package/dist/commands/profile/industries/index.d.ts.map +1 -0
- package/dist/commands/profile/industries/index.js +258 -0
- package/dist/commands/profile/industries/index.js.map +1 -0
- package/dist/commands/profile/portfolio/add.d.ts +43 -0
- package/dist/commands/profile/portfolio/add.d.ts.map +1 -0
- package/dist/commands/profile/portfolio/add.js +181 -0
- package/dist/commands/profile/portfolio/add.js.map +1 -0
- package/dist/commands/profile/portfolio/highlight.d.ts +11 -0
- package/dist/commands/profile/portfolio/highlight.d.ts.map +1 -0
- package/dist/commands/profile/portfolio/highlight.js +31 -0
- package/dist/commands/profile/portfolio/highlight.js.map +1 -0
- package/dist/commands/profile/portfolio/index.d.ts +16 -0
- package/dist/commands/profile/portfolio/index.d.ts.map +1 -0
- package/dist/commands/profile/portfolio/index.js +121 -0
- package/dist/commands/profile/portfolio/index.js.map +1 -0
- package/dist/commands/profile/portfolio/list.d.ts +83 -0
- package/dist/commands/profile/portfolio/list.d.ts.map +1 -0
- package/dist/commands/profile/portfolio/list.js +189 -0
- package/dist/commands/profile/portfolio/list.js.map +1 -0
- package/dist/commands/profile/portfolio/remove.d.ts +9 -0
- package/dist/commands/profile/portfolio/remove.d.ts.map +1 -0
- package/dist/commands/profile/portfolio/remove.js +24 -0
- package/dist/commands/profile/portfolio/remove.js.map +1 -0
- package/dist/commands/profile/portfolio/reorder.d.ts +17 -0
- package/dist/commands/profile/portfolio/reorder.d.ts.map +1 -0
- package/dist/commands/profile/portfolio/reorder.js +135 -0
- package/dist/commands/profile/portfolio/reorder.js.map +1 -0
- package/dist/commands/profile/portfolio/shared.d.ts +8 -0
- package/dist/commands/profile/portfolio/shared.d.ts.map +1 -0
- package/dist/commands/profile/portfolio/shared.js +10 -0
- package/dist/commands/profile/portfolio/shared.js.map +1 -0
- package/dist/commands/profile/portfolio/update.d.ts +18 -0
- package/dist/commands/profile/portfolio/update.d.ts.map +1 -0
- package/dist/commands/profile/portfolio/update.js +77 -0
- package/dist/commands/profile/portfolio/update.js.map +1 -0
- package/dist/commands/profile/portfolio/upload.d.ts +8 -0
- package/dist/commands/profile/portfolio/upload.d.ts.map +1 -0
- package/dist/commands/profile/portfolio/upload.js +131 -0
- package/dist/commands/profile/portfolio/upload.js.map +1 -0
- package/dist/commands/profile/resume/cancel-upload.d.ts +9 -0
- package/dist/commands/profile/resume/cancel-upload.d.ts.map +1 -0
- package/dist/commands/profile/resume/cancel-upload.js +30 -0
- package/dist/commands/profile/resume/cancel-upload.js.map +1 -0
- package/dist/commands/profile/resume/index.d.ts +15 -0
- package/dist/commands/profile/resume/index.d.ts.map +1 -0
- package/dist/commands/profile/resume/index.js +42 -0
- package/dist/commands/profile/resume/index.js.map +1 -0
- package/dist/commands/profile/resume/upload.d.ts +16 -0
- package/dist/commands/profile/resume/upload.d.ts.map +1 -0
- package/dist/commands/profile/resume/upload.js +65 -0
- package/dist/commands/profile/resume/upload.js.map +1 -0
- package/dist/commands/profile/reviews/_shared.d.ts +9 -0
- package/dist/commands/profile/reviews/_shared.d.ts.map +1 -0
- package/dist/commands/profile/reviews/_shared.js +15 -0
- package/dist/commands/profile/reviews/_shared.js.map +1 -0
- package/dist/commands/profile/reviews/approve-item.d.ts +30 -0
- package/dist/commands/profile/reviews/approve-item.d.ts.map +1 -0
- package/dist/commands/profile/reviews/approve-item.js +82 -0
- package/dist/commands/profile/reviews/approve-item.js.map +1 -0
- package/dist/commands/profile/reviews/approve-section.d.ts +15 -0
- package/dist/commands/profile/reviews/approve-section.d.ts.map +1 -0
- package/dist/commands/profile/reviews/approve-section.js +67 -0
- package/dist/commands/profile/reviews/approve-section.js.map +1 -0
- package/dist/commands/profile/reviews/index.d.ts +19 -0
- package/dist/commands/profile/reviews/index.d.ts.map +1 -0
- package/dist/commands/profile/reviews/index.js +71 -0
- package/dist/commands/profile/reviews/index.js.map +1 -0
- package/dist/commands/profile/reviews/list.d.ts +17 -0
- package/dist/commands/profile/reviews/list.d.ts.map +1 -0
- package/dist/commands/profile/reviews/list.js +96 -0
- package/dist/commands/profile/reviews/list.js.map +1 -0
- package/dist/commands/profile/reviews/submit-for-review.d.ts +16 -0
- package/dist/commands/profile/reviews/submit-for-review.d.ts.map +1 -0
- package/dist/commands/profile/reviews/submit-for-review.js +65 -0
- package/dist/commands/profile/reviews/submit-for-review.js.map +1 -0
- package/dist/commands/profile/shared.d.ts +46 -0
- package/dist/commands/profile/shared.d.ts.map +1 -0
- package/dist/commands/profile/shared.js +111 -0
- package/dist/commands/profile/shared.js.map +1 -0
- package/dist/commands/profile/skills/index.d.ts +29 -0
- package/dist/commands/profile/skills/index.d.ts.map +1 -0
- package/dist/commands/profile/skills/index.js +475 -0
- package/dist/commands/profile/skills/index.js.map +1 -0
- package/dist/commands/profile/visas/add.d.ts +19 -0
- package/dist/commands/profile/visas/add.d.ts.map +1 -0
- package/dist/commands/profile/visas/add.js +37 -0
- package/dist/commands/profile/visas/add.js.map +1 -0
- package/dist/commands/profile/visas/index.d.ts +13 -0
- package/dist/commands/profile/visas/index.d.ts.map +1 -0
- package/dist/commands/profile/visas/index.js +69 -0
- package/dist/commands/profile/visas/index.js.map +1 -0
- package/dist/commands/profile/visas/list.d.ts +40 -0
- package/dist/commands/profile/visas/list.d.ts.map +1 -0
- package/dist/commands/profile/visas/list.js +115 -0
- package/dist/commands/profile/visas/list.js.map +1 -0
- package/dist/commands/profile/visas/remove.d.ts +8 -0
- package/dist/commands/profile/visas/remove.d.ts.map +1 -0
- package/dist/commands/profile/visas/remove.js +23 -0
- package/dist/commands/profile/visas/remove.js.map +1 -0
- package/dist/commands/profile/visas/shared.d.ts +11 -0
- package/dist/commands/profile/visas/shared.d.ts.map +1 -0
- package/dist/commands/profile/visas/shared.js +16 -0
- package/dist/commands/profile/visas/shared.js.map +1 -0
- package/dist/commands/profile/visas/update.d.ts +13 -0
- package/dist/commands/profile/visas/update.d.ts.map +1 -0
- package/dist/commands/profile/visas/update.js +44 -0
- package/dist/commands/profile/visas/update.js.map +1 -0
- package/dist/commands/timesheet/index.d.ts +24 -0
- package/dist/commands/timesheet/index.d.ts.map +1 -0
- package/dist/commands/timesheet/index.js +98 -0
- package/dist/commands/timesheet/index.js.map +1 -0
- package/dist/commands/timesheet/list.d.ts +40 -0
- package/dist/commands/timesheet/list.d.ts.map +1 -0
- package/dist/commands/timesheet/list.js +79 -0
- package/dist/commands/timesheet/list.js.map +1 -0
- package/dist/commands/timesheet/shared.d.ts +10 -0
- package/dist/commands/timesheet/shared.d.ts.map +1 -0
- package/dist/commands/timesheet/shared.js +35 -0
- package/dist/commands/timesheet/shared.js.map +1 -0
- package/dist/commands/timesheet/show.d.ts +19 -0
- package/dist/commands/timesheet/show.d.ts.map +1 -0
- package/dist/commands/timesheet/show.js +109 -0
- package/dist/commands/timesheet/show.js.map +1 -0
- package/dist/commands/timesheet/submit.d.ts +50 -0
- package/dist/commands/timesheet/submit.d.ts.map +1 -0
- package/dist/commands/timesheet/submit.js +151 -0
- package/dist/commands/timesheet/submit.js.map +1 -0
- package/dist/crash-handlers.d.ts +67 -0
- package/dist/crash-handlers.d.ts.map +1 -0
- package/dist/crash-handlers.js +78 -0
- package/dist/crash-handlers.js.map +1 -0
- package/dist/errors.d.ts +45 -0
- package/dist/errors.d.ts.map +1 -0
- package/dist/errors.js +57 -0
- package/dist/errors.js.map +1 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +15 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/config-context.d.ts +41 -0
- package/dist/lib/config-context.d.ts.map +1 -0
- package/dist/lib/config-context.js +74 -0
- package/dist/lib/config-context.js.map +1 -0
- package/dist/lib/dry-run.d.ts +70 -0
- package/dist/lib/dry-run.d.ts.map +1 -0
- package/dist/lib/dry-run.js +114 -0
- package/dist/lib/dry-run.js.map +1 -0
- package/dist/lib/empty-state-cta.d.ts +63 -0
- package/dist/lib/empty-state-cta.d.ts.map +1 -0
- package/dist/lib/empty-state-cta.js +88 -0
- package/dist/lib/empty-state-cta.js.map +1 -0
- package/dist/lib/envelopes.d.ts +540 -0
- package/dist/lib/envelopes.d.ts.map +1 -0
- package/dist/lib/envelopes.js +598 -0
- package/dist/lib/envelopes.js.map +1 -0
- package/dist/lib/error-routing.d.ts +49 -0
- package/dist/lib/error-routing.d.ts.map +1 -0
- package/dist/lib/error-routing.js +72 -0
- package/dist/lib/error-routing.js.map +1 -0
- package/dist/lib/format-helpers.d.ts +65 -0
- package/dist/lib/format-helpers.d.ts.map +1 -0
- package/dist/lib/format-helpers.js +79 -0
- package/dist/lib/format-helpers.js.map +1 -0
- package/dist/lib/format-overrides.d.ts +81 -0
- package/dist/lib/format-overrides.d.ts.map +1 -0
- package/dist/lib/format-overrides.js +55 -0
- package/dist/lib/format-overrides.js.map +1 -0
- package/dist/lib/freetext.d.ts +83 -0
- package/dist/lib/freetext.d.ts.map +1 -0
- package/dist/lib/freetext.js +182 -0
- package/dist/lib/freetext.js.map +1 -0
- package/dist/lib/kill-switch-hook.d.ts +49 -0
- package/dist/lib/kill-switch-hook.d.ts.map +1 -0
- package/dist/lib/kill-switch-hook.js +34 -0
- package/dist/lib/kill-switch-hook.js.map +1 -0
- package/dist/lib/output.d.ts +173 -0
- package/dist/lib/output.d.ts.map +1 -0
- package/dist/lib/output.js +177 -0
- package/dist/lib/output.js.map +1 -0
- package/dist/lib/pagination.d.ts +49 -0
- package/dist/lib/pagination.d.ts.map +1 -0
- package/dist/lib/pagination.js +36 -0
- package/dist/lib/pagination.js.map +1 -0
- package/dist/program.d.ts +80 -0
- package/dist/program.d.ts.map +1 -0
- package/dist/program.js +273 -0
- package/dist/program.js.map +1 -0
- package/package.json +35 -13
- package/index.js +0 -7
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search.js","sourceRoot":"","sources":["../../../src/commands/jobs/search.ts"],"names":[],"mappings":"AAAA,yCAAyC;AACzC,oCAAoC;AAEpC,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAEnC,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACpD,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AACnH,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEjD,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;AAEnE;;;;;;;;;;;;;GAaG;AAEH;;;;GAIG;AACH,MAAM,CAAC,KAAK,UAAU,iBAAiB,CAAC,MAAoB;IAC1D,MAAM,KAAK,GAAG,MAAM,mBAAmB,CAAC,kBAAkB,EAAE,MAAM,CAAC,CAAC;IAEpE,IAAI,KAAmC,CAAC;IACxC,IAAI,CAAC;QACH,KAAK,GAAG,MAAM,IAAI,CAAC,sBAAsB,CAAC,KAAK,CAAC,CAAC;IACnD,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,eAAe,CAAC,kBAAkB,EAAE,GAAG,EAAE,MAAM,CAAC,CAAC;IACnD,CAAC;IAED,MAAM,KAAK,GAA4B,KAAK,CAAC,MAAM,IAAI,KAAK,CAAC,OAAO,KAAK,IAAI,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IAEhH,UAAU,CAAC,gBAAgB,CAAC,KAAK,CAAC,EAAE,MAAM,EAAE;QAC1C,MAAM,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,uBAAuB,CA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G,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACzF,IAAI,GAAG,CAAC,SAAS,CAAC,MAAM,GAAG,CAAC;QAAE,KAAK,CAAC,IAAI,CAAC,eAAe,GAAG,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpF,IAAI,GAAG,CAAC,gBAAgB,CAAC,MAAM,GAAG,CAAC;QAAE,KAAK,CAAC,IAAI,CAAC,sBAAsB,GAAG,CAAC,gBAAgB,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACzG,IAAI,GAAG,CAAC,wBAAwB,KAAK,IAAI,EAAE,CAAC;QAC1C,KAAK,CAAC,IAAI,CAAC,+BAA+B,GAAG,CAAC,wBAAwB,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC;IAC3F,CAAC;IACD,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAC1B,CAAC"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { jobs } from "@ttctl/core";
|
|
2
|
+
import type { OutputFormat } from "../../lib/output.js";
|
|
3
|
+
export { loadAuthTokenOrExit } from "../profile/shared.js";
|
|
4
|
+
/**
|
|
5
|
+
* Thin wrapper around the shared CLI error router (#330) closed over
|
|
6
|
+
* `jobs.JobsError`. The router applies the envelope ABI (#128)
|
|
7
|
+
* branching uniformly across sub-domains. No per-code hint adapter —
|
|
8
|
+
* `JobsError` codes do not carry actionable next-step hints today.
|
|
9
|
+
*/
|
|
10
|
+
export declare function handleJobsError(commandLabel: string, err: unknown, format?: OutputFormat): never;
|
|
11
|
+
/**
|
|
12
|
+
* Render an ISO 8601 timestamp as just the date portion (YYYY-MM-DD).
|
|
13
|
+
*/
|
|
14
|
+
export declare function formatDate(iso: string | null): string;
|
|
15
|
+
/**
|
|
16
|
+
* Render a job rate (server-side `maxRate` is the upper-bound on
|
|
17
|
+
* hourly rate, in USD). Returns the empty string when null.
|
|
18
|
+
*/
|
|
19
|
+
export declare function formatRate(rate: number | null): string;
|
|
20
|
+
/**
|
|
21
|
+
* Render the jobs list as a `cli-table3` table sized to the current
|
|
22
|
+
* terminal width. Columns: id, title, client, commitment, rate, flags
|
|
23
|
+
* (saved / not-interested / viewed). Used by `list`, `saved`,
|
|
24
|
+
* `viewed`, `not-interested-list`.
|
|
25
|
+
*/
|
|
26
|
+
export declare function formatJobsTable(items: jobs.JobListItem[], terminalWidth?: number): string;
|
|
27
|
+
/**
|
|
28
|
+
* Render the interest-status flags as a compact one-line tag string.
|
|
29
|
+
* Used in list rows and in interest-mutation success summaries.
|
|
30
|
+
*
|
|
31
|
+
* - `S` — saved
|
|
32
|
+
* - `N` — not-interested
|
|
33
|
+
* - `V` — viewed
|
|
34
|
+
*
|
|
35
|
+
* Empty when no flag is set.
|
|
36
|
+
*/
|
|
37
|
+
export declare function formatFlags(state: {
|
|
38
|
+
saved: boolean | null;
|
|
39
|
+
notInterested: boolean | null;
|
|
40
|
+
viewed: boolean | null;
|
|
41
|
+
}): string;
|
|
42
|
+
/**
|
|
43
|
+
* Render the pretty-format pagination footer "Page X of Y (per_page=Z)"
|
|
44
|
+
* appended below the table for paginated list outputs (#138). The
|
|
45
|
+
* footer is appended ONLY when the server returned `totalCount > 0` —
|
|
46
|
+
* empty pages route through the existing empty-state CTA wrapper
|
|
47
|
+
* BEFORE per-format dispatch, so this helper never fires on
|
|
48
|
+
* `items.length === 0`.
|
|
49
|
+
*
|
|
50
|
+
* `totalPages` is derived as `Math.max(1, Math.ceil(totalCount /
|
|
51
|
+
* perPage))` so a single-page result with `totalCount > 0` renders
|
|
52
|
+
* "Page 1 of 1". When `currentPage > totalPages` (user overshot — the
|
|
53
|
+
* server returned an empty entities array on a non-existent page), the
|
|
54
|
+
* caller's `items.length === 0` triggers empty-state before we reach
|
|
55
|
+
* here; no special handling needed.
|
|
56
|
+
*
|
|
57
|
+
* Pure — directly unit-testable.
|
|
58
|
+
*/
|
|
59
|
+
export declare function formatPageFooter(currentPage: number, perPage: number, totalCount: number): string;
|
|
60
|
+
/**
|
|
61
|
+
* Build the offset-style `pageInfo` block for the list envelope (#138)
|
|
62
|
+
* from the service-layer's {@link jobs.JobListPage}. Wraps the
|
|
63
|
+
* arithmetic for `totalPages` and `hasNextPage` derivation so the
|
|
64
|
+
* action handler and the unit tests share one source of truth.
|
|
65
|
+
*
|
|
66
|
+
* - `currentPage`, `perPage`: passed through verbatim (the service
|
|
67
|
+
* returns the values actually used in the query).
|
|
68
|
+
* - `totalPages`: `Math.max(1, Math.ceil(totalCount / perPage))`.
|
|
69
|
+
* - `hasNextPage`: `currentPage < totalPages`.
|
|
70
|
+
*
|
|
71
|
+
* Pure — directly unit-testable.
|
|
72
|
+
*/
|
|
73
|
+
export declare function buildJobsPageInfo(page: jobs.JobListPage): {
|
|
74
|
+
currentPage: number;
|
|
75
|
+
perPage: number;
|
|
76
|
+
totalPages: number;
|
|
77
|
+
hasNextPage: boolean;
|
|
78
|
+
};
|
|
79
|
+
//# sourceMappingURL=shared.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../../src/commands/jobs/shared.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAGnC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAExD,OAAO,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAE3D;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,YAAY,EAAE,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,GAAE,YAAuB,GAAG,KAAK,CAE1G;AAED;;GAEG;AACH,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM,CAIrD;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM,CAGtD;AAED;;;;;GAKG;AACH,wBAAgB,eAAe,CAC7B,KAAK,EAAE,IAAI,CAAC,WAAW,EAAE,EACzB,aAAa,GAAE,MAAsC,GACpD,MAAM,CA6BR;AAED;;;;;;;;;GASG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE;IACjC,KAAK,EAAE,OAAO,GAAG,IAAI,CAAC;IACtB,aAAa,EAAE,OAAO,GAAG,IAAI,CAAC;IAC9B,MAAM,EAAE,OAAO,GAAG,IAAI,CAAC;CACxB,GAAG,MAAM,CAMT;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,gBAAgB,CAAC,WAAW,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,MAAM,CAGjG;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,GAAG;IACzD,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,EAAE,OAAO,CAAC;CACtB,CAQA"}
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
// SPDX-License-Identifier: AGPL-3.0-only
|
|
2
|
+
// Copyright (C) 2026 Oleksii PELYKH
|
|
3
|
+
import Table from "cli-table3";
|
|
4
|
+
import { jobs } from "@ttctl/core";
|
|
5
|
+
import { handleDomainError } from "../../lib/error-routing.js";
|
|
6
|
+
export { loadAuthTokenOrExit } from "../profile/shared.js";
|
|
7
|
+
/**
|
|
8
|
+
* Thin wrapper around the shared CLI error router (#330) closed over
|
|
9
|
+
* `jobs.JobsError`. The router applies the envelope ABI (#128)
|
|
10
|
+
* branching uniformly across sub-domains. No per-code hint adapter —
|
|
11
|
+
* `JobsError` codes do not carry actionable next-step hints today.
|
|
12
|
+
*/
|
|
13
|
+
export function handleJobsError(commandLabel, err, format = "pretty") {
|
|
14
|
+
handleDomainError(commandLabel, err, jobs.JobsError, format);
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Render an ISO 8601 timestamp as just the date portion (YYYY-MM-DD).
|
|
18
|
+
*/
|
|
19
|
+
export function formatDate(iso) {
|
|
20
|
+
if (iso === null)
|
|
21
|
+
return "";
|
|
22
|
+
const m = /^(\d{4}-\d{2}-\d{2})/.exec(iso);
|
|
23
|
+
return m?.[1] ?? iso;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Render a job rate (server-side `maxRate` is the upper-bound on
|
|
27
|
+
* hourly rate, in USD). Returns the empty string when null.
|
|
28
|
+
*/
|
|
29
|
+
export function formatRate(rate) {
|
|
30
|
+
if (rate === null)
|
|
31
|
+
return "";
|
|
32
|
+
return `$${rate.toString()}/h`;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Render the jobs list as a `cli-table3` table sized to the current
|
|
36
|
+
* terminal width. Columns: id, title, client, commitment, rate, flags
|
|
37
|
+
* (saved / not-interested / viewed). Used by `list`, `saved`,
|
|
38
|
+
* `viewed`, `not-interested-list`.
|
|
39
|
+
*/
|
|
40
|
+
export function formatJobsTable(items, terminalWidth = process.stdout.columns || 100) {
|
|
41
|
+
if (items.length === 0) {
|
|
42
|
+
const empty = new Table({ head: ["id", "title", "client", "commitment", "rate", "flags"] });
|
|
43
|
+
return empty.toString();
|
|
44
|
+
}
|
|
45
|
+
const idWidth = 22;
|
|
46
|
+
const commitmentWidth = 14;
|
|
47
|
+
const rateWidth = 10;
|
|
48
|
+
const flagsWidth = 8;
|
|
49
|
+
const clientWidth = 24;
|
|
50
|
+
// 6 columns x 2 padding + 7 borders ≈ 19
|
|
51
|
+
const remaining = Math.max(20, terminalWidth - idWidth - clientWidth - commitmentWidth - rateWidth - flagsWidth - 19);
|
|
52
|
+
const titleWidth = Math.max(20, remaining);
|
|
53
|
+
const table = new Table({
|
|
54
|
+
head: ["id", "title", "client", "commitment", "rate", "flags"],
|
|
55
|
+
colWidths: [idWidth, titleWidth, clientWidth, commitmentWidth, rateWidth, flagsWidth],
|
|
56
|
+
wordWrap: true,
|
|
57
|
+
});
|
|
58
|
+
for (const it of items) {
|
|
59
|
+
table.push([
|
|
60
|
+
it.id,
|
|
61
|
+
it.title ?? "(untitled)",
|
|
62
|
+
it.client?.fullName ?? "",
|
|
63
|
+
it.commitment?.slug ?? "",
|
|
64
|
+
formatRate(it.maxRate),
|
|
65
|
+
formatFlags(it),
|
|
66
|
+
]);
|
|
67
|
+
}
|
|
68
|
+
return table.toString();
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Render the interest-status flags as a compact one-line tag string.
|
|
72
|
+
* Used in list rows and in interest-mutation success summaries.
|
|
73
|
+
*
|
|
74
|
+
* - `S` — saved
|
|
75
|
+
* - `N` — not-interested
|
|
76
|
+
* - `V` — viewed
|
|
77
|
+
*
|
|
78
|
+
* Empty when no flag is set.
|
|
79
|
+
*/
|
|
80
|
+
export function formatFlags(state) {
|
|
81
|
+
const parts = [];
|
|
82
|
+
if (state.saved === true)
|
|
83
|
+
parts.push("S");
|
|
84
|
+
if (state.notInterested === true)
|
|
85
|
+
parts.push("N");
|
|
86
|
+
if (state.viewed === true)
|
|
87
|
+
parts.push("V");
|
|
88
|
+
return parts.join("");
|
|
89
|
+
}
|
|
90
|
+
/**
|
|
91
|
+
* Render the pretty-format pagination footer "Page X of Y (per_page=Z)"
|
|
92
|
+
* appended below the table for paginated list outputs (#138). The
|
|
93
|
+
* footer is appended ONLY when the server returned `totalCount > 0` —
|
|
94
|
+
* empty pages route through the existing empty-state CTA wrapper
|
|
95
|
+
* BEFORE per-format dispatch, so this helper never fires on
|
|
96
|
+
* `items.length === 0`.
|
|
97
|
+
*
|
|
98
|
+
* `totalPages` is derived as `Math.max(1, Math.ceil(totalCount /
|
|
99
|
+
* perPage))` so a single-page result with `totalCount > 0` renders
|
|
100
|
+
* "Page 1 of 1". When `currentPage > totalPages` (user overshot — the
|
|
101
|
+
* server returned an empty entities array on a non-existent page), the
|
|
102
|
+
* caller's `items.length === 0` triggers empty-state before we reach
|
|
103
|
+
* here; no special handling needed.
|
|
104
|
+
*
|
|
105
|
+
* Pure — directly unit-testable.
|
|
106
|
+
*/
|
|
107
|
+
export function formatPageFooter(currentPage, perPage, totalCount) {
|
|
108
|
+
const totalPages = Math.max(1, Math.ceil(totalCount / perPage));
|
|
109
|
+
return `Page ${currentPage.toString()} of ${totalPages.toString()} (per_page=${perPage.toString()})`;
|
|
110
|
+
}
|
|
111
|
+
/**
|
|
112
|
+
* Build the offset-style `pageInfo` block for the list envelope (#138)
|
|
113
|
+
* from the service-layer's {@link jobs.JobListPage}. Wraps the
|
|
114
|
+
* arithmetic for `totalPages` and `hasNextPage` derivation so the
|
|
115
|
+
* action handler and the unit tests share one source of truth.
|
|
116
|
+
*
|
|
117
|
+
* - `currentPage`, `perPage`: passed through verbatim (the service
|
|
118
|
+
* returns the values actually used in the query).
|
|
119
|
+
* - `totalPages`: `Math.max(1, Math.ceil(totalCount / perPage))`.
|
|
120
|
+
* - `hasNextPage`: `currentPage < totalPages`.
|
|
121
|
+
*
|
|
122
|
+
* Pure — directly unit-testable.
|
|
123
|
+
*/
|
|
124
|
+
export function buildJobsPageInfo(page) {
|
|
125
|
+
const totalPages = Math.max(1, Math.ceil(page.totalCount / page.perPage));
|
|
126
|
+
return {
|
|
127
|
+
currentPage: page.page,
|
|
128
|
+
perPage: page.perPage,
|
|
129
|
+
totalPages,
|
|
130
|
+
hasNextPage: page.page < totalPages,
|
|
131
|
+
};
|
|
132
|
+
}
|
|
133
|
+
//# sourceMappingURL=shared.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shared.js","sourceRoot":"","sources":["../../../src/commands/jobs/shared.ts"],"names":[],"mappings":"AAAA,yCAAyC;AACzC,oCAAoC;AAEpC,OAAO,KAAK,MAAM,YAAY,CAAC;AAC/B,OAAO,EAAE,IAAI,EAAE,MAAM,a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CAAC;IAClD,IAAI,KAAK,CAAC,MAAM,KAAK,IAAI;QAAE,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAC3C,OAAO,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACxB,CAAC;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,UAAU,gBAAgB,CAAC,WAAmB,EAAE,OAAe,EAAE,UAAkB;IACvF,MAAM,UAAU,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,CAAC,CAAC;IAChE,OAAO,QAAQ,WAAW,CAAC,QAAQ,EAAE,OAAO,UAAU,CAAC,QAAQ,EAAE,cAAc,OAAO,CAAC,QAAQ,EAAE,GAAG,CAAC;AACvG,CAAC;AAED;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,iBAAiB,CAAC,IAAsB;IAMtD,MAAM,UAAU,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;IAC1E,OAAO;QACL,WAAW,EAAE,IAAI,CAAC,IAAI;QACtB,OAAO,EAAE,IAAI,CAAC,OAAO;QACrB,UAAU;QACV,WAAW,EAAE,IAAI,CAAC,IAAI,GAAG,UAAU;KACpC,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { jobs } from "@ttctl/core";
|
|
2
|
+
import type { OutputFormat } from "../../lib/output.js";
|
|
3
|
+
/**
|
|
4
|
+
* Action handler for `ttctl jobs show <id>`. Fetches a single job's
|
|
5
|
+
* detail view by id and emits via the cross-CLI output helper.
|
|
6
|
+
*
|
|
7
|
+
* Pretty rendering is a multi-line key:value layout grouped into
|
|
8
|
+
* sections (Job, Client, Skills, Status, Time zone). Sections with no
|
|
9
|
+
* data are omitted.
|
|
10
|
+
*
|
|
11
|
+
* `json` / `yaml` emit the full projection — machine consumers may
|
|
12
|
+
* project further as needed.
|
|
13
|
+
*/
|
|
14
|
+
export declare function runJobsShow(id: string, output: OutputFormat): Promise<void>;
|
|
15
|
+
/**
|
|
16
|
+
* Render the job detail as a sectioned multi-line block. Pure —
|
|
17
|
+
* directly unit-testable.
|
|
18
|
+
*/
|
|
19
|
+
export declare function formatJobDetail(job: jobs.JobDetail): string;
|
|
20
|
+
//# sourceMappingURL=show.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"show.d.ts","sourceRoot":"","sources":["../../../src/commands/jobs/show.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAGnC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAGxD;;;;;;;;;;GAUG;AACH,wBAAsB,WAAW,CAAC,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CAajF;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,GAAG,EAAE,IAAI,CAAC,SAAS,GAAG,MAAM,CAmF3D"}
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
// SPDX-License-Identifier: AGPL-3.0-only
|
|
2
|
+
// Copyright (C) 2026 Oleksii PELYKH
|
|
3
|
+
import { jobs } from "@ttctl/core";
|
|
4
|
+
import { emitResult } from "../../lib/output.js";
|
|
5
|
+
import { formatDate, formatRate, handleJobsError, loadAuthTokenOrExit } from "./shared.js";
|
|
6
|
+
/**
|
|
7
|
+
* Action handler for `ttctl jobs show <id>`. Fetches a single job's
|
|
8
|
+
* detail view by id and emits via the cross-CLI output helper.
|
|
9
|
+
*
|
|
10
|
+
* Pretty rendering is a multi-line key:value layout grouped into
|
|
11
|
+
* sections (Job, Client, Skills, Status, Time zone). Sections with no
|
|
12
|
+
* data are omitted.
|
|
13
|
+
*
|
|
14
|
+
* `json` / `yaml` emit the full projection — machine consumers may
|
|
15
|
+
* project further as needed.
|
|
16
|
+
*/
|
|
17
|
+
export async function runJobsShow(id, output) {
|
|
18
|
+
const token = await loadAuthTokenOrExit("jobs show", output);
|
|
19
|
+
let item;
|
|
20
|
+
try {
|
|
21
|
+
item = await jobs.show(token, id);
|
|
22
|
+
}
|
|
23
|
+
catch (err) {
|
|
24
|
+
handleJobsError("jobs show", err, output);
|
|
25
|
+
}
|
|
26
|
+
emitResult(item, output, {
|
|
27
|
+
pretty: (data) => formatJobDetail(data),
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Render the job detail as a sectioned multi-line block. Pure —
|
|
32
|
+
* directly unit-testable.
|
|
33
|
+
*/
|
|
34
|
+
export function formatJobDetail(job) {
|
|
35
|
+
const lines = [];
|
|
36
|
+
lines.push(`Job ${job.id}`);
|
|
37
|
+
if (job.title !== null)
|
|
38
|
+
lines.push(` ${job.title}`);
|
|
39
|
+
if (job.url !== null)
|
|
40
|
+
lines.push(` ${job.url}`);
|
|
41
|
+
if (job.commitment?.slug != null)
|
|
42
|
+
lines.push(` Commitment: ${job.commitment.slug}`);
|
|
43
|
+
if (job.workType?.slug != null)
|
|
44
|
+
lines.push(` Work type: ${job.workType.slug}`);
|
|
45
|
+
if (job.specialization?.title != null)
|
|
46
|
+
lines.push(` Specialization: ${job.specialization.title}`);
|
|
47
|
+
if (job.expectedHours !== null)
|
|
48
|
+
lines.push(` Hours: ${job.expectedHours.toString()}`);
|
|
49
|
+
if (job.minimumHoursPerBillingCycle !== null) {
|
|
50
|
+
lines.push(` Min hours/cycle: ${job.minimumHoursPerBillingCycle.toString()}`);
|
|
51
|
+
}
|
|
52
|
+
if (job.maxRate !== null)
|
|
53
|
+
lines.push(` Max rate: ${formatRate(job.maxRate)}`);
|
|
54
|
+
if (job.startDate !== null)
|
|
55
|
+
lines.push(` Starts: ${formatDate(job.startDate)}`);
|
|
56
|
+
if (job.postedWhen !== null)
|
|
57
|
+
lines.push(` Posted: ${job.postedWhen}`);
|
|
58
|
+
if (job.isCoaching === true)
|
|
59
|
+
lines.push(` Type: coaching`);
|
|
60
|
+
if (job.isToptalProject === true)
|
|
61
|
+
lines.push(` Type: toptal-project`);
|
|
62
|
+
const flagParts = [];
|
|
63
|
+
if (job.saved === true)
|
|
64
|
+
flagParts.push("saved");
|
|
65
|
+
if (job.notInterested === true)
|
|
66
|
+
flagParts.push("not-interested");
|
|
67
|
+
if (job.viewed === true)
|
|
68
|
+
flagParts.push("viewed");
|
|
69
|
+
if (flagParts.length > 0)
|
|
70
|
+
lines.push(` Status: ${flagParts.join(", ")}`);
|
|
71
|
+
if (job.client !== null) {
|
|
72
|
+
lines.push("");
|
|
73
|
+
lines.push("Client");
|
|
74
|
+
if (job.client.fullName !== null)
|
|
75
|
+
lines.push(` ${job.client.fullName}`);
|
|
76
|
+
if (job.client.industry !== null)
|
|
77
|
+
lines.push(` Industry: ${job.client.industry}`);
|
|
78
|
+
if (job.client.city !== null || job.client.countryName !== null) {
|
|
79
|
+
const loc = [job.client.city, job.client.countryName].filter((s) => s !== null).join(", ");
|
|
80
|
+
if (loc !== "")
|
|
81
|
+
lines.push(` Location: ${loc}`);
|
|
82
|
+
}
|
|
83
|
+
if (job.client.teamSize?.value != null)
|
|
84
|
+
lines.push(` Team size: ${job.client.teamSize.value}`);
|
|
85
|
+
if (job.client.website !== null)
|
|
86
|
+
lines.push(` Website: ${job.client.website}`);
|
|
87
|
+
if (job.client.linkedin !== null)
|
|
88
|
+
lines.push(` LinkedIn: ${job.client.linkedin}`);
|
|
89
|
+
if (job.client.isEnterprise === true)
|
|
90
|
+
lines.push(` Enterprise: yes`);
|
|
91
|
+
}
|
|
92
|
+
if (job.jobTimeZone !== null) {
|
|
93
|
+
const tz = job.jobTimeZone;
|
|
94
|
+
if (tz.verbose !== null || tz.hoursOverlap !== null) {
|
|
95
|
+
lines.push("");
|
|
96
|
+
lines.push("Time zone");
|
|
97
|
+
if (tz.verbose !== null)
|
|
98
|
+
lines.push(` ${tz.verbose}`);
|
|
99
|
+
if (tz.workingTimeFrom !== null && tz.workingTimeTo !== null) {
|
|
100
|
+
lines.push(` Hours: ${tz.workingTimeFrom} – ${tz.workingTimeTo}`);
|
|
101
|
+
}
|
|
102
|
+
if (tz.hoursOverlap !== null)
|
|
103
|
+
lines.push(` Overlap: ${tz.hoursOverlap.toString()}h`);
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
if (job.skills.length > 0) {
|
|
107
|
+
lines.push("");
|
|
108
|
+
lines.push("Skills");
|
|
109
|
+
for (const sk of job.skills) {
|
|
110
|
+
const optional = sk.isOptional === true ? " (optional)" : "";
|
|
111
|
+
const rating = sk.rating !== null ? ` ★${sk.rating.toString()}` : "";
|
|
112
|
+
lines.push(` • ${sk.name}${rating}${optional}`);
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
if (job.languages.length > 0) {
|
|
116
|
+
const langs = job.languages
|
|
117
|
+
.map((l) => l.name)
|
|
118
|
+
.filter((n) => n !== null)
|
|
119
|
+
.join(", ");
|
|
120
|
+
if (langs !== "") {
|
|
121
|
+
lines.push("");
|
|
122
|
+
lines.push(`Languages: ${langs}`);
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
if (job.descriptionMd !== null && job.descriptionMd !== "") {
|
|
126
|
+
lines.push("");
|
|
127
|
+
lines.push("Description");
|
|
128
|
+
for (const para of job.descriptionMd.split(/\n+/)) {
|
|
129
|
+
if (para.trim().length > 0)
|
|
130
|
+
lines.push(` ${para}`);
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
return lines.join("\n");
|
|
134
|
+
}
|
|
135
|
+
//# sourceMappingURL=show.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"show.js","sourceRoot":"","sources":["../../../src/commands/jobs/show.ts"],"names":[],"mappings":"AAAA,yCAAyC;AACzC,oCAAoC;AAEpC,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CA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C,IAAI,CAAC,EAAE,CAAC,CAAC;QACf,KAAK,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;QAC1B,KAAK,MAAM,IAAI,IAAI,GAAG,CAAC,aAAa,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,CAAC;YAClD,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC,MAAM,GAAG,CAAC;gBAAE,KAAK,CAAC,IAAI,CAAC,KAAK,IAAI,EAAE,CAAC,CAAC;QACtD,CAAC;IACH,CAAC;IAED,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAC1B,CAAC"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { Command } from "commander";
|
|
2
|
+
/**
|
|
3
|
+
* Build the `ttctl payments` command tree (#149). Seven leaves across
|
|
4
|
+
* three sub-namespaces:
|
|
5
|
+
*
|
|
6
|
+
* | Leaf | Description |
|
|
7
|
+
* |------------------------------------------------------------|-----------------------------------|
|
|
8
|
+
* | `payouts list [--from <d>] [--to <d>]` | List historical payouts |
|
|
9
|
+
* | `payouts show <id>` | Single payout detail |
|
|
10
|
+
* | `methods list` | List configured payment methods |
|
|
11
|
+
* | `methods show <id>` | Single payment method detail |
|
|
12
|
+
* | `rate show` | Current rate + change-request status |
|
|
13
|
+
* | `rate questions` | Discovery: form questions for `rate change` |
|
|
14
|
+
* | `rate change --kind=... --rate=... [...] --confirm` | Submit rate-change request |
|
|
15
|
+
*
|
|
16
|
+
* `<id>` is the entity id from the corresponding `list` leaf.
|
|
17
|
+
*
|
|
18
|
+
* **Per-issue scope refinements** (issue #149 comment 4441685270 —
|
|
19
|
+
* post-investigation, ux-architect consultation):
|
|
20
|
+
* - Original `rate-change list` (no list endpoint exists) → replaced
|
|
21
|
+
* with `rate show` (unified projection) + `rate questions` (form
|
|
22
|
+
* discovery).
|
|
23
|
+
* - Original `rate-change request --engagement --new-rate` (missing
|
|
24
|
+
* 3 of 5 mutation inputs) → replaced with `rate change --kind=...
|
|
25
|
+
* --rate=... [--engagement] [--comment] [--answer <q> <v>...]`.
|
|
26
|
+
*
|
|
27
|
+
* **Out of scope for v1** (per #149 spec):
|
|
28
|
+
* - Payment-method mutations (create / update / mark-as-preferred /
|
|
29
|
+
* remove).
|
|
30
|
+
* - Withdrawal request initiation.
|
|
31
|
+
* - Tax document generation / download.
|
|
32
|
+
*/
|
|
33
|
+
export declare function buildPaymentsCommand(): Command;
|
|
34
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/commands/payments/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,OAAO,EAAgC,MAAM,WAAW,CAAC;AAWlE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,wBAAgB,oBAAoB,IAAI,OAAO,CAoJ9C"}
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
// SPDX-License-Identifier: AGPL-3.0-only
|
|
2
|
+
// Copyright (C) 2026 Oleksii PELYKH
|
|
3
|
+
import { Command, InvalidArgumentError, Option } from "commander";
|
|
4
|
+
import { payments } from "@ttctl/core";
|
|
5
|
+
import { markMutation } from "../../lib/dry-run.js";
|
|
6
|
+
import { OUTPUT_FORMATS } from "../../lib/output.js";
|
|
7
|
+
import { runPaymentsMethodsList, runPaymentsMethodsShow } from "./methods.js";
|
|
8
|
+
import { runPaymentsPayoutsList, runPaymentsPayoutsShow } from "./payouts.js";
|
|
9
|
+
import { runPaymentsRateChange, runPaymentsRateQuestions, runPaymentsRateShow } from "./rate.js";
|
|
10
|
+
/**
|
|
11
|
+
* Build the `ttctl payments` command tree (#149). Seven leaves across
|
|
12
|
+
* three sub-namespaces:
|
|
13
|
+
*
|
|
14
|
+
* | Leaf | Description |
|
|
15
|
+
* |------------------------------------------------------------|-----------------------------------|
|
|
16
|
+
* | `payouts list [--from <d>] [--to <d>]` | List historical payouts |
|
|
17
|
+
* | `payouts show <id>` | Single payout detail |
|
|
18
|
+
* | `methods list` | List configured payment methods |
|
|
19
|
+
* | `methods show <id>` | Single payment method detail |
|
|
20
|
+
* | `rate show` | Current rate + change-request status |
|
|
21
|
+
* | `rate questions` | Discovery: form questions for `rate change` |
|
|
22
|
+
* | `rate change --kind=... --rate=... [...] --confirm` | Submit rate-change request |
|
|
23
|
+
*
|
|
24
|
+
* `<id>` is the entity id from the corresponding `list` leaf.
|
|
25
|
+
*
|
|
26
|
+
* **Per-issue scope refinements** (issue #149 comment 4441685270 —
|
|
27
|
+
* post-investigation, ux-architect consultation):
|
|
28
|
+
* - Original `rate-change list` (no list endpoint exists) → replaced
|
|
29
|
+
* with `rate show` (unified projection) + `rate questions` (form
|
|
30
|
+
* discovery).
|
|
31
|
+
* - Original `rate-change request --engagement --new-rate` (missing
|
|
32
|
+
* 3 of 5 mutation inputs) → replaced with `rate change --kind=...
|
|
33
|
+
* --rate=... [--engagement] [--comment] [--answer <q> <v>...]`.
|
|
34
|
+
*
|
|
35
|
+
* **Out of scope for v1** (per #149 spec):
|
|
36
|
+
* - Payment-method mutations (create / update / mark-as-preferred /
|
|
37
|
+
* remove).
|
|
38
|
+
* - Withdrawal request initiation.
|
|
39
|
+
* - Tax document generation / download.
|
|
40
|
+
*/
|
|
41
|
+
export function buildPaymentsCommand() {
|
|
42
|
+
const cmd = new Command("payments").description("View payouts, configured payment methods, and rate-change history; submit a rate-change request");
|
|
43
|
+
// ----- payouts sub-group ---------------------------------------------
|
|
44
|
+
const payouts = cmd.command("payouts").description("Historical payouts (read-only)");
|
|
45
|
+
payouts
|
|
46
|
+
.command("list")
|
|
47
|
+
.description("List historical payouts (default: server order, most-recent first)")
|
|
48
|
+
.option("--from <date>", "filter by createdOn lower bound (inclusive YYYY-MM-DD)")
|
|
49
|
+
.option("--to <date>", "filter by createdOn upper bound (inclusive YYYY-MM-DD)")
|
|
50
|
+
.addOption(new Option("-o, --output <format>", "output format")
|
|
51
|
+
.choices(OUTPUT_FORMATS)
|
|
52
|
+
.default("pretty"))
|
|
53
|
+
.action(async (options) => {
|
|
54
|
+
const listOpts = { output: options.output };
|
|
55
|
+
if (options.from !== undefined)
|
|
56
|
+
listOpts.from = options.from;
|
|
57
|
+
if (options.to !== undefined)
|
|
58
|
+
listOpts.to = options.to;
|
|
59
|
+
await runPaymentsPayoutsList(listOpts);
|
|
60
|
+
});
|
|
61
|
+
payouts
|
|
62
|
+
.command("show")
|
|
63
|
+
.description("Show one payout by id")
|
|
64
|
+
.argument("<id>", "payout id (the row id from `payouts list`)", parseIdArg)
|
|
65
|
+
.addOption(new Option("-o, --output <format>", "output format")
|
|
66
|
+
.choices(OUTPUT_FORMATS)
|
|
67
|
+
.default("pretty"))
|
|
68
|
+
.action(async (id, options) => {
|
|
69
|
+
await runPaymentsPayoutsShow(id, options.output);
|
|
70
|
+
});
|
|
71
|
+
// ----- methods sub-group ---------------------------------------------
|
|
72
|
+
const methods = cmd.command("methods").description("Configured payment methods (read-only)");
|
|
73
|
+
methods
|
|
74
|
+
.command("list")
|
|
75
|
+
.description("List configured payment methods")
|
|
76
|
+
.addOption(new Option("-o, --output <format>", "output format")
|
|
77
|
+
.choices(OUTPUT_FORMATS)
|
|
78
|
+
.default("pretty"))
|
|
79
|
+
.action(async (options) => {
|
|
80
|
+
await runPaymentsMethodsList(options.output);
|
|
81
|
+
});
|
|
82
|
+
methods
|
|
83
|
+
.command("show")
|
|
84
|
+
.description("Show one payment method by id")
|
|
85
|
+
.argument("<id>", "payment method id (from `methods list`)", parseIdArg)
|
|
86
|
+
.addOption(new Option("-o, --output <format>", "output format")
|
|
87
|
+
.choices(OUTPUT_FORMATS)
|
|
88
|
+
.default("pretty"))
|
|
89
|
+
.action(async (id, options) => {
|
|
90
|
+
await runPaymentsMethodsShow(id, options.output);
|
|
91
|
+
});
|
|
92
|
+
// ----- rate sub-group ------------------------------------------------
|
|
93
|
+
const rate = cmd.command("rate").description("Current rate + rate-change requests");
|
|
94
|
+
rate
|
|
95
|
+
.command("show")
|
|
96
|
+
.description("Show current rate, last/ongoing rate-change request, market insight, and validation rules")
|
|
97
|
+
.addOption(new Option("-o, --output <format>", "output format")
|
|
98
|
+
.choices(OUTPUT_FORMATS)
|
|
99
|
+
.default("pretty"))
|
|
100
|
+
.action(async (options) => {
|
|
101
|
+
await runPaymentsRateShow(options.output);
|
|
102
|
+
});
|
|
103
|
+
rate
|
|
104
|
+
.command("questions")
|
|
105
|
+
.description("List the form questions required by `rate change` (discovery)")
|
|
106
|
+
.addOption(new Option("-o, --output <format>", "output format")
|
|
107
|
+
.choices(OUTPUT_FORMATS)
|
|
108
|
+
.default("pretty"))
|
|
109
|
+
.action(async (options) => {
|
|
110
|
+
await runPaymentsRateQuestions(options.output);
|
|
111
|
+
});
|
|
112
|
+
// Marked as a mutation (issue #163) so the global `--dry-run` flag
|
|
113
|
+
// routes through to `payments.rate.change()`'s `dryRun` option.
|
|
114
|
+
markMutation(rate
|
|
115
|
+
.command("change")
|
|
116
|
+
.description("Submit a rate-change request (requires `--confirm`)")
|
|
117
|
+
.addOption(new Option("--kind <kind>", "rate-change kind")
|
|
118
|
+
.choices([...payments.RATE_CHANGE_KINDS])
|
|
119
|
+
.makeOptionMandatory(true))
|
|
120
|
+
.requiredOption("--rate <decimal>", "desired hourly rate (decimal, e.g. `95.0`)")
|
|
121
|
+
.option("--engagement <id>", "engagement id (required for --kind=current-engagement; rejected for other kinds)")
|
|
122
|
+
.option("--comment <text>", "optional free-text comment attached to the request")
|
|
123
|
+
.option("--answer <args...>", "answer to a form question, two args per repeat: `--answer <question-id> <value>` (repeatable; discover ids via `payments rate questions`)")
|
|
124
|
+
.option("--answer-comment <args...>", "comment for a previously-supplied answer (when `commentRequired: true` on the picked option): `--answer-comment <question-id> <text>` (repeatable)")
|
|
125
|
+
.option("--confirm", "explicit confirmation (required — refuses without)")
|
|
126
|
+
.addOption(new Option("-o, --output <format>", "output format")
|
|
127
|
+
.choices(OUTPUT_FORMATS)
|
|
128
|
+
.default("pretty"))
|
|
129
|
+
.action(async (options) => {
|
|
130
|
+
const changeOpts = {
|
|
131
|
+
kind: options.kind,
|
|
132
|
+
rate: options.rate,
|
|
133
|
+
output: options.output,
|
|
134
|
+
};
|
|
135
|
+
if (options.engagement !== undefined)
|
|
136
|
+
changeOpts.engagement = options.engagement;
|
|
137
|
+
if (options.comment !== undefined)
|
|
138
|
+
changeOpts.comment = options.comment;
|
|
139
|
+
if (options.answer !== undefined)
|
|
140
|
+
changeOpts.answer = options.answer;
|
|
141
|
+
if (options.answerComment !== undefined)
|
|
142
|
+
changeOpts.answerComment = options.answerComment;
|
|
143
|
+
if (options.confirm !== undefined)
|
|
144
|
+
changeOpts.confirm = options.confirm;
|
|
145
|
+
await runPaymentsRateChange(changeOpts);
|
|
146
|
+
}));
|
|
147
|
+
return cmd;
|
|
148
|
+
}
|
|
149
|
+
/**
|
|
150
|
+
* Reject empty or whitespace-only id arguments at parse time. Mirrors
|
|
151
|
+
* the engagements/jobs groups' `parseIdArg`.
|
|
152
|
+
*/
|
|
153
|
+
function parseIdArg(value) {
|
|
154
|
+
const trimmed = value.trim();
|
|
155
|
+
if (trimmed.length === 0) {
|
|
156
|
+
throw new InvalidArgumentError("id must not be empty");
|
|
157
|
+
}
|
|
158
|
+
return trimmed;
|
|
159
|
+
}
|
|
160
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/commands/payments/index.ts"],"names":[],"mappings":"AAAA,yCAAyC;AACzC,oCAAoC;AAEpC,OAAO,EAAE,OAAO,EAAE,oBAAoB,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAElE,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAEvC,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACpD,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAErD,OAAO,EAAE,sBAAsB,EAAE,sBAAsB,EA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-0,0 +1,17 @@
|
|
|
1
|
+
import { payments } from "@ttctl/core";
|
|
2
|
+
import type { OutputFormat } from "../../lib/output.js";
|
|
3
|
+
/**
|
|
4
|
+
* Action handler for `ttctl payments methods list`. Lists configured
|
|
5
|
+
* payment methods. The preferred method is annotated with a leading
|
|
6
|
+
* marker in pretty / table rendering.
|
|
7
|
+
*/
|
|
8
|
+
export declare function runPaymentsMethodsList(output: OutputFormat): Promise<void>;
|
|
9
|
+
/**
|
|
10
|
+
* Action handler for `ttctl payments methods show <id>`. No
|
|
11
|
+
* per-id wire op exists; the service performs a client-side filter
|
|
12
|
+
* on the full methods list.
|
|
13
|
+
*/
|
|
14
|
+
export declare function runPaymentsMethodsShow(id: string, output: OutputFormat): Promise<void>;
|
|
15
|
+
export declare function formatMethodsTable(items: payments.PaymentMethod[]): string;
|
|
16
|
+
export declare function formatMethodDetail(m: payments.PaymentMethod): string;
|
|
17
|
+
//# sourceMappingURL=methods.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"methods.d.ts","sourceRoot":"","sources":["../../../src/commands/payments/methods.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAIvC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAGxD;;;;GAIG;AACH,wBAAsB,sBAAsB,CAAC,MAAM,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CAehF;AAED;;;;GAIG;AACH,wBAAsB,sBAAsB,CAAC,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CAa5F;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,QAAQ,CAAC,aAAa,EAAE,GAAG,MAAM,CAa1E;AAED,wBAAgB,kBAAkB,CAAC,CAAC,EAAE,QAAQ,CAAC,aAAa,GAAG,MAAM,CAYpE"}
|