Skip to content

Commit d6e478d

Browse files
authored
Merge pull request #1 from ishansasika/release/v2.3.0-comprehensive-features
Release/v2.3.0 comprehensive features
2 parents 34054aa + 44fdb2b commit d6e478d

16 files changed

Lines changed: 1554 additions & 17 deletions

CHANGELOG.md

Lines changed: 114 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,120 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [2.3.0] - 2026-01-14
9+
10+
### ✨ New Features
11+
12+
#### Fuzzy Search
13+
- Advanced search algorithm supporting acronym-style matching (e.g., "fb" matches "Facebook")
14+
- Scores and ranks results by relevance with consecutive match bonuses
15+
- Word boundary detection for better acronym matching
16+
- Configurable threshold and case sensitivity
17+
- Props: `enableFuzzySearch`, `fuzzySearchThreshold`, `fuzzySearchCaseSensitive`
18+
- New utility: `fuzzyMatch()` and `sortByFuzzyScore()` exported for external use
19+
20+
#### Dark Mode
21+
- Automatic system dark mode detection via CSS media queries
22+
- Uses Angular signals for reactive theme switching
23+
- Manual override with `colorScheme` prop ('auto', 'light', 'dark')
24+
- Dedicated dark theme with proper contrast and readability
25+
- New provider: `DarkModeProvider` service for theme management
26+
- Props: `enableAutoThemeDetection`, `colorScheme`, `darkModeTheme`, `lightModeTheme`
27+
28+
#### Loading Skeleton
29+
- Modern shimmer skeleton UI during async loading operations
30+
- Customizable item count, height, and animation delay
31+
- Smooth gradient animation with configurable timing
32+
- Props: `enableLoadingSkeleton`, `skeletonItemCount`, `skeletonItemHeight`, `skeletonAnimationDelay`
33+
34+
#### Compact Mode
35+
- Ultra-dense layout variant for dashboards and data-heavy UIs
36+
- Reduced padding, font sizes, and gaps throughout component
37+
- Works with all existing features (multi-select, validation, etc.)
38+
- Single prop activation: `compactMode`
39+
40+
#### Custom Tag Templates
41+
- Full control over multi-select tag rendering via ng-template
42+
- Support custom layouts, avatars, badges, and styling
43+
- Template context includes option data and selection state
44+
- Usage: `<ng-template #tagTemplate let-option>...</ng-template>`
45+
46+
#### Option Checkbox Mode
47+
- Visual checkboxes next to options for better selection feedback
48+
- Three style variants: default, filled, outlined
49+
- Configurable left/right position
50+
- Enhanced accessibility with proper ARIA attributes
51+
- Props: `showOptionCheckboxes`, `checkboxPosition`, `checkboxStyle`
52+
53+
#### Bulk Actions
54+
- Action buttons for performing operations on selected options
55+
- Three position options: above, below, or floating
56+
- Configurable label and disabled states
57+
- Event emission for custom handling
58+
- Props: `bulkActions`, `enableBulkActions`, `bulkActionsPosition`, `bulkActionsLabel`
59+
- New event: `bulkActionSelected`
60+
- New interface: `BulkAction`
61+
62+
#### Option Sorting
63+
- Multiple built-in sort modes: alphabetical (asc/desc), recently-used
64+
- Custom comparator function support for advanced sorting
65+
- Recently used tracking with configurable limit
66+
- Integrates seamlessly with existing filtering and pinning
67+
- Props: `sortMode`, `customSortComparator`, `recentlyUsedLimit`
68+
- New utility: `sortOptions()` exported for external use
69+
70+
### 📦 New Exports
71+
72+
- `DarkModeProvider` - Injectable service for dark mode management
73+
- `ColorScheme` - Type for color scheme preference
74+
- `BulkAction` - Interface for bulk action configuration
75+
- `SelectBulkActionEvent` - Event interface for bulk actions
76+
- `fuzzyMatch()` - Utility function for fuzzy string matching
77+
- `FuzzyMatchResult` - Interface for fuzzy match results
78+
- `sortByFuzzyScore()` - Utility to sort items by fuzzy score
79+
- `sortOptions()` - Utility function for option sorting
80+
- `SortMode` - Type for sorting modes
81+
- `SortConfig` - Interface for sort configuration
82+
83+
### 🔧 Improvements
84+
85+
- Added `resolvedTheme` computed signal for automatic theme resolution
86+
- Added `hasBulkActions` computed signal for conditional rendering
87+
- Added `recentlyUsedIds` signal for tracking usage history
88+
- Enhanced `filteredOptions` to support fuzzy search and sorting
89+
- Better separation of concerns with new utility modules
90+
91+
### 🎨 Styles
92+
93+
- Added ~350 lines of new SCSS for all v2.3.0 features
94+
- Complete dark mode styling with CSS custom properties
95+
- Skeleton loader animations with shimmer effect
96+
- Compact mode adjustments for all component parts
97+
- Checkbox styles for all three variants
98+
- Bulk actions bar with multiple position options
99+
- Responsive design for all new features
100+
101+
### 📊 Statistics
102+
103+
- **27 new @Input properties**
104+
- **1 new @Output event**
105+
- **1 new @ContentChild template**
106+
- **4 new utility files**
107+
- **1 new provider**
108+
- **1 new interface file**
109+
- **~500 lines of new TypeScript**
110+
- **~350 lines of new SCSS**
111+
- **~50 lines of template updates**
112+
113+
### 🔄 Demo App Updates
114+
115+
- Added 14 new examples showcasing v2.3.0 features
116+
- Updated metadata with 23 new prop definitions
117+
- Added `v2.3-features` category
118+
- Combined feature examples demonstrating integration
119+
120+
---
121+
8122
## [2.2.0] - 2026-01-09
9123

