Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .claude/skills/contributing/references/new-component.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,18 @@ Follow all patterns from best-practices:
1. Create barrel export in `index.ts`
2. Add export to the parent category `index.ts` (e.g., `tedi/components/form/index.ts`)

## Step 6: Verify
## Step 6: Code Review

Run `/simplify` to review all changed code for reuse opportunities, code quality issues, and efficiency problems. Fix all valid findings before proceeding.

Comment on lines +57 to +60
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Document the /simplify command and clarify "valid findings".

The new code review step introduces the /simplify command without explanation. Users need to know:

  • What the /simplify command is and what it does
  • Where/how to execute it (CLI, IDE plugin, web interface, etc.)
  • What kind of output to expect
  • How to determine which findings are "valid" (criteria, judgment process)

Consider adding a brief explanation or a reference link to documentation.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.claude/skills/contributing/references/new-component.md around lines 57 -
60, Update "Step 6: Code Review" to document the /simplify command and define
"valid findings": add a short description of what /simplify does (e.g.,
automated code-review assistant that suggests reuse, quality, and efficiency
improvements), where to run it (CLI command or IDE/web integration) and what
output looks like (summary of issues, severity levels, suggested fixes, and
example output). Also add criteria for "valid findings" (e.g., reproducible
issues, non-whitespace changes, security/bug/performance regressions, and
clearly actionable suggestions) and a short guidance on how to triage
suggestions (accept, request changes, or ignore with reason); include a
reference link to the tool/docs if available and mention the command name
"/simplify" and the Step heading ("Step 6: Code Review") so reviewers can find
and run it.

## Step 7: Verify

1. Run tests: `npx jest tedi/components/<category>/<component-name>/`
2. Fix any failures.
3. Run lint: `npm run lint`
4. Fix any lint errors.

## Step 7: Update Consumer Catalog
## Step 8: Update Consumer Catalog

Update `skills/tedi-angular/references/components.md` with the new component:
1. Add an entry to the appropriate section (TEDI-Ready or Community) with selector, key inputs/outputs, and a usage example.
Expand Down
10 changes: 7 additions & 3 deletions .claude/skills/contributing/references/refactoring.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,18 +40,22 @@ Apply changes in this order:
5. **Tests** — update spec files to match new API/behavior
6. **Stories** — update Storybook stories to match new API

## Step 5: Verify
## Step 5: Code Review

Run `/simplify` to review all changed code for reuse opportunities, code quality issues, and efficiency problems. Fix all valid findings before proceeding.

## Step 6: Verify

1. Run the specific component test: `npx jest <component-path>`
2. Run the full test suite: `npm test`
3. Run lint: `npm run lint`
4. Compare test results with the baseline from Step 2 — no new failures allowed.

## Step 6: Update Consumer Catalog
## Step 7: Update Consumer Catalog

If the refactor changed the public API (renamed selector, inputs/outputs, removed or deprecated a component), update `skills/tedi-angular/references/components.md` to match.

## Step 7: Report
## Step 8: Report

