feat(hooks): introduce hook templates management and execution

- Added a new command `ccw hook template` with subcommands for listing, installing, and executing templates.
- Implemented backend support for managing hook templates, including API routes for fetching and installing templates.
- Created a new file `hook-templates.ts` to define and manage hook templates, including their execution logic.
- Added a migration script to convert old-style hooks to the new template-based approach.
- Updated documentation to reflect new template commands and usage examples.
- Enhanced error handling and output formatting for better user experience.
This commit is contained in:
catlog22
2026-03-03 10:07:34 +08:00
parent 59787dc9be
commit 9613644fc4
6 changed files with 1353 additions and 158 deletions

View File

@@ -898,10 +898,31 @@ textarea:focus-visible {
* "Intelligent Responsive Content Width" section.
*/
@media (min-width: 1024px) {
/* Expand .content to fill available space */
/* Remove padding from VPDoc to maximize content width */
.VPDoc.has-aside {
padding-left: 0 !important;
padding-right: 0 !important;
}
/* Remove padding from container to maximize content width */
.VPDoc.has-aside .container {
justify-content: flex-start !important;
padding-left: 0 !important;
padding-right: 0 !important;
}
/* Keep .aside at fixed width */
.VPDoc.has-aside .container .aside {
flex: 0 0 auto !important;
}
/* Expand .content to fill available space and remove padding */
.VPDoc.has-aside .container .content {
flex-grow: 1 !important;
flex: 1 1 0 !important;
min-width: 0 !important;
max-width: none !important;
padding-left: 0 !important;
padding-right: 0 !important;
}
/* Use multiple selectors to increase specificity and override scoped styles */
@@ -910,9 +931,6 @@ textarea:focus-visible {
.content-container {
max-width: none !important;
width: 100% !important;
min-width: 100% !important;
flex-grow: 1 !important;
flex-basis: 100% !important;
}
.vp-doc {