Commit Graph

731 Commits

Author SHA1 Message Date
Leonidas 33892b9bcb chore: add new contributors to our 300 2026-06-18 10:22:30 +00:00
mehrabix f396e32df9 feat: add provideSpartanHlm utility to fix CDK overlay z-index conflict
In Angular 21, the CDK overlay defaults to using the popover attribute,
which causes overlay-based components (sheets, dialogs, tooltips) to
always render above position: fixed elements like hlm-toaster. This
adds a provideSpartanHlm() utility that configures OVERLAY_DEFAULT_CONFIG
with usePopover: false, and documents the issue in the sonner docs.

Closes #1280
2026-06-17 19:08:20 +03:30
moosme 01aeb5a231 feat(navigation-menu): add style support #1408 (#1490)
* feat(navigation-menu): add style support #1408

* fix: review

* feat(navigation-menu): add align input to navigation-menu-trigger

* add align example

* feat(navigation-menu): add navOffset

* docs(navigation-menu): update example ids

* feat(navigation-menu): add guard in updateAlign

* feat(navigation-menu): remove group from trigger

* feat(navigation-menu): remove unused data-popup-open classes

* navigation-menu doesn't have data-popup-open attribute

---------

Co-authored-by: Merlin <merlin.moos@oldendorff.com>
Co-authored-by: Marc Stammerjohann <8985933+marcjulian@users.noreply.github.com>
2026-06-17 15:43:07 +02:00
Leonidas 9849f9cd72 chore: add new contributors to our 300 2026-06-17 10:58:34 +00:00
Ashley Hunter d2f40d3014 Merge pull request #1471 from PatrickLarocque/fix/overlay-lifecycle
refactor!: split dialog and overlay portal lifecycles
2026-06-17 10:16:35 +01:00
moosme 8cf3775943 Merge pull request #1489 from marcjulian/feat/remove-unused-styles 2026-06-17 08:07:19 +02:00
Ashley Hunter 0c3b653902 Merge origin/main into fix/overlay-lifecycle
Resolve brn-dialog.service.ts conflict: drop the deprecated injectBrnDialogCtx
alias (removed on main during the pre-1.0 audit) and keep the typed
injectBrnDialogContext with the unknown default.
2026-06-16 23:22:47 +01:00
moosme 263648ade1 feat(command): add style and rtl support #1399 (#1488)
* feat(command): add style and rtl support #1399

* fix: comments

* feat(command): remove custom data-hidden is built in

* remove important from rounded

* docs(command): fix typo

* fix(command): check has search input for separator

* otherwise shows multiple separator while searching in the scrollable example

---------

