@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,86 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: angular-components-paging
|
|
3
|
+
description: Paging variants for @smartsoft001/pro-angular — 3 Tailwind UI templates pluggable into the fork's <smartpro-paging> via PAGING_STANDARD_COMPONENT_TOKEN
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Paging Variants (pro)
|
|
8
|
+
|
|
9
|
+
This package provides three standalone paging variants derived from Tailwind UI. Each variant extends `PagingBaseComponent` from `@smartsoft001/angular` and is meant to replace the fork's default `PagingStandardComponent` by providing `PAGING_STANDARD_COMPONENT_TOKEN`.
|
|
10
|
+
|
|
11
|
+
## When to Use This Skill
|
|
12
|
+
|
|
13
|
+
- Developer wants a specific paging look → pick the matching variant and register it via the DI token
|
|
14
|
+
- Developer asks which paging variants exist → list the 3 components below
|
|
15
|
+
- Developer wants to see all variants → open the `Components / Paging` Storybook entry (4 stories: one per variant + `All Variants`, dark/light toggle via global theme toolbar)
|
|
16
|
+
|
|
17
|
+
## Available Variants
|
|
18
|
+
|
|
19
|
+
| Component | Selector | When to pick it |
|
|
20
|
+
| --------------------------- | ----------------------------- | ----------------------------------------------------------------------------- |
|
|
21
|
+
| `PagingCardFooterComponent` | `smartpro-paging-card-footer` | Card footer with page buttons (desktop) + simple prev/next on mobile |
|
|
22
|
+
| `PagingCenteredComponent` | `smartpro-paging-centered` | Border-top nav with centered page numbers, arrows for prev/next |
|
|
23
|
+
| `PagingSimpleComponent` | `smartpro-paging-simple` | Simple card footer with "Showing X to Y of Z" text and prev/next buttons only |
|
|
24
|
+
|
|
25
|
+
## Registration
|
|
26
|
+
|
|
27
|
+
```typescript
|
|
28
|
+
import { ApplicationConfig } from '@angular/core';
|
|
29
|
+
import { PAGING_STANDARD_COMPONENT_TOKEN } from '@smartsoft001/angular';
|
|
30
|
+
import { PagingCardFooterComponent } from '@smartsoft001/pro-angular';
|
|
31
|
+
|
|
32
|
+
export const appConfig: ApplicationConfig = {
|
|
33
|
+
providers: [
|
|
34
|
+
{
|
|
35
|
+
provide: PAGING_STANDARD_COMPONENT_TOKEN,
|
|
36
|
+
useValue: PagingCardFooterComponent,
|
|
37
|
+
},
|
|
38
|
+
],
|
|
39
|
+
};
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
The fork's `<smartpro-paging>` wrapper reads the token and renders the provided variant. Inputs (`currentPage`, `totalPages`, `pageSize`, `totalItems`, `class`) are forwarded and the `(pageChange)` output bubbles up through the wrapper.
|
|
43
|
+
|
|
44
|
+
## Consumer API (inherited from `PagingBaseComponent`)
|
|
45
|
+
|
|
46
|
+
| Input | Type | Default | Description |
|
|
47
|
+
| ------------- | --------------- | --------------- | ----------------------------- |
|
|
48
|
+
| `currentPage` | `number` | `1` | Current active page |
|
|
49
|
+
| `totalPages` | `number` | `1` | Total number of pages |
|
|
50
|
+
| `pageSize` | `number` | `10` | Items per page |
|
|
51
|
+
| `totalItems` | `number` | `0` | Total number of items |
|
|
52
|
+
| `variant` | `PagingVariant` | `'card-footer'` | Informational hint |
|
|
53
|
+
| `class` | `string` | `''` | Extra CSS classes on the root |
|
|
54
|
+
|
|
55
|
+
| Output | Type | Description |
|
|
56
|
+
| ------------ | -------- | ----------------------------- |
|
|
57
|
+
| `pageChange` | `number` | Emits the requested page num. |
|
|
58
|
+
|
|
59
|
+
## Dark/Light Mode
|
|
60
|
+
|
|
61
|
+
Every variant uses the `smart:` Tailwind prefix with paired `smart:dark:*` classes. Storybook exposes a global theme toolbar (`light` / `dark`) defined in `.storybook/preview.ts` — stories render in whichever mode the toolbar is set to.
|
|
62
|
+
|
|
63
|
+
## i18n Keys
|
|
64
|
+
|
|
65
|
+
Variants use `TranslatePipe` for the following keys — provide translations in the consuming app:
|
|
66
|
+
|
|
67
|
+
| Key | Fallback context |
|
|
68
|
+
| ---------------- | ---------------------- |
|
|
69
|
+
| `prev` | "Previous" button text |
|
|
70
|
+
| `next` | "Next" button text |
|
|
71
|
+
| `paging.showing` | "Showing" |
|
|
72
|
+
| `paging.to` | "to" |
|
|
73
|
+
| `paging.of` | "of" |
|
|
74
|
+
| `paging.results` | "results" |
|
|
75
|
+
|
|
76
|
+
## File Locations
|
|
77
|
+
|
|
78
|
+
- Variants: `packages/shared/angular/src/lib/components/paging/<variant>/`
|
|
79
|
+
- Barrel: `packages/shared/angular/src/lib/components/paging/index.ts` — exports all 3 components
|
|
80
|
+
- Stories: `packages/shared/angular/src/lib/components/paging/paging.component.stories.ts` (4 stories + First/Last/Few extras)
|
|
81
|
+
- Module registration: `packages/shared/angular/src/lib/components/components.module.ts`
|
|
82
|
+
- Base class + `PAGING_STANDARD_COMPONENT_TOKEN`: re-exported from `@smartsoft001/angular`
|
|
83
|
+
|
|
84
|
+
## Tailwind Classes
|
|
85
|
+
|
|
86
|
+
All classes use `smart:` prefix. Card Footer variant is the richest with numeric page buttons + ellipsis; Centered uses border-top and flat nav; Simple shows only a count line and prev/next buttons. Switching variants by provider requires no template change in the consuming component.
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: angular-components-progress-bars
|
|
3
|
+
description: Progress bars component for @smartsoft001/pro-angular. Four layouts (bar, bullets, circles, panels). The bar layout auto-detects between numeric (`options.value`) and step-based rendering; bullets/circles accept `withText?`; panels accepts `bordered?`.
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Progress Bars Component (Pro)
|
|
8
|
+
|
|
9
|
+
Use `<smartpro-progress-bars>` and pick a layout via `options.layout`. The component reads `IProgressBarsOptionsPro` and renders one of four visualizations. Step-based layouts iterate `options.steps` (with statuses `'complete' | 'current' | 'upcoming'`); the numeric `bar` layout reads `options.value` (0-100).
|
|
10
|
+
|
|
11
|
+
## Layouts
|
|
12
|
+
|
|
13
|
+
| `layout` (default `'bar'`) | Selector | Description |
|
|
14
|
+
| -------------------------- | -------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
15
|
+
| `'bar'` | `smartpro-progress-bars-bar` | Auto-adapts. When `options.value` is set, renders a numeric percentage bar with optional `options.columns` labels; otherwise renders a step-bar (steps as colored vertical/horizontal borders with index + name). |
|
|
16
|
+
| `'bullets'` | `smartpro-progress-bars-bullets` | Compact dots showing progress. Default places them inline next to a "Step X of Y" label. `options.withText: true` switches to a vertical list with each step's name next to its bullet. |
|
|
17
|
+
| `'circles'` | `smartpro-progress-bars-circles` | Numbered circles connected by lines. Default is a horizontal bar; `options.withText: true` switches to a vertical list with each step's name and description next to the circle. |
|
|
18
|
+
| `'panels'` | `smartpro-progress-bars-panels` | Large numbered panels with status colors. Default has dividers between panels (`md:flex` + chevron arrows). `options.bordered: true` switches to the side-bar bordered panel layout (`lg:flex` + side stripe + path arrows; wraps in `mx-auto max-w-7xl`). |
|
|
19
|
+
|
|
20
|
+
## API
|
|
21
|
+
|
|
22
|
+
### IProgressBarsOptionsPro (`progress-bars.types.ts`)
|
|
23
|
+
|
|
24
|
+
```typescript
|
|
25
|
+
type SmartProgressBarsLayoutPro = 'bar' | 'bullets' | 'circles' | 'panels';
|
|
26
|
+
|
|
27
|
+
interface IProgressBarsOptionsPro {
|
|
28
|
+
layout?: SmartProgressBarsLayoutPro;
|
|
29
|
+
steps?: IProgressStep[];
|
|
30
|
+
value?: number; // 0–100, used by bar layout
|
|
31
|
+
columns?: IProgressBarColumn[]; // bar layout only
|
|
32
|
+
title?: string;
|
|
33
|
+
ariaLabel?: string;
|
|
34
|
+
srOnlyTitle?: string;
|
|
35
|
+
withText?: boolean; // bullets / circles only
|
|
36
|
+
bordered?: boolean; // panels only
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
interface IProgressStep {
|
|
40
|
+
id: string;
|
|
41
|
+
name: string;
|
|
42
|
+
description?: string;
|
|
43
|
+
status: 'complete' | 'current' | 'upcoming';
|
|
44
|
+
index?: string;
|
|
45
|
+
href?: string;
|
|
46
|
+
}
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
### Wrapper Inputs
|
|
50
|
+
|
|
51
|
+
| Input | Type | Default | Description |
|
|
52
|
+
| --------- | -------------------------------------- | ----------- | --------------------- |
|
|
53
|
+
| `options` | `IProgressBarsOptionsPro \| undefined` | `undefined` | Layout + steps/value. |
|
|
54
|
+
| `class` | `string` | `''` | Extra CSS classes. |
|
|
55
|
+
|
|
56
|
+
Output: `stepClick: IProgressStepClick` (`{ stepId }`).
|
|
57
|
+
|
|
58
|
+
## Usage Example
|
|
59
|
+
|
|
60
|
+
```html
|
|
61
|
+
<!-- Numeric bar with column labels -->
|
|
62
|
+
<smartpro-progress-bars
|
|
63
|
+
[options]="{
|
|
64
|
+
title: 'Migrating database…',
|
|
65
|
+
value: 38,
|
|
66
|
+
columns: [
|
|
67
|
+
{ label: 'Copying files', active: true },
|
|
68
|
+
{ label: 'Migrating database', active: true },
|
|
69
|
+
{ label: 'Compiling assets' },
|
|
70
|
+
{ label: 'Deployed' }
|
|
71
|
+
]
|
|
72
|
+
}"
|
|
73
|
+
></smartpro-progress-bars>
|
|
74
|
+
|
|
75
|
+
<!-- Step-based bar -->
|
|
76
|
+
<smartpro-progress-bars [options]="{ steps }"></smartpro-progress-bars>
|
|
77
|
+
|
|
78
|
+
<!-- Vertical bullets with labels -->
|
|
79
|
+
<smartpro-progress-bars
|
|
80
|
+
[options]="{ steps, layout: 'bullets', withText: true }"
|
|
81
|
+
></smartpro-progress-bars>
|
|
82
|
+
|
|
83
|
+
<!-- Bordered panels -->
|
|
84
|
+
<smartpro-progress-bars
|
|
85
|
+
[options]="{ steps, layout: 'panels', bordered: true }"
|
|
86
|
+
></smartpro-progress-bars>
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
## File Locations
|
|
90
|
+
|
|
91
|
+
- Wrapper: `packages/shared/angular/src/lib/components/progress-bars/progress-bars.component.ts`
|
|
92
|
+
- Types: `packages/shared/angular/src/lib/components/progress-bars/progress-bars.types.ts`
|
|
93
|
+
- Variants: `packages/shared/angular/src/lib/components/progress-bars/{bar,bullets,circles,panels}/<name>.component.ts`
|
|
94
|
+
- Stories: `packages/shared/angular/src/lib/components/progress-bars/progress-bars.component.stories.ts`
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: angular-components-searchbar
|
|
3
|
+
description: Searchbar component with grid-based trailing-icon variant, dark/light mode, and optional label for @smartsoft001/pro-angular
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Searchbar Component (Pro)
|
|
8
|
+
|
|
9
|
+
One variant (`trailing-icon`) that extends `SearchbarBaseComponent` from `@smartsoft001/angular` and renders the Tailwind Plus "Input with trailing icon" template faithfully. Supports dark/light mode and an optional label rendered above the input. Registered as a `SEARCHBAR_STANDARD_COMPONENT_TOKEN` provider via `SmartProComponentsModule`, so the fork's `<smartpro-searchbar>` wrapper picks this variant up automatically when the module is imported.
|
|
10
|
+
|
|
11
|
+
## Variants
|
|
12
|
+
|
|
13
|
+
| Component | Selector | Description |
|
|
14
|
+
| -------------------------------- | ---------------------------------- | ---------------------------------------------------------------- |
|
|
15
|
+
| `SearchbarTrailingIconComponent` | `smartpro-searchbar-trailing-icon` | Grid-based input with trailing magnifier icon and optional label |
|
|
16
|
+
|
|
17
|
+
## Token Registration
|
|
18
|
+
|
|
19
|
+
`SmartProComponentsModule` already registers `SEARCHBAR_STANDARD_COMPONENT_TOKEN → SearchbarTrailingIconComponent`. Consumers importing `SmartProComponentsModule` automatically get this variant when using the fork's `<smartpro-searchbar>` wrapper — no additional provider wiring required.
|
|
20
|
+
|
|
21
|
+
```typescript
|
|
22
|
+
import { SmartProComponentsModule } from '@smartsoft001/pro-angular';
|
|
23
|
+
|
|
24
|
+
@NgModule({
|
|
25
|
+
imports: [SmartProComponentsModule],
|
|
26
|
+
})
|
|
27
|
+
export class AppModule {}
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
For cherry-picking, the token can also be provided manually:
|
|
31
|
+
|
|
32
|
+
```typescript
|
|
33
|
+
import { ApplicationConfig } from '@angular/core';
|
|
34
|
+
import { SEARCHBAR_STANDARD_COMPONENT_TOKEN } from '@smartsoft001/angular';
|
|
35
|
+
import { SearchbarTrailingIconComponent } from '@smartsoft001/pro-angular';
|
|
36
|
+
|
|
37
|
+
export const appConfig: ApplicationConfig = {
|
|
38
|
+
providers: [
|
|
39
|
+
{
|
|
40
|
+
provide: SEARCHBAR_STANDARD_COMPONENT_TOKEN,
|
|
41
|
+
useValue: SearchbarTrailingIconComponent,
|
|
42
|
+
},
|
|
43
|
+
],
|
|
44
|
+
};
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
## API
|
|
48
|
+
|
|
49
|
+
### ISearchbarOptions (re-exported from `@smartsoft001/angular`)
|
|
50
|
+
|
|
51
|
+
```typescript
|
|
52
|
+
interface ISearchbarOptions {
|
|
53
|
+
placeholder?: string; // translation key, defaults to 'search'
|
|
54
|
+
label?: string; // translation key rendered above the input (skipped when absent)
|
|
55
|
+
debounceTime?: number; // ms, default 1000
|
|
56
|
+
showToggleButton?: boolean; // render magnifier toggle when show=false
|
|
57
|
+
size?: SmartSize;
|
|
58
|
+
color?: SmartColor;
|
|
59
|
+
}
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
### Inputs
|
|
63
|
+
|
|
64
|
+
| Input | Type | Default | Description |
|
|
65
|
+
| --------- | ------------------- | ---------- | --------------------------------------------------------- |
|
|
66
|
+
| `options` | `ISearchbarOptions` | - | Searchbar configuration (placeholder/label keys, etc.) |
|
|
67
|
+
| `show` | `model<boolean>` | `true` | Whether the input is visible (two-way bindable) |
|
|
68
|
+
| `text` | `model<string>` | _required_ | Current input text (two-way bindable, debounced emission) |
|
|
69
|
+
| `class` | `string` | `''` | External CSS classes forwarded to the input element |
|
|
70
|
+
|
|
71
|
+
Both `show` and `text` are `ModelSignal`s — use `[(show)]` / `[(text)]` for two-way binding.
|
|
72
|
+
|
|
73
|
+
## Usage Examples
|
|
74
|
+
|
|
75
|
+
```html
|
|
76
|
+
<!-- Basic usage via fork wrapper (auto-picks pro variant) -->
|
|
77
|
+
<smartpro-searchbar [(text)]="searchText"></smartpro-searchbar>
|
|
78
|
+
|
|
79
|
+
<!-- With label and custom placeholder -->
|
|
80
|
+
<smartpro-searchbar
|
|
81
|
+
[(text)]="searchText"
|
|
82
|
+
[options]="{ label: 'account.number', placeholder: '000-00-0000' }"
|
|
83
|
+
></smartpro-searchbar>
|
|
84
|
+
|
|
85
|
+
<!-- Hidden with toggle button -->
|
|
86
|
+
<smartpro-searchbar
|
|
87
|
+
[(show)]="isShown"
|
|
88
|
+
[(text)]="searchText"
|
|
89
|
+
[options]="{ showToggleButton: true }"
|
|
90
|
+
></smartpro-searchbar>
|
|
91
|
+
|
|
92
|
+
<!-- With external CSS class -->
|
|
93
|
+
<smartpro-searchbar
|
|
94
|
+
[(text)]="searchText"
|
|
95
|
+
class="smart:max-w-md"
|
|
96
|
+
></smartpro-searchbar>
|
|
97
|
+
|
|
98
|
+
<!-- Direct pro variant (bypasses the fork wrapper) -->
|
|
99
|
+
<smartpro-searchbar-trailing-icon
|
|
100
|
+
[(show)]="isShown"
|
|
101
|
+
[(text)]="searchText"
|
|
102
|
+
[options]="{ label: 'Account number', placeholder: 'search' }"
|
|
103
|
+
></smartpro-searchbar-trailing-icon>
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
## File Locations
|
|
107
|
+
|
|
108
|
+
- Variant: `packages/shared/angular/src/lib/components/searchbar/trailing-icon/trailing-icon.component.ts`
|
|
109
|
+
- Template: `packages/shared/angular/src/lib/components/searchbar/trailing-icon/trailing-icon.component.html`
|
|
110
|
+
- Spec: `packages/shared/angular/src/lib/components/searchbar/trailing-icon/trailing-icon.component.spec.ts`
|
|
111
|
+
- Barrel: `packages/shared/angular/src/lib/components/searchbar/index.ts`
|
|
112
|
+
- Module registration: `packages/shared/angular/src/lib/components/components.module.ts` (`SEARCHBAR_COMPONENTS`, `SEARCHBAR_STANDARD_COMPONENT_TOKEN` provider)
|
|
113
|
+
- Stories: `packages/shared/angular/src/lib/components/searchbar/searchbar.component.stories.ts`
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: angular-components-section-heading
|
|
3
|
+
description: Section heading component for @smartsoft001/pro-angular. One default variant whose layout adapts to provided slots (description, label, actions, badge, input-group); separate with-tabs variant for tabbed section headings. Auto-detects which to render from `options.tabsTpl`.
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Section Heading Component (Pro)
|
|
8
|
+
|
|
9
|
+
Use `<smartpro-section-heading>`. The wrapper picks one of two child layouts:
|
|
10
|
+
|
|
11
|
+
- **`default`** — used when `options.tabsTpl` is not set. The default variant adapts its inner DOM based on which slots are provided.
|
|
12
|
+
- **`with-tabs`** — used when `options.tabsTpl` is set. The tabs layout adapts based on `options.actionsTpl` and `options.inline`.
|
|
13
|
+
|
|
14
|
+
Pass `variant: 'default' | 'with-tabs'` explicitly to override the auto-detection.
|
|
15
|
+
|
|
16
|
+
## Default variant — layout adapts from slots
|
|
17
|
+
|
|
18
|
+
| Provided options | Resulting layout |
|
|
19
|
+
| --------------------------------------------------------------- | -------------------------------------------------------------------------------- |
|
|
20
|
+
| `title` only | Bordered header — just the title. |
|
|
21
|
+
| `title` + `description` (no actions/label/badge) | Title + description stacked. |
|
|
22
|
+
| `title` + `actionsTpl` and/or `inputGroupTpl` | Title + slot row (`sm:flex sm:items-center sm:justify-between`). |
|
|
23
|
+
| `title` + `label` | Wrapped flex row, title + label aligned to baseline. |
|
|
24
|
+
| `title` + `badgeTpl` (with optional `description`/`actionsTpl`) | Two-column row: title (+ description) on the left, badge + actions on the right. |
|
|
25
|
+
|
|
26
|
+
## With-tabs variant — tabs placement
|
|
27
|
+
|
|
28
|
+
| Provided options | Resulting layout |
|
|
29
|
+
| -------------------------- | ---------------------------------------------------------------------------------------- |
|
|
30
|
+
| `tabsTpl` (default) | Title above; tabs render below the title row, with `pb-5 sm:pb-0` outer. |
|
|
31
|
+
| `tabsTpl` + `actionsTpl` | Title row with absolute-positioned actions on the right at `md:` breakpoint; tabs below. |
|
|
32
|
+
| `tabsTpl` + `inline: true` | Single row: title and tabs side-by-side, baseline-aligned. |
|
|
33
|
+
|
|
34
|
+
`CUSTOM_ELEMENTS_SCHEMA` is set on both variants so consumers can drop `el-dropdown` / `el-menu` from `@tailwindplus/elements` directly into action templates.
|
|
35
|
+
|
|
36
|
+
## API
|
|
37
|
+
|
|
38
|
+
### ISectionHeadingOptionsPro (`section-heading.types.ts`, extends `ISectionHeadingOptions`)
|
|
39
|
+
|
|
40
|
+
```typescript
|
|
41
|
+
type SmartSectionHeadingLayoutPro = 'default' | 'with-tabs';
|
|
42
|
+
|
|
43
|
+
interface ISectionHeadingOptionsPro {
|
|
44
|
+
title?: string;
|
|
45
|
+
description?: string;
|
|
46
|
+
label?: string;
|
|
47
|
+
actionsTpl?: TemplateRef<unknown>;
|
|
48
|
+
tabsTpl?: TemplateRef<unknown>;
|
|
49
|
+
inputGroupTpl?: TemplateRef<unknown>;
|
|
50
|
+
badgeTpl?: TemplateRef<unknown>;
|
|
51
|
+
/** With-tabs only — when true, render tabs inline beside the title. */
|
|
52
|
+
inline?: boolean;
|
|
53
|
+
}
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### Wrapper Inputs
|
|
57
|
+
|
|
58
|
+
| Input | Type | Default | Description |
|
|
59
|
+
| --------- | ---------------------------------------- | ----------- | --------------------------------------------------------------------- |
|
|
60
|
+
| `variant` | `'default' \| 'with-tabs' \| undefined` | `undefined` | Optional override; auto-detected from `options.tabsTpl` when omitted. |
|
|
61
|
+
| `options` | `ISectionHeadingOptionsPro \| undefined` | `undefined` | Title, description, label, slot template refs, `inline`. |
|
|
62
|
+
| `class` | `string` | `''` | Extra CSS classes appended to the outer container. |
|
|
63
|
+
|
|
64
|
+
## Usage Examples
|
|
65
|
+
|
|
66
|
+
```html
|
|
67
|
+
<ng-template #actions>
|
|
68
|
+
<button
|
|
69
|
+
class="smart:rounded-md smart:bg-indigo-600 smart:px-3 smart:py-2 smart:text-white"
|
|
70
|
+
>
|
|
71
|
+
Create
|
|
72
|
+
</button>
|
|
73
|
+
</ng-template>
|
|
74
|
+
<ng-template #inputGroup>
|
|
75
|
+
<input
|
|
76
|
+
class="smart:rounded-md smart:border smart:px-3 smart:py-2"
|
|
77
|
+
placeholder="Search"
|
|
78
|
+
/>
|
|
79
|
+
</ng-template>
|
|
80
|
+
<ng-template #badge>
|
|
81
|
+
<span
|
|
82
|
+
class="smart:inline-flex smart:items-center smart:rounded-full smart:bg-green-100 smart:px-3 smart:py-0.5 smart:text-sm smart:text-green-800"
|
|
83
|
+
>Badge</span
|
|
84
|
+
>
|
|
85
|
+
</ng-template>
|
|
86
|
+
<ng-template #tabs>
|
|
87
|
+
<nav class="smart:-mb-px smart:flex smart:space-x-8">…tabs…</nav>
|
|
88
|
+
</ng-template>
|
|
89
|
+
|
|
90
|
+
<!-- Just a title -->
|
|
91
|
+
<smartpro-section-heading [options]="{ title: 'Job Postings' }" />
|
|
92
|
+
|
|
93
|
+
<!-- Title + description -->
|
|
94
|
+
<smartpro-section-heading
|
|
95
|
+
[options]="{
|
|
96
|
+
title: 'Job Postings',
|
|
97
|
+
description: 'Lorem ipsum...'
|
|
98
|
+
}"
|
|
99
|
+
/>
|
|
100
|
+
|
|
101
|
+
<!-- Title + actions -->
|
|
102
|
+
<smartpro-section-heading
|
|
103
|
+
[options]="{ title: 'Job Postings', actionsTpl: actions }"
|
|
104
|
+
/>
|
|
105
|
+
|
|
106
|
+
<!-- Title + input group -->
|
|
107
|
+
<smartpro-section-heading
|
|
108
|
+
[options]="{ title: 'Job Postings', inputGroupTpl: inputGroup }"
|
|
109
|
+
/>
|
|
110
|
+
|
|
111
|
+
<!-- Title + label (baseline-aligned wrap) -->
|
|
112
|
+
<smartpro-section-heading
|
|
113
|
+
[options]="{ title: 'Job Postings', label: 'in Engineering' }"
|
|
114
|
+
/>
|
|
115
|
+
|
|
116
|
+
<!-- Title + description + badge + actions -->
|
|
117
|
+
<smartpro-section-heading
|
|
118
|
+
[options]="{
|
|
119
|
+
title: 'Job Postings',
|
|
120
|
+
description: 'Lorem ipsum...',
|
|
121
|
+
badgeTpl: badge,
|
|
122
|
+
actionsTpl: actions
|
|
123
|
+
}"
|
|
124
|
+
/>
|
|
125
|
+
|
|
126
|
+
<!-- Tabs below the title -->
|
|
127
|
+
<smartpro-section-heading
|
|
128
|
+
[options]="{ title: 'Job Postings', tabsTpl: tabs }"
|
|
129
|
+
/>
|
|
130
|
+
|
|
131
|
+
<!-- Tabs below + actions on the right -->
|
|
132
|
+
<smartpro-section-heading
|
|
133
|
+
[options]="{
|
|
134
|
+
title: 'Job Postings',
|
|
135
|
+
tabsTpl: tabs,
|
|
136
|
+
actionsTpl: actions
|
|
137
|
+
}"
|
|
138
|
+
/>
|
|
139
|
+
|
|
140
|
+
<!-- Tabs inline next to the title -->
|
|
141
|
+
<smartpro-section-heading
|
|
142
|
+
[options]="{
|
|
143
|
+
title: 'Job Postings',
|
|
144
|
+
tabsTpl: tabs,
|
|
145
|
+
inline: true
|
|
146
|
+
}"
|
|
147
|
+
/>
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
## File Locations
|
|
151
|
+
|
|
152
|
+
- Wrapper: `packages/shared/angular/src/lib/components/section-heading/section-heading.component.ts`
|
|
153
|
+
- Types: `packages/shared/angular/src/lib/components/section-heading/section-heading.types.ts`
|
|
154
|
+
- Layouts: `packages/shared/angular/src/lib/components/section-heading/{default,tabs}/<name>.component.ts`
|
|
155
|
+
- Shared class utilities: `packages/shared/angular/src/lib/components/section-heading/section-heading-classes.util.ts`
|
|
156
|
+
- Stories: `packages/shared/angular/src/lib/components/section-heading/section-heading.component.stories.ts`
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: angular-components-select-menu
|
|
3
|
+
description: Select menu component for @smartsoft001/pro-angular. Two variants — `simple-native` (HTML `<select>`) and `custom` (`<el-select>`-driven listbox with composable flags for secondary text, avatars, status dots, check indicators, branded styling).
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Select Menu Component (Pro)
|
|
8
|
+
|
|
9
|
+
Use `<smartpro-select-menu>` and pick a variant via `variant`. The component reads `ISelectMenuOptionsPro` for items, placeholder, and a set of decoration flags that compose on the custom dropdown. Two-way `[(value)]` binding selects items.
|
|
10
|
+
|
|
11
|
+
## Variants
|
|
12
|
+
|
|
13
|
+
| `variant` (default `'simple-native'`) | Selector | Description |
|
|
14
|
+
| ------------------------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
15
|
+
| `'simple-native'` | `smartpro-select-menu-simple-native` | Native HTML `<select>`. Best a11y and form-integration story. |
|
|
16
|
+
| `'custom'` | `smartpro-select-menu-custom` | `<el-select>` (Tailwind Plus Elements) listbox with composable flags. `branded: true` switches the trigger to an indigo button and renders multi-line items with `item.secondary` below the label. `avatar: true` renders `item.avatarUrl` next to labels. `statusIndicator: true` renders a colored dot from `item.status` (`'online' \| 'busy' \| …`). `checkPosition: 'left'` puts a check on the selected item. `secondaryText: true` renders inline secondary. |
|
|
17
|
+
|
|
18
|
+
## API
|
|
19
|
+
|
|
20
|
+
### ISelectMenuOptionsPro (`select-menu.types.ts`, extends `ISelectMenuOptions`)
|
|
21
|
+
|
|
22
|
+
```typescript
|
|
23
|
+
type SmartSelectMenuVariantPro = 'simple-native' | 'custom';
|
|
24
|
+
|
|
25
|
+
interface ISelectMenuOptionsPro {
|
|
26
|
+
items?: ISelectMenuItem[];
|
|
27
|
+
placeholder?: string;
|
|
28
|
+
secondaryText?: boolean;
|
|
29
|
+
avatar?: boolean;
|
|
30
|
+
statusIndicator?: boolean;
|
|
31
|
+
checkPosition?: 'left' | 'right';
|
|
32
|
+
branded?: boolean;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
interface ISelectMenuItem {
|
|
36
|
+
value: string | number;
|
|
37
|
+
label?: string;
|
|
38
|
+
secondary?: string;
|
|
39
|
+
avatarUrl?: string;
|
|
40
|
+
status?: 'online' | 'busy' | 'offline' | string;
|
|
41
|
+
}
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
### Wrapper Inputs
|
|
45
|
+
|
|
46
|
+
| Input | Type | Default | Description |
|
|
47
|
+
| ---------- | ------------------------------------ | ----------------- | -------------------- |
|
|
48
|
+
| `variant` | `'simple-native' \| 'custom'` | `'simple-native'` | Variant family. |
|
|
49
|
+
| `value` | `SelectMenuValue` (model) | `null` | Two-way bound value. |
|
|
50
|
+
| `disabled` | `boolean` | `false` | Disable the select. |
|
|
51
|
+
| `options` | `ISelectMenuOptionsPro \| undefined` | `undefined` | Items + flags. |
|
|
52
|
+
| `class` | `string` | `''` | Extra CSS classes. |
|
|
53
|
+
|
|
54
|
+
## Tailwind Plus Elements
|
|
55
|
+
|
|
56
|
+
The `custom` variant relies on `<el-select>` / `<el-options>` / `<el-option>` from [`@tailwindplus/elements`](https://www.npmjs.com/package/@tailwindplus/elements). End-user apps must load the package once.
|
|
57
|
+
|
|
58
|
+
## Usage Example
|
|
59
|
+
|
|
60
|
+
```html
|
|
61
|
+
<!-- Native -->
|
|
62
|
+
<smartpro-select-menu
|
|
63
|
+
[options]="{ items, placeholder: 'Select…' }"
|
|
64
|
+
[(value)]="selected"
|
|
65
|
+
></smartpro-select-menu>
|
|
66
|
+
|
|
67
|
+
<!-- Custom dropdown -->
|
|
68
|
+
<smartpro-select-menu
|
|
69
|
+
variant="custom"
|
|
70
|
+
[options]="{ items, placeholder: 'Select…' }"
|
|
71
|
+
[(value)]="selected"
|
|
72
|
+
></smartpro-select-menu>
|
|
73
|
+
|
|
74
|
+
<!-- Custom with avatars -->
|
|
75
|
+
<smartpro-select-menu
|
|
76
|
+
variant="custom"
|
|
77
|
+
[options]="{ items, avatar: true }"
|
|
78
|
+
[(value)]="selected"
|
|
79
|
+
></smartpro-select-menu>
|
|
80
|
+
|
|
81
|
+
<!-- Custom with check on left -->
|
|
82
|
+
<smartpro-select-menu
|
|
83
|
+
variant="custom"
|
|
84
|
+
[options]="{ items, checkPosition: 'left' }"
|
|
85
|
+
[(value)]="selected"
|
|
86
|
+
></smartpro-select-menu>
|
|
87
|
+
|
|
88
|
+
<!-- Branded multi-line -->
|
|
89
|
+
<smartpro-select-menu
|
|
90
|
+
variant="custom"
|
|
91
|
+
[options]="{ items, branded: true }"
|
|
92
|
+
[(value)]="selected"
|
|
93
|
+
></smartpro-select-menu>
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
## File Locations
|
|
97
|
+
|
|
98
|
+
- Wrapper: `packages/shared/angular/src/lib/components/select-menu/select-menu.component.ts`
|
|
99
|
+
- Types: `packages/shared/angular/src/lib/components/select-menu/select-menu.types.ts`
|
|
100
|
+
- Variants: `packages/shared/angular/src/lib/components/select-menu/{simple-native,custom}/<name>.component.ts`
|
|
101
|
+
- Stories: `packages/shared/angular/src/lib/components/select-menu/select-menu.component.stories.ts`
|