@smartsoft001/pro-claude-plugins 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/marketplace.json +26 -0
- package/README.md +56 -0
- package/package.json +14 -0
- package/plugins/flow/.claude-plugin/README.md +91 -0
- package/plugins/flow/.claude-plugin/merge-permissions.js +115 -0
- package/plugins/flow/.claude-plugin/plugin.json +5 -0
- package/plugins/flow/.claude-plugin/settings.template.json +86 -0
- package/plugins/flow/agents/angular-component-scaffolder.md +176 -0
- package/plugins/flow/agents/angular-directive-builder.md +154 -0
- package/plugins/flow/agents/angular-guard-builder.md +244 -0
- package/plugins/flow/agents/angular-jest-test-writer.md +475 -0
- package/plugins/flow/agents/angular-pipe-builder.md +170 -0
- package/plugins/flow/agents/angular-resolver-builder.md +287 -0
- package/plugins/flow/agents/angular-service-builder.md +162 -0
- package/plugins/flow/agents/angular-signal-state-builder.md +340 -0
- package/plugins/flow/agents/angular-test-diagnostician.md +279 -0
- package/plugins/flow/agents/angular-testbed-configurator.md +315 -0
- package/plugins/flow/agents/arch-scaffolder.md +278 -0
- package/plugins/flow/agents/e2e-data-testid-injector.md +195 -0
- package/plugins/flow/agents/e2e-project-scaffolder.md +194 -0
- package/plugins/flow/agents/e2e-test-writer.md +357 -0
- package/plugins/flow/agents/shared-agent-evolver.md +294 -0
- package/plugins/flow/agents/shared-build-verifier.md +160 -0
- package/plugins/flow/agents/shared-config-updater.md +310 -0
- package/plugins/flow/agents/shared-coverage-enforcer.md +184 -0
- package/plugins/flow/agents/shared-error-handler.md +217 -0
- package/plugins/flow/agents/shared-file-creator.md +344 -0
- package/plugins/flow/agents/shared-impl-orchestrator.md +312 -0
- package/plugins/flow/agents/shared-impl-reporter.md +368 -0
- package/plugins/flow/agents/shared-impl-teammate.md +201 -0
- package/plugins/flow/agents/shared-linear-subtask-iterator.md +337 -0
- package/plugins/flow/agents/shared-logic-implementer.md +244 -0
- package/plugins/flow/agents/shared-maia-api.md +26 -0
- package/plugins/flow/agents/shared-parallelization-analyzer.md +343 -0
- package/plugins/flow/agents/shared-performance-validator.md +168 -0
- package/plugins/flow/agents/shared-plan-perspective.md +271 -0
- package/plugins/flow/agents/shared-project-standardizer.md +205 -0
- package/plugins/flow/agents/shared-report-synthesizer.md +188 -0
- package/plugins/flow/agents/shared-review-teammate.md +189 -0
- package/plugins/flow/agents/shared-security-scanner.md +186 -0
- package/plugins/flow/agents/shared-style-enforcer.md +230 -0
- package/plugins/flow/agents/shared-subtask-dependency-analyzer.md +189 -0
- package/plugins/flow/agents/shared-tdd-developer.md +350 -0
- package/plugins/flow/agents/shared-team-coordinator.md +192 -0
- package/plugins/flow/agents/shared-test-fixer.md +186 -0
- package/plugins/flow/agents/shared-test-runner.md +191 -0
- package/plugins/flow/agents/shared-ui-classifier.md +263 -0
- package/plugins/flow/agents/shared-verification-orchestrator.md +194 -0
- package/plugins/flow/agents/shared-verification-runner.md +140 -0
- package/plugins/flow/agents/ui-a11y-validator.md +305 -0
- package/plugins/flow/agents/ui-screenshot-reporter.md +329 -0
- package/plugins/flow/agents/ui-web-designer.md +214 -0
- package/plugins/flow/scripts/compute-session-tokens.sh +39 -0
- package/plugins/flow/skills/a11y-audit/SKILL.md +214 -0
- package/plugins/flow/skills/angular-patterns/SKILL.md +191 -0
- package/plugins/flow/skills/browser-capture/SKILL.md +238 -0
- package/plugins/flow/skills/commit/SKILL.md +259 -0
- package/plugins/flow/skills/debug-helper/SKILL.md +375 -0
- package/plugins/flow/skills/impl/SKILL.md +992 -0
- package/plugins/flow/skills/karpathy-guidelines/SKILL.md +72 -0
- package/plugins/flow/skills/linear-suggestion/SKILL.md +132 -0
- package/plugins/flow/skills/maia-files-delete/SKILL.md +59 -0
- package/plugins/flow/skills/maia-files-upload/SKILL.md +57 -0
- package/plugins/flow/skills/nx-conventions/SKILL.md +326 -0
- package/plugins/flow/skills/plan/SKILL.md +1033 -0
- package/plugins/flow/skills/push/SKILL.md +759 -0
- package/plugins/flow/skills/review/SKILL.md +443 -0
- package/plugins/flow/skills/test-e2e/SKILL.md +164 -0
- package/plugins/flow/skills/test-unit/SKILL.md +456 -0
- package/plugins/flow-external/.claude-plugin/README.md +146 -0
- package/plugins/flow-external/.claude-plugin/merge-permissions.js +94 -0
- package/plugins/flow-external/.claude-plugin/plugin.json +5 -0
- package/plugins/flow-external/.claude-plugin/settings.template.json +78 -0
- package/plugins/flow-external/agents/angular-component-scaffolder.md +271 -0
- package/plugins/flow-external/agents/angular-directive-builder.md +134 -0
- package/plugins/flow-external/agents/angular-guard-builder.md +73 -0
- package/plugins/flow-external/agents/angular-pipe-builder.md +90 -0
- package/plugins/flow-external/agents/angular-resolver-builder.md +79 -0
- package/plugins/flow-external/agents/angular-service-builder.md +168 -0
- package/plugins/flow-external/agents/angular-state-builder.md +263 -0
- package/plugins/flow-external/agents/shared-build-verifier.md +67 -0
- package/plugins/flow-external/agents/shared-impl-orchestrator.md +90 -0
- package/plugins/flow-external/agents/shared-impl-reporter.md +135 -0
- package/plugins/flow-external/agents/shared-linear-subtask-iterator.md +70 -0
- package/plugins/flow-external/agents/shared-ui-classifier.md +38 -0
- package/plugins/flow-external/agents/ui-web-designer.md +203 -0
- package/plugins/flow-external/scripts/compute-session-tokens.sh +39 -0
- package/plugins/flow-external/skills/a11y-audit/SKILL.md +97 -0
- package/plugins/flow-external/skills/angular-cli-conventions/SKILL.md +268 -0
- package/plugins/flow-external/skills/angular-patterns/SKILL.md +182 -0
- package/plugins/flow-external/skills/browser-capture/SKILL.md +74 -0
- package/plugins/flow-external/skills/commit/SKILL.md +114 -0
- package/plugins/flow-external/skills/debug-helper/SKILL.md +135 -0
- package/plugins/flow-external/skills/impl/SKILL.md +218 -0
- package/plugins/flow-external/skills/karpathy-guidelines/SKILL.md +72 -0
- package/plugins/flow-external/skills/linear-suggestion/SKILL.md +62 -0
- package/plugins/flow-external/skills/maia-files-delete/SKILL.md +34 -0
- package/plugins/flow-external/skills/maia-files-upload/SKILL.md +41 -0
- package/plugins/flow-external/skills/plan/SKILL.md +334 -0
- package/plugins/flow-external/skills/push/SKILL.md +232 -0
- package/plugins/flow-legacy/.claude-plugin/README.md +143 -0
- package/plugins/flow-legacy/.claude-plugin/merge-permissions.js +94 -0
- package/plugins/flow-legacy/.claude-plugin/plugin.json +5 -0
- package/plugins/flow-legacy/.claude-plugin/settings.template.json +79 -0
- package/plugins/flow-legacy/agents/angular-component-scaffolder.md +327 -0
- package/plugins/flow-legacy/agents/angular-directive-builder.md +253 -0
- package/plugins/flow-legacy/agents/angular-guard-builder.md +326 -0
- package/plugins/flow-legacy/agents/angular-pipe-builder.md +238 -0
- package/plugins/flow-legacy/agents/angular-resolver-builder.md +339 -0
- package/plugins/flow-legacy/agents/angular-service-builder.md +271 -0
- package/plugins/flow-legacy/agents/angular-state-builder.md +480 -0
- package/plugins/flow-legacy/agents/shared-impl-orchestrator.md +174 -0
- package/plugins/flow-legacy/agents/shared-impl-reporter.md +232 -0
- package/plugins/flow-legacy/agents/shared-linear-subtask-iterator.md +198 -0
- package/plugins/flow-legacy/agents/shared-tdd-developer.md +307 -0
- package/plugins/flow-legacy/agents/shared-test-runner.md +133 -0
- package/plugins/flow-legacy/agents/shared-ui-classifier.md +145 -0
- package/plugins/flow-legacy/scripts/compute-session-tokens.sh +39 -0
- package/plugins/flow-legacy/skills/a11y-audit/SKILL.md +214 -0
- package/plugins/flow-legacy/skills/angular-patterns/SKILL.md +346 -0
- package/plugins/flow-legacy/skills/browser-capture/SKILL.md +238 -0
- package/plugins/flow-legacy/skills/commit/SKILL.md +215 -0
- package/plugins/flow-legacy/skills/debug-helper/SKILL.md +395 -0
- package/plugins/flow-legacy/skills/impl/SKILL.md +710 -0
- package/plugins/flow-legacy/skills/karpathy-guidelines/SKILL.md +72 -0
- package/plugins/flow-legacy/skills/linear-suggestion/SKILL.md +132 -0
- package/plugins/flow-legacy/skills/maia-files-delete/SKILL.md +59 -0
- package/plugins/flow-legacy/skills/maia-files-upload/SKILL.md +57 -0
- package/plugins/flow-legacy/skills/nx-conventions/SKILL.md +368 -0
- package/plugins/flow-legacy/skills/plan/SKILL.md +742 -0
- package/plugins/flow-legacy/skills/push/SKILL.md +645 -0
- package/plugins/flow-legacy/skills/test-unit/SKILL.md +500 -0
- package/plugins/smart-pro/.claude-plugin/README.md +115 -0
- package/plugins/smart-pro/.claude-plugin/merge-permissions.js +129 -0
- package/plugins/smart-pro/.claude-plugin/plugin.json +5 -0
- package/plugins/smart-pro/.claude-plugin/settings.template.json +94 -0
- package/plugins/smart-pro/agents/angular-components/AGENT.md +214 -0
- package/plugins/smart-pro/hooks/CONFIG.md +198 -0
- package/plugins/smart-pro/hooks/README.md +139 -0
- package/plugins/smart-pro/hooks/audit_logger.py +107 -0
- package/plugins/smart-pro/hooks/auto_format.sh +11 -0
- package/plugins/smart-pro/hooks/hooks.json +79 -0
- package/plugins/smart-pro/hooks/safety_validator.py +129 -0
- package/plugins/smart-pro/hooks/sensitive_file_blocker.py +58 -0
- package/plugins/smart-pro/hooks/skill_validator.py +220 -0
- package/plugins/smart-pro/skills/angular-components-action-panel/SKILL.md +159 -0
- package/plugins/smart-pro/skills/angular-components-avatar/SKILL.md +142 -0
- package/plugins/smart-pro/skills/angular-components-badge/SKILL.md +110 -0
- package/plugins/smart-pro/skills/angular-components-breadcrumbs/SKILL.md +91 -0
- package/plugins/smart-pro/skills/angular-components-button/SKILL.md +146 -0
- package/plugins/smart-pro/skills/angular-components-button-group/SKILL.md +121 -0
- package/plugins/smart-pro/skills/angular-components-calendar/SKILL.md +78 -0
- package/plugins/smart-pro/skills/angular-components-card/SKILL.md +110 -0
- package/plugins/smart-pro/skills/angular-components-card-heading/SKILL.md +105 -0
- package/plugins/smart-pro/skills/angular-components-command-palette/SKILL.md +168 -0
- package/plugins/smart-pro/skills/angular-components-container/SKILL.md +93 -0
- package/plugins/smart-pro/skills/angular-components-description-list/SKILL.md +102 -0
- package/plugins/smart-pro/skills/angular-components-details/SKILL.md +70 -0
- package/plugins/smart-pro/skills/angular-components-divider/SKILL.md +110 -0
- package/plugins/smart-pro/skills/angular-components-drawer/SKILL.md +136 -0
- package/plugins/smart-pro/skills/angular-components-dropdown/SKILL.md +131 -0
- package/plugins/smart-pro/skills/angular-components-empty-state/SKILL.md +103 -0
- package/plugins/smart-pro/skills/angular-components-feed/SKILL.md +110 -0
- package/plugins/smart-pro/skills/angular-components-form/SKILL.md +77 -0
- package/plugins/smart-pro/skills/angular-components-grid-list/SKILL.md +91 -0
- package/plugins/smart-pro/skills/angular-components-input/SKILL.md +118 -0
- package/plugins/smart-pro/skills/angular-components-list/SKILL.md +75 -0
- package/plugins/smart-pro/skills/angular-components-list-container/SKILL.md +106 -0
- package/plugins/smart-pro/skills/angular-components-media-object/SKILL.md +133 -0
- package/plugins/smart-pro/skills/angular-components-modal/SKILL.md +159 -0
- package/plugins/smart-pro/skills/angular-components-multi-column-layout/SKILL.md +84 -0
- package/plugins/smart-pro/skills/angular-components-navbar/SKILL.md +93 -0
- package/plugins/smart-pro/skills/angular-components-notification/SKILL.md +147 -0
- package/plugins/smart-pro/skills/angular-components-page/SKILL.md +162 -0
- package/plugins/smart-pro/skills/angular-components-page-heading/SKILL.md +96 -0
- package/plugins/smart-pro/skills/angular-components-paging/SKILL.md +86 -0
- package/plugins/smart-pro/skills/angular-components-progress-bars/SKILL.md +94 -0
- package/plugins/smart-pro/skills/angular-components-searchbar/SKILL.md +113 -0
- package/plugins/smart-pro/skills/angular-components-section-heading/SKILL.md +156 -0
- package/plugins/smart-pro/skills/angular-components-select-menu/SKILL.md +101 -0
- package/plugins/smart-pro/skills/angular-components-sidebar-layout/SKILL.md +121 -0
- package/plugins/smart-pro/skills/angular-components-sidebar-navigation/SKILL.md +80 -0
- package/plugins/smart-pro/skills/angular-components-sign-in-form/SKILL.md +91 -0
- package/plugins/smart-pro/skills/angular-components-stacked-layout/SKILL.md +114 -0
- package/plugins/smart-pro/skills/angular-components-stacked-list/SKILL.md +93 -0
- package/plugins/smart-pro/skills/angular-components-stats/SKILL.md +87 -0
- package/plugins/smart-pro/skills/angular-components-table/SKILL.md +98 -0
- package/plugins/smart-pro/skills/angular-components-tabs/SKILL.md +99 -0
- package/plugins/smart-pro/skills/angular-components-textarea/SKILL.md +111 -0
- package/plugins/smart-pro/skills/angular-components-toggle/SKILL.md +109 -0
- package/plugins/smart-pro/skills/angular-components-vertical-navigation/SKILL.md +139 -0
- package/plugins/smart-pro/skills/audit-log/SKILL.md +82 -0
- package/plugins/smart-pro/skills/format-code/SKILL.md +46 -0
- package/plugins/smart-pro/skills/project-conventions/SKILL.md +90 -0
- package/plugins/smart-pro/skills/safety-check/SKILL.md +0 -0
- package/src/index.d.ts +6 -0
- package/src/index.js +7 -0
- package/src/index.js.map +1 -0
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: angular-components-table
|
|
3
|
+
description: Table component for @smartsoft001/pro-angular. Four variants (default, with-grouped-rows, with-summary-rows, responsive) driven by `ITableOptionsPro.columns` / `rows` plus feature flags (`inCard`, `border`, `selectable`, `sortable`, `stickyHeader`, `hideHeadings`, `withAvatars`, `width`, `mobileStrategy`).
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Table Component (Pro)
|
|
8
|
+
|
|
9
|
+
Use `<smartpro-table>` and pick a variant via `variant`. The component reads `ITableOptionsPro.columns` / `rows` and a set of feature flags that combine cleanly. Each column declares `key`, optional `label`, optional `align`, optional `sortable`, and optional `headerTpl` / `cellTpl` template overrides.
|
|
10
|
+
|
|
11
|
+
## Variants
|
|
12
|
+
|
|
13
|
+
| `variant` (default `'default'`) | Selector | Description |
|
|
14
|
+
| ------------------------------- | ---------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
15
|
+
| `'default'` | `smartpro-table-default` | Adaptive table with composable feature flags. `inCard: true` wraps in a rounded `bg-white shadow-sm` card; `border: true` wraps in a `rounded-lg ring-1` border; `selectable: true` adds a checkbox column; `sortable: true` shows sort affordances on `column.sortable: true`; `stickyHeader: true` makes the thead sticky; `hideHeadings: true` visually hides headers; `withAvatars: true` renders the first column as `avatar + email`; `width: 'constrained-full'` wraps cell content in `mx-auto max-w-7xl`. |
|
|
16
|
+
| `'with-grouped-rows'` | `smartpro-table-with-grouped-rows` | Table with extra group-row sections (rows grouped by `row.group`). |
|
|
17
|
+
| `'with-summary-rows'` | `smartpro-table-with-summary-rows` | Table with summary rows interleaved with the data rows. |
|
|
18
|
+
| `'responsive'` | `smartpro-table-responsive` | Mobile-first table. `mobileStrategy: 'hide'` hides all but the first column on mobile; `mobileStrategy: 'stack'` stacks columns vertically on mobile. |
|
|
19
|
+
|
|
20
|
+
## API
|
|
21
|
+
|
|
22
|
+
### ITableOptionsPro (`table.types.ts`, extends `ITableOptions`)
|
|
23
|
+
|
|
24
|
+
```typescript
|
|
25
|
+
type SmartTableVariantPro =
|
|
26
|
+
| 'default'
|
|
27
|
+
| 'with-grouped-rows'
|
|
28
|
+
| 'with-summary-rows'
|
|
29
|
+
| 'responsive';
|
|
30
|
+
|
|
31
|
+
interface ITableOptionsPro {
|
|
32
|
+
title?: string;
|
|
33
|
+
columns?: ITableColumn[];
|
|
34
|
+
rows?: Record<string, unknown>[];
|
|
35
|
+
striped?: boolean;
|
|
36
|
+
inCard?: boolean;
|
|
37
|
+
border?: boolean;
|
|
38
|
+
selectable?: boolean;
|
|
39
|
+
sortable?: boolean;
|
|
40
|
+
stickyHeader?: boolean;
|
|
41
|
+
hideHeadings?: boolean;
|
|
42
|
+
withAvatars?: boolean;
|
|
43
|
+
width?: 'normal' | 'constrained-full';
|
|
44
|
+
mobileStrategy?: 'hide' | 'stack';
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
interface ITableColumn {
|
|
48
|
+
key: string;
|
|
49
|
+
label?: string;
|
|
50
|
+
align?: 'left' | 'center' | 'right';
|
|
51
|
+
sortable?: boolean;
|
|
52
|
+
headerTpl?: TemplateRef<unknown>;
|
|
53
|
+
cellTpl?: TemplateRef<{ $implicit: Record<string, unknown>; key: string }>;
|
|
54
|
+
}
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
### Wrapper Inputs
|
|
58
|
+
|
|
59
|
+
| Input | Type | Default | Description |
|
|
60
|
+
| --------- | ------------------------------------------------------------------------- | ----------- | ----------------------- |
|
|
61
|
+
| `variant` | `'default' \| 'with-grouped-rows' \| 'with-summary-rows' \| 'responsive'` | `'default'` | Variant family. |
|
|
62
|
+
| `options` | `ITableOptionsPro \| undefined` | `undefined` | Columns + rows + flags. |
|
|
63
|
+
| `class` | `string` | `''` | Extra CSS classes. |
|
|
64
|
+
|
|
65
|
+
## Usage Example
|
|
66
|
+
|
|
67
|
+
```html
|
|
68
|
+
<!-- Default simple -->
|
|
69
|
+
<smartpro-table [options]="{ columns, rows }"></smartpro-table>
|
|
70
|
+
|
|
71
|
+
<!-- In card with border -->
|
|
72
|
+
<smartpro-table [options]="{ columns, rows, inCard: true }"></smartpro-table>
|
|
73
|
+
|
|
74
|
+
<!-- Selectable + sortable + sticky header -->
|
|
75
|
+
<smartpro-table
|
|
76
|
+
[options]="{ columns, rows, selectable: true, sortable: true, stickyHeader: true }"
|
|
77
|
+
></smartpro-table>
|
|
78
|
+
|
|
79
|
+
<!-- Responsive: hide all but first column on mobile -->
|
|
80
|
+
<smartpro-table
|
|
81
|
+
variant="responsive"
|
|
82
|
+
[options]="{ columns, rows, mobileStrategy: 'hide' }"
|
|
83
|
+
></smartpro-table>
|
|
84
|
+
|
|
85
|
+
<!-- Responsive: stack columns vertically on mobile -->
|
|
86
|
+
<smartpro-table
|
|
87
|
+
variant="responsive"
|
|
88
|
+
[options]="{ columns, rows, mobileStrategy: 'stack' }"
|
|
89
|
+
></smartpro-table>
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
## File Locations
|
|
93
|
+
|
|
94
|
+
- Wrapper: `packages/shared/angular/src/lib/components/table/table.component.ts`
|
|
95
|
+
- Types: `packages/shared/angular/src/lib/components/table/table.types.ts`
|
|
96
|
+
- Variants: `packages/shared/angular/src/lib/components/table/{default,responsive,with-grouped-rows,with-summary-rows}/<name>.component.ts`
|
|
97
|
+
- Shared utilities: `packages/shared/angular/src/lib/components/table/table-classes.util.ts`
|
|
98
|
+
- Stories: `packages/shared/angular/src/lib/components/table/table.component.stories.ts`
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: angular-components-tabs
|
|
3
|
+
description: Tabs components for @smartsoft001/pro-angular. Two layouts (underline, pills) with adaptive styling for full-width, in-bar, bare-text, per-item icons/badges, and pill background variants.
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Tabs Components (Pro)
|
|
8
|
+
|
|
9
|
+
Use `<smartpro-tabs>` and pick a layout via `options.layout: 'underline' | 'pills'`. Both adapt to optional flags on the options object. Each renders a horizontal tab list with a mobile `<select>` fallback (disable via `options.showMobileSelect = false`), plus `[(selectedId)]` model binding and a `tabChange` output (`{ tabId }`).
|
|
10
|
+
|
|
11
|
+
## Layouts
|
|
12
|
+
|
|
13
|
+
| `layout` (default `'underline'`) | Selector | Description |
|
|
14
|
+
| -------------------------------- | ------------------------- | ----------------------------------------------------------------------------------------------------------------------------------- |
|
|
15
|
+
| `'underline'` | `smartpro-tabs-underline` | Horizontal nav with a per-tab underline indicator. Adapts via `fullWidth?`, `inBar?`, `bare?`, plus per-item `iconTpl?` / `badge?`. |
|
|
16
|
+
| `'pills'` | `smartpro-tabs-pills` | Pill-shaped tabs. Active background controlled by `background?: 'transparent' \| 'gray' \| 'brand'`. |
|
|
17
|
+
|
|
18
|
+
### Underline modifiers
|
|
19
|
+
|
|
20
|
+
`options.fullWidth: true` — anchors stretch to fill the nav row (`flex-1`).
|
|
21
|
+
`options.inBar: true` — boxed bar with dividers, shadow, and a per-tab underline indicator.
|
|
22
|
+
`options.bare: true` — wraps the nav in a bg-white container with `max-w-7xl` and renders minimal text tabs without the underline indicator.
|
|
23
|
+
Per-item: set `item.iconTpl` to render an icon before the label; set `item.badge` to render a count pill after the label.
|
|
24
|
+
|
|
25
|
+
### Pills modifiers
|
|
26
|
+
|
|
27
|
+
`options.background: 'transparent'` (default) — gray-100 active pill.
|
|
28
|
+
`options.background: 'gray'` — gray-200 active pill, intended for use on lighter gray surfaces.
|
|
29
|
+
`options.background: 'brand'` — indigo-100 active pill.
|
|
30
|
+
|
|
31
|
+
## API
|
|
32
|
+
|
|
33
|
+
### ITabsOptionsPro (`tabs.types.ts`, extends `ITabsOptions`)
|
|
34
|
+
|
|
35
|
+
```typescript
|
|
36
|
+
type SmartTabsLayoutPro = 'underline' | 'pills';
|
|
37
|
+
type SmartTabsPillsBackground = 'transparent' | 'gray' | 'brand';
|
|
38
|
+
|
|
39
|
+
interface ITabsOptionsPro {
|
|
40
|
+
layout?: SmartTabsLayoutPro;
|
|
41
|
+
items?: ITabItem[];
|
|
42
|
+
ariaLabel?: string;
|
|
43
|
+
showMobileSelect?: boolean;
|
|
44
|
+
fullWidth?: boolean;
|
|
45
|
+
inBar?: boolean;
|
|
46
|
+
bare?: boolean;
|
|
47
|
+
background?: SmartTabsPillsBackground;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
interface ITabItem {
|
|
51
|
+
id: string;
|
|
52
|
+
label?: string;
|
|
53
|
+
href?: string;
|
|
54
|
+
badge?: string | number;
|
|
55
|
+
iconTpl?: TemplateRef<unknown>;
|
|
56
|
+
}
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
### Wrapper Inputs
|
|
60
|
+
|
|
61
|
+
| Input | Type | Default | Description |
|
|
62
|
+
| ------------ | ------------------------------ | ----------- | ------------------------- |
|
|
63
|
+
| `options` | `ITabsOptionsPro \| undefined` | `undefined` | Items, layout, modifiers. |
|
|
64
|
+
| `selectedId` | `string \| null` (model) | `null` | Two-way bound active tab. |
|
|
65
|
+
| `class` | `string` | `''` | Extra CSS classes. |
|
|
66
|
+
|
|
67
|
+
Output: `tabChange: ITabChange` (`{ tabId }`).
|
|
68
|
+
|
|
69
|
+
## Usage Example
|
|
70
|
+
|
|
71
|
+
```html
|
|
72
|
+
<!-- Default underline -->
|
|
73
|
+
<smartpro-tabs
|
|
74
|
+
[options]="{
|
|
75
|
+
items: [
|
|
76
|
+
{ id: 'account', label: 'My Account' },
|
|
77
|
+
{ id: 'team', label: 'Team Members', badge: 4 }
|
|
78
|
+
]
|
|
79
|
+
}"
|
|
80
|
+
[(selectedId)]="active"
|
|
81
|
+
(tabChange)="onChange($event)"
|
|
82
|
+
/>
|
|
83
|
+
|
|
84
|
+
<!-- Bar with underline -->
|
|
85
|
+
<smartpro-tabs [options]="{ items, inBar: true }" [(selectedId)]="active" />
|
|
86
|
+
|
|
87
|
+
<!-- Brand pills -->
|
|
88
|
+
<smartpro-tabs
|
|
89
|
+
[options]="{ items, layout: 'pills', background: 'brand' }"
|
|
90
|
+
[(selectedId)]="active"
|
|
91
|
+
/>
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
## File Locations
|
|
95
|
+
|
|
96
|
+
- Wrapper: `packages/shared/angular/src/lib/components/tabs/tabs.component.ts`
|
|
97
|
+
- Types: `packages/shared/angular/src/lib/components/tabs/tabs.types.ts`
|
|
98
|
+
- Layouts: `packages/shared/angular/src/lib/components/tabs/{underline,pills}/<name>.component.ts`
|
|
99
|
+
- Stories: `packages/shared/angular/src/lib/components/tabs/tabs.component.stories.ts`
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: angular-components-textarea
|
|
3
|
+
description: Textarea component for @smartsoft001/pro-angular. Two variants — `simple` (with `borderStyle?` and `withPreview?` flags) and `with-actions` (with `actionStyle: 'avatar' | 'pill'`). Renders a labeled textarea with optional toolbar / actions / preview.
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Textarea Component (Pro)
|
|
8
|
+
|
|
9
|
+
Use `<smartpro-textarea>` and pick a variant via `options.variant`. The component reads `ITextareaOptionsPro` for label, name, rows, max-length, actions list, optional `avatarTpl` / `toolbarTpl` / `previewTpl`. Two-way `[(value)]` binding tracks the textarea content; `actionClick` fires when an action button is pressed.
|
|
10
|
+
|
|
11
|
+
## Variants
|
|
12
|
+
|
|
13
|
+
| `options.variant` (default `'simple'`) | Selector | Description |
|
|
14
|
+
| -------------------------------------- | -------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
15
|
+
| `'simple'` | `smartpro-textarea-simple` | Single textarea with optional label. `options.borderStyle: 'underline'` switches to a bottom-border-on-focus look with avatar + actions row. `options.withPreview: true` adds Write / Preview tabs above the textarea (plus a primary submit action below). |
|
|
16
|
+
| `'with-actions'` | `smartpro-textarea-with-actions` | Textarea with action bar. `options.actionStyle: 'avatar'` (default) shows avatar + textarea + inline action row. `options.actionStyle: 'pill'` shows a title input + textarea + pill-style secondary actions and a primary submit action with a divider. |
|
|
17
|
+
|
|
18
|
+
## API
|
|
19
|
+
|
|
20
|
+
### ITextareaOptionsPro (`textarea.types.ts`, omits + redefines `variant`)
|
|
21
|
+
|
|
22
|
+
```typescript
|
|
23
|
+
type SmartTextareaVariantPro = 'simple' | 'with-actions';
|
|
24
|
+
|
|
25
|
+
interface ITextareaOptionsPro {
|
|
26
|
+
variant?: SmartTextareaVariantPro;
|
|
27
|
+
label?: string;
|
|
28
|
+
name?: string;
|
|
29
|
+
rows?: number;
|
|
30
|
+
maxLength?: number;
|
|
31
|
+
required?: boolean;
|
|
32
|
+
ariaLabel?: string;
|
|
33
|
+
avatarTpl?: TemplateRef<unknown>;
|
|
34
|
+
toolbarTpl?: TemplateRef<unknown>;
|
|
35
|
+
previewTpl?: TemplateRef<unknown>;
|
|
36
|
+
actions?: ITextareaAction[];
|
|
37
|
+
borderStyle?: 'box' | 'underline';
|
|
38
|
+
withPreview?: boolean;
|
|
39
|
+
actionStyle?: 'avatar' | 'pill';
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
interface ITextareaAction {
|
|
43
|
+
id: string;
|
|
44
|
+
label: string;
|
|
45
|
+
variant?: 'primary' | 'secondary' | 'ghost';
|
|
46
|
+
iconTpl?: TemplateRef<unknown>;
|
|
47
|
+
}
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
### Wrapper Inputs
|
|
51
|
+
|
|
52
|
+
| Input | Type | Default | Description |
|
|
53
|
+
| ------------- | ---------------------------------- | ----------- | ---------------------------------- |
|
|
54
|
+
| `options` | `ITextareaOptionsPro \| undefined` | `undefined` | Variant + label + actions + flags. |
|
|
55
|
+
| `value` | `string` (model) | `''` | Two-way bound textarea content. |
|
|
56
|
+
| `placeholder` | `string` | `''` | Native placeholder. |
|
|
57
|
+
| `disabled` | `boolean` | `false` | Disable textarea + actions. |
|
|
58
|
+
| `class` | `string` | `''` | Extra CSS classes. |
|
|
59
|
+
|
|
60
|
+
Output: `actionClick: ITextareaActionClick` (`{ actionId, value }`).
|
|
61
|
+
|
|
62
|
+
## Usage Example
|
|
63
|
+
|
|
64
|
+
```html
|
|
65
|
+
<!-- Simple textarea -->
|
|
66
|
+
<smartpro-textarea
|
|
67
|
+
[options]="{ label: 'Comment', name: 'comment' }"
|
|
68
|
+
[(value)]="comment"
|
|
69
|
+
></smartpro-textarea>
|
|
70
|
+
|
|
71
|
+
<!-- With underline border + avatar + actions -->
|
|
72
|
+
<smartpro-textarea
|
|
73
|
+
[options]="{
|
|
74
|
+
variant: 'simple',
|
|
75
|
+
borderStyle: 'underline',
|
|
76
|
+
avatarTpl: avatar,
|
|
77
|
+
actions: [{ id: 'post', label: 'Post', variant: 'primary' }]
|
|
78
|
+
}"
|
|
79
|
+
[(value)]="comment"
|
|
80
|
+
(actionClick)="onAction($event)"
|
|
81
|
+
></smartpro-textarea>
|
|
82
|
+
|
|
83
|
+
<!-- With write / preview tabs -->
|
|
84
|
+
<smartpro-textarea
|
|
85
|
+
[options]="{
|
|
86
|
+
variant: 'simple',
|
|
87
|
+
withPreview: true,
|
|
88
|
+
actions: [{ id: 'post', label: 'Post', variant: 'primary' }]
|
|
89
|
+
}"
|
|
90
|
+
[(value)]="comment"
|
|
91
|
+
></smartpro-textarea>
|
|
92
|
+
|
|
93
|
+
<!-- With avatar + actions row -->
|
|
94
|
+
<smartpro-textarea
|
|
95
|
+
[options]="{ variant: 'with-actions', avatarTpl: avatar, actions }"
|
|
96
|
+
[(value)]="comment"
|
|
97
|
+
></smartpro-textarea>
|
|
98
|
+
|
|
99
|
+
<!-- With pill actions -->
|
|
100
|
+
<smartpro-textarea
|
|
101
|
+
[options]="{ variant: 'with-actions', actionStyle: 'pill', actions }"
|
|
102
|
+
[(value)]="comment"
|
|
103
|
+
></smartpro-textarea>
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
## File Locations
|
|
107
|
+
|
|
108
|
+
- Wrapper: `packages/shared/angular/src/lib/components/textarea/textarea.component.ts`
|
|
109
|
+
- Types: `packages/shared/angular/src/lib/components/textarea/textarea.types.ts`
|
|
110
|
+
- Variants: `packages/shared/angular/src/lib/components/textarea/{simple,with-actions}/<name>.component.ts`
|
|
111
|
+
- Stories: `packages/shared/angular/src/lib/components/textarea/textarea.component.stories.ts`
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: angular-components-toggle
|
|
3
|
+
description: Toggle component for @smartsoft001/pro-angular. Two layouts (simple, with-labels), optional `size` (standard/short) and built-in `withIcon`, configurable label position, dark/light mode.
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Toggle Component (Pro)
|
|
8
|
+
|
|
9
|
+
Use `<smartpro-toggle>`. The wrapper picks one of two child layouts based on whether labels are provided in `options`. Within either layout, the toggle's appearance is shaped by `options.size` and `options.withIcon`.
|
|
10
|
+
|
|
11
|
+
## Layouts
|
|
12
|
+
|
|
13
|
+
| `variant` (auto-detected) | Selector | Description |
|
|
14
|
+
| ------------------------- | ----------------------------- | ----------------------------------------------------------------------------------------------------------------------- |
|
|
15
|
+
| `'simple'` | `smartpro-toggle-simple` | Bare switch, no label or description rendered. Use when the toggle stands alone (e.g., next to its own external label). |
|
|
16
|
+
| `'with-labels'` | `smartpro-toggle-with-labels` | Switch + label + optional description, with `labelPosition` honored. |
|
|
17
|
+
|
|
18
|
+
The wrapper auto-selects `'with-labels'` when `options.label` or `options.description` is set; otherwise `'simple'`. Pass an explicit `variant` input to override the auto-detection.
|
|
19
|
+
|
|
20
|
+
## Sizes & Icons
|
|
21
|
+
|
|
22
|
+
`options.size` selects the geometry, available in both layouts:
|
|
23
|
+
|
|
24
|
+
- `'standard'` (default) — full-width pill (`w-11`) with a white knob.
|
|
25
|
+
- `'short'` — compact rail (`h-5 w-10`) with a knob that rides over the track.
|
|
26
|
+
|
|
27
|
+
`options.withIcon: true` renders the built-in X / ✓ icons inside the knob (only meaningful for `size: 'standard'`).
|
|
28
|
+
|
|
29
|
+
## API
|
|
30
|
+
|
|
31
|
+
### IToggleOptionsPro (`toggle.types.ts`, extends `IToggleOptions`)
|
|
32
|
+
|
|
33
|
+
```typescript
|
|
34
|
+
type SmartTogglePro = 'simple' | 'with-labels';
|
|
35
|
+
type SmartToggleSize = 'standard' | 'short';
|
|
36
|
+
|
|
37
|
+
interface IToggleOptionsPro {
|
|
38
|
+
size?: SmartToggleSize; // 'standard' (default) | 'short'
|
|
39
|
+
withIcon?: boolean; // default false
|
|
40
|
+
label?: string;
|
|
41
|
+
description?: string;
|
|
42
|
+
labelPosition?: 'left' | 'right'; // 'left' (default) — used by with-labels
|
|
43
|
+
ariaLabel?: string;
|
|
44
|
+
}
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
### Wrapper Inputs
|
|
48
|
+
|
|
49
|
+
| Input | Type | Default | Description |
|
|
50
|
+
| ---------- | ---------------------------------------- | ----------- | ----------------------------------------------------------------------------------- |
|
|
51
|
+
| `value` | `boolean` (model — two-way) | `false` | Toggle state. Bind with `[(value)]`. |
|
|
52
|
+
| `variant` | `'simple' \| 'with-labels' \| undefined` | `undefined` | Forces a layout; when `undefined`, auto-detects from `options.label`/`description`. |
|
|
53
|
+
| `disabled` | `boolean` | `false` | Disables the toggle. |
|
|
54
|
+
| `options` | `IToggleOptionsPro \| undefined` | `undefined` | Size, icon, label, description, label position, aria-label. |
|
|
55
|
+
| `class` | `string` | `''` | Extra CSS classes appended to the toggle wrapper. |
|
|
56
|
+
|
|
57
|
+
## Usage Examples
|
|
58
|
+
|
|
59
|
+
```html
|
|
60
|
+
<!-- Bare toggle -->
|
|
61
|
+
<smartpro-toggle [(value)]="enabled" [options]="{ ariaLabel: 'Use setting' }" />
|
|
62
|
+
|
|
63
|
+
<!-- Short toggle -->
|
|
64
|
+
<smartpro-toggle
|
|
65
|
+
[(value)]="compact"
|
|
66
|
+
[options]="{ size: 'short', ariaLabel: 'Compact' }"
|
|
67
|
+
/>
|
|
68
|
+
|
|
69
|
+
<!-- With X / ✓ icons inside the knob -->
|
|
70
|
+
<smartpro-toggle
|
|
71
|
+
[(value)]="active"
|
|
72
|
+
[options]="{ withIcon: true, ariaLabel: 'Active' }"
|
|
73
|
+
/>
|
|
74
|
+
|
|
75
|
+
<!-- Left label + description -->
|
|
76
|
+
<smartpro-toggle
|
|
77
|
+
[(value)]="available"
|
|
78
|
+
[options]="{
|
|
79
|
+
label: 'Available to hire',
|
|
80
|
+
description: 'Nulla amet tempus sit accumsan.',
|
|
81
|
+
labelPosition: 'left'
|
|
82
|
+
}"
|
|
83
|
+
/>
|
|
84
|
+
|
|
85
|
+
<!-- Right label + description -->
|
|
86
|
+
<smartpro-toggle
|
|
87
|
+
[(value)]="annual"
|
|
88
|
+
[options]="{
|
|
89
|
+
label: 'Annual billing',
|
|
90
|
+
description: '(Save 10%)',
|
|
91
|
+
labelPosition: 'right'
|
|
92
|
+
}"
|
|
93
|
+
/>
|
|
94
|
+
|
|
95
|
+
<!-- Disabled -->
|
|
96
|
+
<smartpro-toggle
|
|
97
|
+
[(value)]="locked"
|
|
98
|
+
[options]="{ ariaLabel: 'Locked' }"
|
|
99
|
+
[disabled]="true"
|
|
100
|
+
/>
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
## File Locations
|
|
104
|
+
|
|
105
|
+
- Wrapper: `packages/shared/angular/src/lib/components/toggle/toggle.component.ts`
|
|
106
|
+
- Types: `packages/shared/angular/src/lib/components/toggle/toggle.types.ts`
|
|
107
|
+
- Layouts: `packages/shared/angular/src/lib/components/toggle/{simple,with-labels}/<name>.component.ts`
|
|
108
|
+
- Shared class utilities: `packages/shared/angular/src/lib/components/toggle/toggle-classes.util.ts`
|
|
109
|
+
- Stories: `packages/shared/angular/src/lib/components/toggle/toggle.component.stories.ts`
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: angular-components-vertical-navigation
|
|
3
|
+
description: Vertical navigation component for @smartsoft001/pro-angular. Three layouts (flat, on-gray, with-secondary-navigation). Flat iterates `options.items` and renders optional per-item `iconTpl` / `badge`. The other two iterate `options.groups` for multi-section navigation.
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Vertical Navigation Component (Pro)
|
|
8
|
+
|
|
9
|
+
Use `<smartpro-vertical-navigation>`. Pick a layout via `options.layout`. The component reads either `options.items` (flat) or `options.groups` (grouped) depending on the layout, and emits `itemClick` when a link is clicked.
|
|
10
|
+
|
|
11
|
+
## Layouts
|
|
12
|
+
|
|
13
|
+
| `options.layout` (default `'flat'`) | Selector | Data | Description |
|
|
14
|
+
| ----------------------------------- | -------------------------------------------------------- | ----------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
15
|
+
| `'flat'` | `smartpro-vertical-navigation-flat` | `items[]` | Flat link list. Per-item `iconTpl` and `badge` are optional — render only when set on the item. Item padding tightens to `p-2` when `iconTpl` is present and expands to `p-2 pl-3` when not, so icon-less and icon-bearing rows align consistently. |
|
|
16
|
+
| `'on-gray'` | `smartpro-vertical-navigation-on-gray` | `groups[]` or `items[]` | Multi-section navigation styled for a gray background. Each group can have a `title` and a list of items. Items support `initial` (single-letter chip) when no `iconTpl` is given. |
|
|
17
|
+
| `'with-secondary-navigation'` | `smartpro-vertical-navigation-with-secondary-navigation` | `groups[]` or `items[]` | Like `on-gray` but tuned for the standard light sidebar shell. Same group/item shape. |
|
|
18
|
+
|
|
19
|
+
## API
|
|
20
|
+
|
|
21
|
+
### IVerticalNavOptionsPro (`vertical-navigation.types.ts`, extends `IVerticalNavOptions`)
|
|
22
|
+
|
|
23
|
+
```typescript
|
|
24
|
+
type SmartVerticalNavLayoutPro =
|
|
25
|
+
| 'flat'
|
|
26
|
+
| 'on-gray'
|
|
27
|
+
| 'with-secondary-navigation';
|
|
28
|
+
|
|
29
|
+
interface IVerticalNavOptionsPro {
|
|
30
|
+
layout?: SmartVerticalNavLayoutPro;
|
|
31
|
+
ariaLabel?: string;
|
|
32
|
+
items?: IVerticalNavItem[]; // used by 'flat'
|
|
33
|
+
groups?: IVerticalNavGroup[]; // used by 'on-gray' and 'with-secondary-navigation'
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
interface IVerticalNavGroup {
|
|
37
|
+
id?: string;
|
|
38
|
+
title?: string;
|
|
39
|
+
items: IVerticalNavItem[];
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
interface IVerticalNavItem {
|
|
43
|
+
id: string;
|
|
44
|
+
label?: string;
|
|
45
|
+
href?: string;
|
|
46
|
+
current?: boolean;
|
|
47
|
+
badge?: string | number;
|
|
48
|
+
iconTpl?: TemplateRef<unknown>;
|
|
49
|
+
initial?: string;
|
|
50
|
+
}
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
### Wrapper Inputs / Outputs
|
|
54
|
+
|
|
55
|
+
| Input / Output | Type | Description |
|
|
56
|
+
| -------------- | ------------------------------------- | ------------------------------------------------ |
|
|
57
|
+
| `options` | `IVerticalNavOptionsPro \| undefined` | Layout, items or groups, ARIA label. |
|
|
58
|
+
| `class` | `string` | Extra CSS classes appended to the outer `<nav>`. |
|
|
59
|
+
| `itemClick` | `{ itemId: string }` | Emitted when an item link is clicked. |
|
|
60
|
+
|
|
61
|
+
## Usage
|
|
62
|
+
|
|
63
|
+
### Flat list
|
|
64
|
+
|
|
65
|
+
```html
|
|
66
|
+
<smartpro-vertical-navigation
|
|
67
|
+
[options]="{
|
|
68
|
+
items: [
|
|
69
|
+
{ id: 'dashboard', label: 'Dashboard', href: '/', current: true },
|
|
70
|
+
{ id: 'team', label: 'Team', href: '/team' }
|
|
71
|
+
]
|
|
72
|
+
}"
|
|
73
|
+
(itemClick)="onItem($event)"
|
|
74
|
+
/>
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
### Flat list with badges
|
|
78
|
+
|
|
79
|
+
```html
|
|
80
|
+
<smartpro-vertical-navigation
|
|
81
|
+
[options]="{
|
|
82
|
+
items: [
|
|
83
|
+
{ id: 'dashboard', label: 'Dashboard', href: '/', current: true, badge: 5 },
|
|
84
|
+
{ id: 'projects', label: 'Projects', href: '/projects', badge: 12 }
|
|
85
|
+
]
|
|
86
|
+
}"
|
|
87
|
+
/>
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
### Flat list with icons
|
|
91
|
+
|
|
92
|
+
```html
|
|
93
|
+
<smartpro-vertical-navigation
|
|
94
|
+
[options]="{
|
|
95
|
+
items: [
|
|
96
|
+
{ id: 'dashboard', label: 'Dashboard', href: '/', current: true, iconTpl: dashboardIcon },
|
|
97
|
+
{ id: 'team', label: 'Team', href: '/team', iconTpl: teamIcon }
|
|
98
|
+
]
|
|
99
|
+
}"
|
|
100
|
+
/>
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
### Grouped (on-gray)
|
|
104
|
+
|
|
105
|
+
```html
|
|
106
|
+
<smartpro-vertical-navigation
|
|
107
|
+
[options]="{
|
|
108
|
+
layout: 'on-gray',
|
|
109
|
+
groups: [
|
|
110
|
+
{ items: [{ id: 'dashboard', label: 'Dashboard', href: '/', current: true }] },
|
|
111
|
+
{
|
|
112
|
+
title: 'Projects',
|
|
113
|
+
items: [
|
|
114
|
+
{ id: 'web', label: 'Website redesign', href: '/web', initial: 'W' },
|
|
115
|
+
{ id: 'graphql', label: 'GraphQL API', href: '/graphql', initial: 'G' }
|
|
116
|
+
]
|
|
117
|
+
}
|
|
118
|
+
]
|
|
119
|
+
}"
|
|
120
|
+
/>
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
### Grouped (with secondary navigation)
|
|
124
|
+
|
|
125
|
+
```html
|
|
126
|
+
<smartpro-vertical-navigation
|
|
127
|
+
[options]="{
|
|
128
|
+
layout: 'with-secondary-navigation',
|
|
129
|
+
groups: [...]
|
|
130
|
+
}"
|
|
131
|
+
/>
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
## File Locations
|
|
135
|
+
|
|
136
|
+
- Wrapper: `packages/shared/angular/src/lib/components/vertical-navigation/vertical-navigation.component.ts`
|
|
137
|
+
- Types: `packages/shared/angular/src/lib/components/vertical-navigation/vertical-navigation.types.ts`
|
|
138
|
+
- Layouts: `packages/shared/angular/src/lib/components/vertical-navigation/{flat,on-gray,with-secondary-navigation}/<name>.component.ts`
|
|
139
|
+
- Stories: `packages/shared/angular/src/lib/components/vertical-navigation/vertical-navigation.component.stories.ts`
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: audit-log
|
|
3
|
+
description: Query and analyze Claude Code audit logs
|
|
4
|
+
user-invocable: true
|
|
5
|
+
allowed-tools: Bash, Read, Grep, Glob
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# Audit Log
|
|
9
|
+
|
|
10
|
+
Query and analyze the Claude Code audit trail stored in `.claude/audit_logs/`.
|
|
11
|
+
|
|
12
|
+
## Purpose
|
|
13
|
+
|
|
14
|
+
Provide easy access to audit logs that track all Claude Code actions, including tool usage, prompt submissions, and session activity.
|
|
15
|
+
|
|
16
|
+
## When to Use
|
|
17
|
+
|
|
18
|
+
Use `/smart:audit-log` when you need to:
|
|
19
|
+
|
|
20
|
+
- Review what actions Claude took during a session
|
|
21
|
+
- Debug unexpected behavior by checking the audit trail
|
|
22
|
+
- Verify that safety validators blocked dangerous commands
|
|
23
|
+
- Analyze tool usage patterns
|
|
24
|
+
|
|
25
|
+
## Arguments
|
|
26
|
+
|
|
27
|
+
```
|
|
28
|
+
/smart:audit-log [today|yesterday|YYYYMMDD]
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
- **today** (default) — Show today's audit log
|
|
32
|
+
- **yesterday** — Show yesterday's audit log
|
|
33
|
+
- **YYYYMMDD** — Show log for a specific date (e.g., `20260210`)
|
|
34
|
+
|
|
35
|
+
## Log Location
|
|
36
|
+
|
|
37
|
+
```
|
|
38
|
+
.claude/audit_logs/YYYYMMDD_audit.jsonl
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
Each line is a JSON object with:
|
|
42
|
+
|
|
43
|
+
- `timestamp` — ISO 8601 UTC timestamp
|
|
44
|
+
- `event_type` — Hook event (PreToolUse, PostToolUse, UserPromptSubmit, Stop)
|
|
45
|
+
- `session_id` — Unique session identifier
|
|
46
|
+
- `event_data` — Full event payload
|
|
47
|
+
|
|
48
|
+
## Instructions
|
|
49
|
+
|
|
50
|
+
1. Determine the target date from the argument (default: today)
|
|
51
|
+
2. Construct the log file path: `.claude/audit_logs/YYYYMMDD_audit.jsonl`
|
|
52
|
+
3. Check if the file exists using Glob
|
|
53
|
+
4. Read the file and parse JSONL entries
|
|
54
|
+
5. Present a summary:
|
|
55
|
+
- Total events count
|
|
56
|
+
- Breakdown by event type
|
|
57
|
+
- Any blocked actions (exit code 2)
|
|
58
|
+
- Timeline of key actions
|
|
59
|
+
|
|
60
|
+
### Filtering Examples
|
|
61
|
+
|
|
62
|
+
To filter by tool name:
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
grep '"tool_name":"Bash"' .claude/audit_logs/YYYYMMDD_audit.jsonl
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
To filter by event type:
|
|
69
|
+
|
|
70
|
+
```bash
|
|
71
|
+
grep '"event_type":"PreToolUse"' .claude/audit_logs/YYYYMMDD_audit.jsonl
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
To show only blocked actions:
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
grep 'BLOCKED' .claude/audit_logs/YYYYMMDD_audit.jsonl
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
## Output Format
|
|
81
|
+
|
|
82
|
+
Present results as a readable summary table, not raw JSON. Group events chronologically and highlight any safety blocks or errors.
|