Summarize:
- Files changed (with brief description of each change)
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/angular-test-and-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ jobs:
--skip-git --skip-tests --style=scss --ssr=false --skip-install
cd test-app
npm install
npm install ../dist/*.tgz @angular/animations@${{ matrix.angular-version }} @angular/forms@${{ matrix.angular-version }} @angular/cdk@${{ matrix.angular-version }} ngx-float-ui@${{ matrix.angular-version }}
npm install ../dist/*.tgz @angular/animations@${{ matrix.angular-version }} @angular/forms@${{ matrix.angular-version }} @angular/cdk@${{ matrix.angular-version }}

# Import a component to verify the library is consumable
cat > src/app/app.component.ts << 'EOF'
Expand Down
4 changes: 2 additions & 2 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
],
"rules": {
"selector-class-pattern": [
"^((tedi|cdk)-[a-z][a-z0-9]*(?:-[a-z0-9]+)*(?:__[a-z][a-z0-9]*(?:-[a-z0-9]+)*)*(?:--[a-z][a-z0-9]+(?:-[a-z0-9]+)*)?|ng-[a-z]+(?:-[a-z]+)*|float-ui-[a-z]+(?:-[a-z]+)*)$",
"^((tedi|cdk)-[a-z][a-z0-9]*(?:-[a-z0-9]+)*(?:__[a-z][a-z0-9]*(?:-[a-z0-9]+)*)*(?:--[a-z][a-z0-9]+(?:-[a-z0-9]+)*)?|ng-[a-z]+(?:-[a-z]+)*)$",
{
"message": "Class selector must start with 'tedi-' prefix and follow BEM naming (e.g., .tedi-button, .tedi-button__icon, .tedi-button--primary). Selector: \"%s\"",
"message": "Class selector must start with 'tedi-', 'cdk-' or 'ng-' prefix and follow BEM naming (e.g., .tedi-button, .tedi-button__icon, .tedi-button--primary). Selector: \"%s\"",
"resolveNestedSelectors": true
}
],
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,15 @@ CI runs build and test jobs against all supported versions using a matrix strate

When a new Angular major is released (e.g. v22):

1. **`package.json`** — add `|| ^22.0.0` to every Angular peer dependency and `ngx-float-ui`
1. **`package.json`** — add `|| ^22.0.0` to every Angular peer dependency
2. **`.github/workflows/angular-test-and-lint.yml`** — add `22` to the `angular-version` matrix in the `build` and `test` jobs
3. **`.github/workflows/angular-release.yml`** — add `22` to the `angular-version` matrix in the `test` job

### Dropping a deprecated Angular version

When an Angular major reaches end-of-life (e.g. v19):

1. **`package.json`** — remove `^19.0.0 ||` from every Angular peer dependency and `ngx-float-ui`
1. **`package.json`** — remove `^19.0.0 ||` from every Angular peer dependency
2. **`.github/workflows/angular-test-and-lint.yml`** — remove `19` from the `angular-version` matrix in the `build` and `test` jobs
3. **`.github/workflows/angular-release.yml`** — remove `19` from the `angular-version` matrix in the `test` job
4. Bump `devDependencies` to the new minimum supported Angular version so the library is always built and developed against a supported release
Expand Down
49 changes: 1 addition & 48 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 1 addition & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
"@angular/common": "^19.0.0 || ^20.0.0 || ^21.0.0",
"@angular/core": "^19.0.0 || ^20.0.0 || ^21.0.0",
"@angular/forms": "^19.0.0 || ^20.0.0 || ^21.0.0",
"@angular/platform-browser": "^19.0.0 || ^20.0.0 || ^21.0.0",
"ngx-float-ui": "^19.0.1 || ^20.0.0 || ^21.0.0"
"@angular/platform-browser": "^19.0.0 || ^20.0.0 || ^21.0.0"
},
"dependencies": {
"@tedi-design-system/core": "^3.3.0"
Expand Down Expand Up @@ -84,7 +83,6 @@
"jest-preset-angular": "^14.5.3",
"lint-staged": "^16.1.6",
"ng-packagr": "^19.2.0",
"ngx-float-ui": "19.0.1",
"prettier": "^3.4.2",
"readdirp": "4.1.2",
"replace-in-file": "^8.3.0",
Expand Down
1 change: 0 additions & 1 deletion skills/tedi-angular/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ npm install @tedi-design-system/angular @tedi-design-system/core
@angular/cdk: ^19.0.0 || ^20.0.0 || ^21.0.0
@angular/animations: ^19.0.0 || ^20.0.0 || ^21.0.0
@angular/platform-browser: ^19.0.0 || ^20.0.0 || ^21.0.0
ngx-float-ui: ^19.0.1 || ^20.0.0 || ^21.0.0
```

## Setup
Expand Down
10 changes: 3 additions & 7 deletions skills/tedi-angular/references/components.md
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,6 @@ Implements `ControlValueAccessor`. Value type is `T` (single) or `T[]` (multisel
- `showClear: boolean = false` — show clear action in dropdown
- `selectAllLabel: string = "Vali kõik"`
- `clearLabel: string = "Tühjenda valik"`
- `appendTo: string = ""` — append dropdown to selector (e.g., "body")
**Outputs:**
- `cleared: void` — emitted when clear button is clicked in custom content mode
**Slots:**
Expand All @@ -377,14 +376,14 @@ Implements `ControlValueAccessor`. Value type depends on mode: `boolean` (toggle
<tedi-filter text="Active" variant="secondary" [formControl]="activeControl" />

<!-- Single-select dropdown -->
<tedi-filter text="Service" [options]="options" [(value)]="value" [showClear]="true" appendTo="body" />
<tedi-filter text="Service" [options]="options" [(value)]="value" [showClear]="true" />

<!-- Single-select with label preserved (shows "Service: Option A") -->
<tedi-filter text="Service" [options]="options" [(value)]="value" [preserveLabel]="true" appendTo="body" />
<tedi-filter text="Service" [options]="options" [(value)]="value" [preserveLabel]="true" />

<!-- Multiselect dropdown -->
<tedi-filter text="Hospital" [multiselect]="true" [options]="options" [(values)]="values"
[searchable]="true" [showSelectAll]="true" [showClear]="true" appendTo="body" />
[searchable]="true" [showSelectAll]="true" [showClear]="true" />

<!-- With prepend content -->
<tedi-filter text="Submitted" variant="secondary" size="large">
Expand Down Expand Up @@ -718,7 +717,6 @@ The `[(open)]` binding approach is deprecated. Use `ModalService.open()` for new
**Inputs:**
- `position: DropdownPosition = "bottom-start"`
- `preventOverflow: boolean = true`
- `appendTo: string`

```html
<tedi-dropdown [(value)]="selected">
Expand All @@ -737,15 +735,13 @@ The `[(open)]` binding approach is deprecated. Use `ModalService.open()` for new
- `dismissible: boolean = true`
- `withArrow: boolean = true`
- `lockScroll: boolean = false`
- `appendTo: string = "body"`

### Tooltip
**Selector:** `tedi-tooltip`
**Inputs:**
- `position: TooltipPosition = "top"`
- `preventOverflow: boolean = true`
- `openWith: TooltipOpenWith = "both"` — hover, focus, or both
- `appendTo: string = "body"`

```html
<tedi-tooltip position="top">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
[class.tedi-date-picker__input--error]="inputState() === 'error'"
[attr.id]="inputId()"
[attr.placeholder]="inputPlaceholder()"
[attr.aria-expanded]="!fieldDisabled() && popover().floatUiComponent().state"
[attr.aria-expanded]="!fieldDisabled() && popover().isOpen()"
[attr.aria-controls]="uniqueId"
[attr.aria-readonly]="!allowManualInput()"
[readOnly]="!allowManualInput()"
Expand Down
Loading
Loading