10124
### ✨ New Features

CLAUDE.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ Target: >85% coverage
250250
- **Async Caching**: Uses Map for O(1) cache lookups
251251
- **Signals**: Automatic change detection optimization
252252
- **Animations**: Use `@angular/animations` for GPU-accelerated transforms
253-
- **Virtual Scrolling**: Not currently implemented (consider for v2.0)
253+
- **Virtual Scrolling**: Implemented in v2.0 using Angular CDK
254254

255255
## Accessibility Notes
256256
- All interactive elements have ARIA labels
@@ -261,6 +261,11 @@ Target: >85% coverage
261261
- High contrast mode support
262262

263263
## Version History
264+
- **v2.3.0** (2026-01-14): Fuzzy search, dark mode, loading skeleton, compact mode, custom tag templates, option checkboxes, bulk actions, option sorting
265+
- **v2.2.0** (2026-01-09): Search result highlighting, tag overflow management
266+
- **v2.1.0** (2026-01-09): Drag & drop reordering, option pinning
267+
- **v2.0.0** (2026-01-08): Virtual scrolling, validation states, tooltips, recent selections, infinite scroll, advanced keyboard, copy/paste
268+
- **v1.1.0** (2026-01-07): Max selection limit, search debounce, min search length
264269
- **v1.0.0** (2025-12-31): Initial release with full react-select API parity
265270

266271
## Resources

README.md

Lines changed: 176 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,17 @@ A modern, feature-rich, and fully accessible select component for Angular applic
2121

2222
### Advanced Features
2323

24-
#### v2.2.0 Features 🆕
24+
#### v2.3.0 Features 🎉 NEW
25+
- **Fuzzy Search** - Advanced search algorithm supporting acronym-style matching (e.g., 'fb' matches 'Facebook')
26+
- **Dark Mode** - Automatic dark mode detection with manual override and dedicated dark theme
27+
- **Loading Skeleton** - Modern shimmer skeleton UI while loading async options
28+
- **Compact Mode** - Ultra-dense layout variant with reduced padding for data-heavy UIs
29+
- **Custom Tag Templates** - Full control over multi-select tag rendering with ng-template
30+
- **Option Checkbox Mode** - Display checkboxes next to options for better visual selection feedback
31+
- **Bulk Actions** - Action buttons for performing operations on all selected options
32+
- **Option Sorting** - Built-in sorting modes (alphabetical, recently used, custom comparator)
33+
34+
#### v2.2.0 Features
2535
- **Search Result Highlighting** - Automatically highlights matching text in options with customizable colors
2636
- **Tag Overflow Management** - Show "+N more" or collapsible tags when exceeding visible limit
2737

@@ -134,6 +144,171 @@ export class AppModule { }
134144

135145
## Usage Examples
136146

