# Changelog ## 13.0.0-next.0 The library has been rewritten from scratch to support modern, zoneless Angular 21 architecture and high-performance native web APIs. ### New features - **Modern Stack Upgrade:** Migrated to Angular 21 and replaced the testing environment with Vitest. - **Performance Boost:** Completely removed dependencies on `zone.js`, `hammerjs` (closes [#449](https://github.com/MurhafSousli/ngx-gallery/issues/449)), and `@angular/animations`. - **Template Flexibility:** - Added `gallerySlot` attribute directive for static custom templates. - Added `*galleryItemDef` structural directive to define main and thumbnail item templates. - Added `*galleryItemLoaderDef` and `*galleryItemErrorDef` structural directives for custom loading/error states (closes [#626](https://github.com/MurhafSousli/ngx-gallery/issues/626)). - **Navigation & Layout Enhancements:** - `GalleryNav` component can now be used directly on thumbnails (closes [#448](https://github.com/MurhafSousli/ngx-gallery/issues/448), [#591](https://github.com/MurhafSousli/ngx-gallery/issues/591)). - Added `GalleryNavButton` for custom navigation buttons within `GalleryNav`. - Introduced new layout configurations: `itemsPerView="3"`, `itemSize="auto"`, and `itemSize="200"`. - Added a `steps` option to `next()` and `prev()` navigation methods (closes [#281](https://github.com/MurhafSousli/ngx-gallery/issues/281)). - Added `initialIndex` input to set the starting gallery index (closes [#638](https://github.com/MurhafSousli/ngx-gallery/issues/638)). - Added `snapAlign` input to define item alignment in the viewport. - **Reactivity & Events:** Added `activeIndexChange` and `anchorIndexChange` outputs. - **Styling:** Added SASS functions `ng-gallery-overrides()` and `ng-lightbox-overrides()` to easily customize gallery and lightbox CSS variables. - **Accessibility (A11Y):** Added native accessibility support via `provideGalleryA11yOptions()`. - **Core Optimization:** - Ability to use `NgOptimizedImage` for lazy loading images and thumbnails (closes [#546](https://github.com/MurhafSousli/ngx-gallery/issues/546)). - Lightbox now uses the native HTML `` element instead of `@angular/cdk/dialog` (closes [#596](https://github.com/MurhafSousli/ngx-gallery/issues/596)). - Added native gesture support for sliding one image at a time (closes [#616](https://github.com/MurhafSousli/ngx-gallery/issues/616)). - Enabled hooking click events directly on gallery images (closes [#603](https://github.com/MurhafSousli/ngx-gallery/issues/603)). ### Bug fixes - Replaced `@angular/animations` with native web animations (closes [#639](https://github.com/MurhafSousli/ngx-gallery/issues/639), [#637](https://github.com/MurhafSousli/ngx-gallery/issues/637)). - Fixed Lightbox focus trap and restored focus to the previously active element upon closing (closes [#642](https://github.com/MurhafSousli/ngx-gallery/issues/642)). - Migrated Lightbox close button to a native `