Co-authored-by: Merlin <merlin.moos@oldendorff.com>
Co-authored-by: Marc Stammerjohann <8985933+marcjulian@users.noreply.github.com>
2026-06-16 18:48:35 +02:00
Marc Stammerjohann 98ca3b7ae7 docs(popover): update basic example 2026-06-16 18:08:13 +02:00
Marc Stammerjohann 346c06eaab docs(popover): add align example 2026-06-16 17:26:33 +02:00
Marc Stammerjohann a0687ae64b feat(popover): add header, title and description 2026-06-16 17:21:28 +02:00
Marc Stammerjohann 27305c73c0 feat: dropdown and context menu styles, rtl example (#1486)
* feat(dropdown-menu): add style support, add sub trigger

* feat(dropdown-menu): update snapshot

* feat(context-menu): add rtl and more examples, enable styles

* remove spartan-context-* classes as it reuses dropdown-menu

* feat(menubar): remove unused spartan-menubar-* styles, update examples

* fix(dropdown-menu): remove duplicate styles which dropdown-menu-item already applies

* docs(context-menu): fix id

* docs: update examples

* feat(dropdown-menu): make checkbox/radio group scoped

* fix(dropdown-menu): fix rtl styles

* feat(dropdown-menu): add internal comment

* feat(dropdown-menu): add ng-icon styles for item-indicator

* docs(menubar): update preview
2026-06-16 16:33:33 +02:00
Marc Stammerjohann 05463a6955 fix: ignore copilot from contributors (#1487) 2026-06-16 16:13:34 +02:00
Leonidas 0475400815 chore: add new contributors to our 300 2026-06-16 11:12:27 +00:00
Juan Valero 50c54ac29c docs: add tailwind configuration guide for Jetbrains-based IDEs (#1482) 2026-06-16 00:40:21 +02:00
moosme 457b7190cc feat(menubar): add style support (#1474)
* feat(menubar): add style support

* fix: review

---------

Co-authored-by: Merlin <merlin.moos@oldendorff.com>
2026-06-15 15:52:30 +02:00
Ahmad Mehrabi 715499fe4e feat(date-picker): add Jalali (Persian) calendar support (#1429)
* feat(date-picker): add Jalali (Persian) calendar support

- Add pure Jalali calendar math algorithms (no npm packages)
- Add JalaliDate class with valueOf() for reliable calendar comparison
- Add BrnJalaliDateAdapter implementing BrnDateAdapter<JalaliDate>
- Add comprehensive unit tests for all adapter methods
- Add Persian (Farsi) calendar i18n with RTL layout
- Add Jalali date picker example to docs page
- Add Storybook story with Persian locale
- Extend TranslateService to support 'fa' language

* feat(date-picker): add Jalali (Persian) calendar support

Add pure Jalali calendar math, JalaliDate class, and BrnJalaliDateAdapter with tests.

Move example from component docs to blocks/calendar page per PR review.

* refactor: clean up jalali date-time code

- Deduplicate JALALI_MONTHS array in calendar i18n files
- snake_case to camelCase in PersianDate (gregorianDaysInMonth, jalaliDaysInMonth)
- Expand cryptic param names (j_y to jalaliYear, g_y to gregorianYear, etc.)
- Remove parseInt() no-ops on typed number params
- Remove getMonthName (i18n concern, not calendrical)
- Destructure tuples with descriptive names across adapter/date/persian-date
- Fix month+day add drift: clamp day after month step before day arithmetic

* style: fix long line formatting to pass nx format check

* fix(date-picker): resolve merge conflicts from upstream and stashed changes

Merge descriptive variable names (_constrain, parseInt, getMonthName,
full descriptive names) with upstream descriptive names. All tests pass.

* refactor: remove parseInt unwrapping and getMonthName, add PersianDate tests
2026-06-15 15:05:30 +02:00
Leonidas 5435594148 chore: add new contributors to our 300 2026-06-15 12:16:48 +00:00
mehrabix dec0ce4401 feat(drawer): add RTL example, pointer-events guard, and fix input spacing
Add RTL preview example with EN/AR/HE translations,
pointer-events:none on body while drawer is open (removed with 300ms
delay on close), and replace div.px-4 with hlm-field-group for proper
spacing.
2026-06-14 13:14:33 +03:30
mehrabix 522153e44e fix(drawer): add showThemeToggle to drawer page
Co-authored-by: moosme <46927822+MerlinMoos@users.noreply.github.com>
2026-06-14 13:14:25 +03:30
Patrick 803614a7bb test: update overlay api snapshots 2026-06-13 14:48:23 -04:00
Patrick ba74c53c97 refactor: split dialog and overlay primitives 2026-06-13 14:32:40 -04:00
Patrick 179ec6af8f fix: coordinate overlay lifecycle with animations
Replace fixed close delays with lifecycle-driven disposal so overlays remain responsive.
Wait only for exit animations that actually start and centralize Escape, backdrop, and
outside-pointer dismissal.

BREAKING CHANGE: remove the closeDelay input and configuration option. Remove explicit delay
values; closed-state exit animations are now detected automatically.
2026-06-13 14:32:40 -04:00
mehrabix 2e3059c8a2 feat(drawer): add drawer component with brain primitive and helm styling 2026-06-13 21:31:07 +03:30
Marc Stammerjohann 68ce4bdd89 docs: add signal forms examples (#1463)
* docs: remove new flag from a few pages

* docs: add signal forms examples

* docs: remove required validation
2026-06-12 16:22:10 +02:00
moosme 33299063ad Merge pull request #1462 from marcjulian/feat/sheet-styles
feat(sheet): add style support, rtl and more examples
2026-06-12 16:10:13 +02:00
moosme 23e2d705c8 Merge pull request #1454 from marcjulian/feat/sidebar-styles
feat(sidebar): add style support and rtl example
2026-06-12 16:09:43 +02:00
Marc Stammerjohann 24811b0e91 docs(sidebar): rename dropdown menu template 2026-06-12 15:16:16 +02:00
Marc Stammerjohann 00f740cb64 feat(sidebar): adjust styles for rtl, add rtl example 2026-06-12 13:18:09 +02:00
Marc Stammerjohann 5d246e7fd2 docs(sheet): add button imports 2026-06-12 11:50:07 +02:00
Marc Stammerjohann 84ed84f8a8 docs(sheet): update side for rtl 2026-06-12 11:16:59 +02:00
Marc Stammerjohann d5a5aa1f7a feat(sheet): add style support, rtl and more examples 2026-06-12 11:13:43 +02:00
Ashley Hunter 859676a41a feat!: drop Tailwind CSS v3 support (#1460)
spartan/ui is now Tailwind CSS v4 only. The v3 compatibility layer added
complexity across the brain preset, the CLI generators and the docs, all of
which is removed here.

Brain:
- Delete the v3 JavaScript preset (hlm-tailwind-preset.js) and its package
  export; the v4 CSS preset (hlm-tailwind-preset.css) is now the only preset.
- Bump the tailwindcss peer dependency to >=4.0.0 and declare tw-animate-css
  as a peer, since it is imported by the CSS preset.

CLI:
- Remove Tailwind version detection and the v3 confirmation prompt; the theme
  generator always emits the v4 stylesheet (preset import plus OKLCH theme).
- Drop the legacy HSL theme table, the v3-only CDK overlay import branch, the
  vestigial addCdkStyles option and the unused registryItemTailwindSchema.

Docs and tooling:
- Remove the Tailwind v3 installation and theming sections and snippets.
- Drop autoprefixer; Tailwind v4 handles vendor prefixing via @tailwindcss/postcss.

BREAKING CHANGE: Tailwind CSS v3 is no longer supported. The
@spartan-ng/brain/hlm-tailwind-preset (JS) package export has been removed; use
the @spartan-ng/brain/hlm-tailwind-preset.css preset with Tailwind CSS v4. The
tailwindcss peer dependency now requires >=4.0.0.
2026-06-12 00:39:14 +02:00
Marc Stammerjohann 5a43bf7054 docs(dialog): use hlmFieldLabel 2026-06-11 16:42:58 +02:00
Marc Stammerjohann f2015b49c9 docs(dialog): update variable names 2026-06-11 16:32:09 +02:00
Marc Stammerjohann 4997940e6d docs(dialog): add rtl and more examples 2026-06-11 16:30:34 +02:00
Marc Stammerjohann 3c03ca82d0 feat(dialog): add style support 2026-06-11 12:48:34 +02:00
Marc Stammerjohann 65e30c63f7 fix(dialog): inside a menu, move out of the ng-template, closes #1225 2026-06-11 12:13:01 +02:00
Marc Stammerjohann a7e225c1fd feat(alert-dialog): add style support, rtl and more examples, add BrnDialogClose to hlmAlertDialogCancel (#1450)
* feat(alert-dialog): add style support, add BrnDialogClose to hlmAlertDialogCancel

* feat(alert-dialog): add rtl and more examples

* docs(alert-dialog): fix text

* feat(alert-dialog): align dialog width

* feat(alert-dialog): update snapshot

* chore: update snapshot comment
2026-06-11 12:01:07 +02:00
moosme e8fb6b0cfb Merge pull request #1441 from spartan-ng/wt/resizable-1412 2026-06-10 22:44:24 +02:00
Ashley Hunter 99b05147d1 fix(scroll-area): implement per-style support and match shadcn
Address review feedback on the PR. Wire the directive to ngx-scrollbar's
real CSS variables at shadcn's values (transparent 10px track, 7px
bg-border thumb) and default visibility to hover so the thumb only shows
on hover, scroll or focus like shadcn.

Move the container radius into the registry per style now that the demo
no longer hardcodes it: rounded-md for vega/nova/mira, square for lyra
via --radius 0, and rounded-2xl for maia/luma. Replace the dead
radix-era marker rules with a single spartan-scroll-area rule.

Declare ngx-scrollbar as a helm peer dependency since the directive now
imports from it, and mirror the changes in the CLI template.
2026-06-10 18:24:28 +01:00
Ashley Hunter 7296a49784 feat(scroll-area): add style support and rtl example
Closes #1413
2026-06-10 18:23:39 +01:00
Ashley Hunter 66f4d9f454 feat(resizable): add style support and rtl example
Closes #1412
2026-06-10 18:09:51 +01:00
Marc Stammerjohann a9103a61af feat(sidebar): add style support 2026-06-10 16:40:32 +02:00
Marc Stammerjohann dc2d2c112d feat(collapsible): add rtl and settings panel example (#1453)
* feat(collapsible): add rtl and settings panel example

* docs(collapsible): update feedback
2026-06-10 15:59:40 +02:00
moosme 69595c394e Merge pull request #1440 from spartan-ng/wt/radio-group-1411
feat(radio-group): add style support and rtl example
2026-06-10 09:16:35 +02:00
moosme 3dd146e20f Merge pull request #1443 from spartan-ng/wt/popover-1409
feat(popover): add style support and rtl example
2026-06-10 08:57:08 +02:00
moosme d5095a281d Merge pull request #1442 from spartan-ng/wt/carousel-1396
feat(carousel): add style support and rtl example
2026-06-10 08:56:31 +02:00
moosme 32d0ca6b65 Merge pull request #1439 from spartan-ng/wt/progress-1410
feat(progress): add style support and rtl example
2026-06-10 08:55:49 +02:00
moosme 088e9ce64a Merge pull request #1438 from spartan-ng/wt/checkbox-1397
feat(checkbox): add style support and rtl example
2026-06-10 08:51:10 +02:00