147+
### Fuzzy Search (v2.3.0)
148+
149+
Enable intelligent fuzzy search for better option matching:
150+
151+
```typescript
152+
<angular-perfect-select
153+
[options]="options"
154+
[enableFuzzySearch]="true"
155+
[fuzzySearchThreshold]="0.3"
156+
[fuzzySearchCaseSensitive]="false"
157+
[isSearchable]="true"
158+
placeholder="Try searching 'fb' to find 'Facebook'..."
159+
/>
160+
```
161+
162+
### Dark Mode (v2.3.0)
163+
164+
Automatic dark mode detection with system preference:
165+
166+
```typescript
167+
<angular-perfect-select
168+
[options]="options"
169+
[enableAutoThemeDetection]="true"
170+
[darkModeTheme]="'dark'"
171+
[lightModeTheme]="'blue'"
172+
[colorScheme]="'auto'"
173+
placeholder="Auto dark mode..."
174+
/>
175+
176+
// Manual dark mode override
177+
<angular-perfect-select
178+
[options]="options"
179+
[colorScheme]="'dark'"
180+
placeholder="Always dark mode..."
181+
/>
182+
```
183+
184+
### Loading Skeleton (v2.3.0)
185+
186+
Show modern skeleton UI while loading:
187+
188+
```typescript
189+
<angular-perfect-select
190+
[loadOptions]="loadRemoteData"
191+
[enableLoadingSkeleton]="true"
192+
[skeletonItemCount]="5"
193+
[skeletonItemHeight]="40"
194+
[skeletonAnimationDelay]="800"
195+
placeholder="Loading with skeleton..."
196+
/>
197+
```
198+
199+
### Compact Mode (v2.3.0)
200+
201+
Dense layout for dashboards and data grids:
202+
203+
```typescript
204+
<angular-perfect-select
205+
[options]="options"
206+
[compactMode]="true"
207+
placeholder="Compact select..."
208+
/>
209+
```
210+
211+
### Custom Tag Templates (v2.3.0)
212+
213+
Fully customize how multi-select tags are rendered:
214+
215+
```typescript
216+
<angular-perfect-select
217+
[options]="options"
218+
[isMulti]="true"
219+
[(ngModel)]="selectedValues"
220+
>
221+
<ng-template #tagTemplate let-option>
222+
<div class="custom-tag">
223+
<img [src]="option.avatar" alt="" class="tag-avatar" />
224+
<span>{{option.label}}</span>
225+
<span class="tag-badge">{{option.role}}</span>
226+
</div>
227+
</ng-template>
228+
</angular-perfect-select>
229+
```
230+
231+
### Option Checkbox Mode (v2.3.0)
232+
233+
Display checkboxes for better visual feedback:
234+
235+
```typescript
236+
<angular-perfect-select
237+
[options]="options"
238+
[isMulti]="true"
239+
[showOptionCheckboxes]="true"
240+
[checkboxPosition]="'left'"
241+
[checkboxStyle]="'filled'"
242+
placeholder="Select with checkboxes..."
243+
/>
244+
```
245+
246+
### Bulk Actions (v2.3.0)
247+
248+
Add action buttons for selected options:
249+
250+
```typescript
251+
// Component
252+
bulkActions: BulkAction[] = [
253+
{
254+
id: 'export',
255+
label: 'Export',
256+
icon: '/assets/export.svg',
257+
action: (selectedOptions) => this.exportSelected(selectedOptions)
258+
},
259+
{
260+
id: 'delete',
261+
label: 'Delete All',
262+
action: (selectedOptions) => this.deleteSelected(selectedOptions)
263+
}
264+
];
265+
266+
// Template
267+
<angular-perfect-select
268+
[options]="options"
269+
[isMulti]="true"
270+
[enableBulkActions]="true"
271+
[bulkActions]="bulkActions"
272+
[bulkActionsPosition]="'above'"
273+
[bulkActionsLabel]="'Actions:'"
274+
(bulkActionSelected)="onBulkAction($event)"
275+
/>
276+
```
277+
278+
### Option Sorting (v2.3.0)
279+
280+
Sort options automatically:
281+
282+
```typescript
283+
// Alphabetical sorting
284+
<angular-perfect-select
285+
[options]="options"
286+
[sortMode]="'alphabetical-asc'"
287+
placeholder="Sorted A-Z..."
288+
/>
289+
290+
// Recently used sorting
291+
<angular-perfect-select
292+
[options]="options"
293+
[sortMode]="'recently-used'"
294+
[recentlyUsedLimit]="10"
295+
placeholder="Recently used first..."
296+
/>
297+
298+
// Custom sorting
299+
<angular-perfect-select
300+
[options]="options"
301+
[sortMode]="'custom'"
302+
[customSortComparator]="customSort"
303+
placeholder="Custom sorted..."
304+
/>
305+
306+
// Component
307+
customSort = (a: SelectOption, b: SelectOption) => {
308+
return a.priority - b.priority;
309+
};
310+
```
311+
137312
### Search Result Highlighting (v2.2.0)
138313

139314
Highlight matching text in options during search:

demo/angular.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
},
3333
{
3434
"type": "anyComponentStyle",
35-
"maximumWarning": "10kB",
36-
"maximumError": "20kB"
35+
"maximumWarning": "20kB",
36+
"maximumError": "30kB"
3737
}
3838
],
3939
"outputHashing": "all"

0 commit comments

Comments
 (0)