@spartan-ng/cli 0.0.1-alpha.345 → 0.0.1-alpha.346

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spartan-ng/cli",
3
- "version": "0.0.1-alpha.345",
3
+ "version": "0.0.1-alpha.346",
4
4
  "type": "commonjs",
5
5
  "dependencies": {
6
6
  "@nx/js": "^18.0.7",
@@ -1,25 +1,25 @@
1
1
  export declare const FALLBACK_ANGULAR_VERSION = "^17.3.0";
2
2
  export declare const NG_ICONS_VERSION = "^25.1.0";
3
- export declare const SPARTAN_ACCORDION_BRAIN_VERSION = "0.0.1-alpha.343";
4
- export declare const SPARTAN_ALERT_DIALOG_BRAIN_VERSION = "0.0.1-alpha.343";
5
- export declare const SPARTAN_AVATAR_BRAIN_VERSION = "0.0.1-alpha.343";
6
- export declare const SPARTAN_COMMAND_BRAIN_VERSION = "0.0.1-alpha.343";
7
- export declare const SPARTAN_COLLAPSIBLE_BRAIN_VERSION = "0.0.1-alpha.343";
8
- export declare const SPARTAN_CORE_VERSION = "0.0.1-alpha.343";
9
- export declare const SPARTAN_DIALOG_BRAIN_VERSION = "0.0.1-alpha.343";
10
- export declare const SPARTAN_HOVERCARD_BRAIN_VERSION = "0.0.1-alpha.343";
11
- export declare const SPARTAN_LABEL_BRAIN_VERSION = "0.0.1-alpha.343";
12
- export declare const SPARTAN_MENU_BRAIN_VERSION = "0.0.1-alpha.343";
13
- export declare const SPARTAN_POPOVER_BRAIN_VERSION = "0.0.1-alpha.343";
14
- export declare const SPARTAN_PROGRESS_BRAIN_VERSION = "0.0.1-alpha.343";
15
- export declare const SPARTAN_RADIO_GROUP_BRAIN_VERSION = "0.0.1-alpha.343";
16
- export declare const SPARTAN_SELECT_BRAIN_VERSION = "0.0.1-alpha.343";
17
- export declare const SPARTAN_SEPARATOR_BRAIN_VERSION = "0.0.1-alpha.343";
18
- export declare const SPARTAN_SHEET_BRAIN_VERSION = "0.0.1-alpha.343";
19
- export declare const SPARTAN_SWITCH_VERSION = "0.0.1-alpha.343";
20
- export declare const SPARTAN_TABS_VERSION = "0.0.1-alpha.343";
21
- export declare const SPARTAN_TABLE_VERSION = "0.0.1-alpha.343";
22
- export declare const SPARTAN_TOGGLE_VERSION = "0.0.1-alpha.343";
3
+ export declare const SPARTAN_ACCORDION_BRAIN_VERSION = "0.0.1-alpha.344";
4
+ export declare const SPARTAN_ALERT_DIALOG_BRAIN_VERSION = "0.0.1-alpha.344";
5
+ export declare const SPARTAN_AVATAR_BRAIN_VERSION = "0.0.1-alpha.344";
6
+ export declare const SPARTAN_COMMAND_BRAIN_VERSION = "0.0.1-alpha.344";
7
+ export declare const SPARTAN_COLLAPSIBLE_BRAIN_VERSION = "0.0.1-alpha.344";
8
+ export declare const SPARTAN_CORE_VERSION = "0.0.1-alpha.344";
9
+ export declare const SPARTAN_DIALOG_BRAIN_VERSION = "0.0.1-alpha.344";
10
+ export declare const SPARTAN_HOVERCARD_BRAIN_VERSION = "0.0.1-alpha.344";
11
+ export declare const SPARTAN_LABEL_BRAIN_VERSION = "0.0.1-alpha.344";
12
+ export declare const SPARTAN_MENU_BRAIN_VERSION = "0.0.1-alpha.344";
13
+ export declare const SPARTAN_POPOVER_BRAIN_VERSION = "0.0.1-alpha.344";
14
+ export declare const SPARTAN_PROGRESS_BRAIN_VERSION = "0.0.1-alpha.344";
15
+ export declare const SPARTAN_RADIO_GROUP_BRAIN_VERSION = "0.0.1-alpha.344";
16
+ export declare const SPARTAN_SELECT_BRAIN_VERSION = "0.0.1-alpha.344";
17
+ export declare const SPARTAN_SEPARATOR_BRAIN_VERSION = "0.0.1-alpha.344";
18
+ export declare const SPARTAN_SHEET_BRAIN_VERSION = "0.0.1-alpha.344";
19
+ export declare const SPARTAN_SWITCH_VERSION = "0.0.1-alpha.344";
20
+ export declare const SPARTAN_TABS_VERSION = "0.0.1-alpha.344";
21
+ export declare const SPARTAN_TABLE_VERSION = "0.0.1-alpha.344";
22
+ export declare const SPARTAN_TOGGLE_VERSION = "0.0.1-alpha.344";
23
23
  export declare const TAILWIND_MERGE_VERSION = "^2.2.0";
24
24
  export declare const TAILWINDCSS_VERSION = "^3.0.2";
25
25
  export declare const TAILWIND_ANIMATE_VERSION = "^1.0.6";
@@ -6,26 +6,26 @@ exports.FALLBACK_ANGULAR_VERSION = '^17.3.0';
6
6
  // ng-icon dependency
7
7
  exports.NG_ICONS_VERSION = '^25.1.0';
8
8
  // spartan dependencies
9
- exports.SPARTAN_ACCORDION_BRAIN_VERSION = '0.0.1-alpha.343';
10
- exports.SPARTAN_ALERT_DIALOG_BRAIN_VERSION = '0.0.1-alpha.343';
11
- exports.SPARTAN_AVATAR_BRAIN_VERSION = '0.0.1-alpha.343';
12
- exports.SPARTAN_COMMAND_BRAIN_VERSION = '0.0.1-alpha.343';
13
- exports.SPARTAN_COLLAPSIBLE_BRAIN_VERSION = '0.0.1-alpha.343';
14
- exports.SPARTAN_CORE_VERSION = '0.0.1-alpha.343';
15
- exports.SPARTAN_DIALOG_BRAIN_VERSION = '0.0.1-alpha.343';
16
- exports.SPARTAN_HOVERCARD_BRAIN_VERSION = '0.0.1-alpha.343';
17
- exports.SPARTAN_LABEL_BRAIN_VERSION = '0.0.1-alpha.343';
18
- exports.SPARTAN_MENU_BRAIN_VERSION = '0.0.1-alpha.343';
19
- exports.SPARTAN_POPOVER_BRAIN_VERSION = '0.0.1-alpha.343';
20
- exports.SPARTAN_PROGRESS_BRAIN_VERSION = '0.0.1-alpha.343';
21
- exports.SPARTAN_RADIO_GROUP_BRAIN_VERSION = '0.0.1-alpha.343';
22
- exports.SPARTAN_SELECT_BRAIN_VERSION = '0.0.1-alpha.343';
23
- exports.SPARTAN_SEPARATOR_BRAIN_VERSION = '0.0.1-alpha.343';
24
- exports.SPARTAN_SHEET_BRAIN_VERSION = '0.0.1-alpha.343';
25
- exports.SPARTAN_SWITCH_VERSION = '0.0.1-alpha.343';
26
- exports.SPARTAN_TABS_VERSION = '0.0.1-alpha.343';
27
- exports.SPARTAN_TABLE_VERSION = '0.0.1-alpha.343';
28
- exports.SPARTAN_TOGGLE_VERSION = '0.0.1-alpha.343';
9
+ exports.SPARTAN_ACCORDION_BRAIN_VERSION = '0.0.1-alpha.344';
10
+ exports.SPARTAN_ALERT_DIALOG_BRAIN_VERSION = '0.0.1-alpha.344';
11
+ exports.SPARTAN_AVATAR_BRAIN_VERSION = '0.0.1-alpha.344';
12
+ exports.SPARTAN_COMMAND_BRAIN_VERSION = '0.0.1-alpha.344';
13
+ exports.SPARTAN_COLLAPSIBLE_BRAIN_VERSION = '0.0.1-alpha.344';
14
+ exports.SPARTAN_CORE_VERSION = '0.0.1-alpha.344';
15
+ exports.SPARTAN_DIALOG_BRAIN_VERSION = '0.0.1-alpha.344';
16
+ exports.SPARTAN_HOVERCARD_BRAIN_VERSION = '0.0.1-alpha.344';
17
+ exports.SPARTAN_LABEL_BRAIN_VERSION = '0.0.1-alpha.344';
18
+ exports.SPARTAN_MENU_BRAIN_VERSION = '0.0.1-alpha.344';
19
+ exports.SPARTAN_POPOVER_BRAIN_VERSION = '0.0.1-alpha.344';
20
+ exports.SPARTAN_PROGRESS_BRAIN_VERSION = '0.0.1-alpha.344';
21
+ exports.SPARTAN_RADIO_GROUP_BRAIN_VERSION = '0.0.1-alpha.344';
22
+ exports.SPARTAN_SELECT_BRAIN_VERSION = '0.0.1-alpha.344';
23
+ exports.SPARTAN_SEPARATOR_BRAIN_VERSION = '0.0.1-alpha.344';
24
+ exports.SPARTAN_SHEET_BRAIN_VERSION = '0.0.1-alpha.344';
25
+ exports.SPARTAN_SWITCH_VERSION = '0.0.1-alpha.344';
26
+ exports.SPARTAN_TABS_VERSION = '0.0.1-alpha.344';
27
+ exports.SPARTAN_TABLE_VERSION = '0.0.1-alpha.344';
28
+ exports.SPARTAN_TOGGLE_VERSION = '0.0.1-alpha.344';
29
29
  // dev dependencies
30
30
  exports.TAILWIND_MERGE_VERSION = '^2.2.0';
31
31
  exports.TAILWINDCSS_VERSION = '^3.0.2';
@@ -1,4 +1,4 @@
1
- import { computed, Directive, Input, signal } from '@angular/core';
1
+ import { computed, Directive, input, Input, signal } from '@angular/core';
2
2
  import { hlm, injectExposedSideProvider, injectExposesStateProvider } from '@spartan-ng/ui-core';
3
3
  import { ClassValue } from 'clsx';
4
4
 
@@ -12,19 +12,14 @@ import { ClassValue } from 'clsx';
12
12
  },
13
13
  })
14
14
  export class HlmSelectContentDirective {
15
- private readonly _classNames = signal<ClassValue>('');
16
- // eslint-disable-next-line @angular-eslint/no-input-rename
17
- @Input({ alias: 'class' })
18
- set _class(classNames: ClassValue) {
19
- this._classNames.set(classNames);
20
- }
15
+ public readonly userClass = input<ClassValue>('', { alias: 'class' });
21
16
  protected readonly _stateProvider = injectExposesStateProvider({ optional: true });
22
17
  protected readonly _sideProvider = injectExposedSideProvider({ optional: true });
23
18
 
24
19
  protected readonly _computedClass = computed(() =>
25
20
  hlm(
26
21
  'w-full relative z-50 min-w-[8rem] overflow-hidden rounded-md border border-border bg-popover text-popover-foreground shadow-md p-1 data-[side=bottom]:top-[2px] data-[side=top]:bottom-[2px] data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
27
- this._classNames(),
22
+ this.userClass(),
28
23
  ),
29
24
  );
30
25
 
@@ -1,4 +1,4 @@
1
- import { computed, Directive, Input, signal } from '@angular/core';
1
+ import { computed, Directive, input } from '@angular/core';
2
2
  import { hlm } from '@spartan-ng/ui-core';
3
3
  import { BrnSelectGroupDirective } from '@spartan-ng/ui-select-brain';
4
4
  import { ClassValue } from 'clsx';
@@ -12,11 +12,6 @@ import { ClassValue } from 'clsx';
12
12
  },
13
13
  })
14
14
  export class HlmSelectGroupDirective {
15
- private readonly _classNames = signal<ClassValue>('');
16
- // eslint-disable-next-line @angular-eslint/no-input-rename
17
- @Input({ alias: 'class' })
18
- set _class(classNames: ClassValue) {
19
- this._classNames.set(classNames);
20
- }
21
- protected readonly _computedClass = computed(() => hlm(this._classNames()));
15
+ public readonly userClass = input<ClassValue>('', { alias: 'class' });
16
+ protected readonly _computedClass = computed(() => hlm(this.userClass()));
22
17
  }
@@ -1,4 +1,4 @@
1
- import { computed, Directive, inject, Input, OnInit, signal } from '@angular/core';
1
+ import { computed, Directive, inject, input, OnInit, signal } from '@angular/core';
2
2
  import { hlm } from '@spartan-ng/ui-core';
3
3
  import { BrnSelectLabelDirective } from '@spartan-ng/ui-select-brain';
4
4
  import { ClassValue } from 'clsx';
@@ -15,18 +15,12 @@ import { HlmSelectContentDirective } from './hlm-select-content.directive';
15
15
  export class HlmSelectLabelDirective implements OnInit {
16
16
  private readonly selectContent = inject(HlmSelectContentDirective);
17
17
  private readonly _stickyLabels = signal(false);
18
-
19
- private readonly _classNames = signal<ClassValue>('');
20
- // eslint-disable-next-line @angular-eslint/no-input-rename
21
- @Input({ alias: 'class' })
22
- set _class(classNames: ClassValue) {
23
- this._classNames.set(classNames);
24
- }
18
+ public readonly userClass = input<ClassValue>('', { alias: 'class' });
25
19
  protected _computedClass = computed(() =>
26
20
  hlm(
27
21
  'pl-8 pr-2 text-sm font-semibold rtl:pl-2 rtl:pr-8',
28
22
  this._stickyLabels() ? 'sticky top-0 bg-popover block z-[2]' : '',
29
- this._classNames(),
23
+ this.userClass(),
30
24
  ),
31
25
  );
32
26
 
@@ -1,4 +1,4 @@
1
- import { ChangeDetectionStrategy, Component, computed, inject, Input, signal } from '@angular/core';
1
+ import { ChangeDetectionStrategy, Component, computed, inject, input, Input } from '@angular/core';
2
2
  import { lucideCheck } from '@ng-icons/lucide';
3
3
  import { hlm } from '@spartan-ng/ui-core';
4
4
  import { HlmIconComponent, provideIcons } from '@spartan-ng/ui-icon-helm';
@@ -30,17 +30,11 @@ import { ClassValue } from 'clsx';
30
30
  })
31
31
  export class HlmSelectOptionComponent {
32
32
  protected readonly _brnSelectOption = inject(BrnSelectOptionDirective, { host: true });
33
-
34
- private readonly classNames = signal<ClassValue>('');
35
- // eslint-disable-next-line @angular-eslint/no-input-rename
36
- @Input({ alias: 'class' })
37
- set _class(classNames: ClassValue) {
38
- this.classNames.set(classNames);
39
- }
33
+ public readonly userClass = input<ClassValue>('', { alias: 'class' });
40
34
  protected readonly _computedClass = computed(() =>
41
35
  hlm(
42
36
  'relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 rtl:flex-reverse rtl:pr-8 rtl:pl-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50',
43
- this.classNames(),
37
+ this.userClass(),
44
38
  ),
45
39
  );
46
40
 
@@ -1,4 +1,4 @@
1
- import { Component, computed, ContentChild, ElementRef, Input, signal, ViewChild } from '@angular/core';
1
+ import { Component, computed, ContentChild, ElementRef, input, ViewChild } from '@angular/core';
2
2
  import { provideIcons } from '@ng-icons/core';
3
3
  import { lucideChevronDown } from '@ng-icons/lucide';
4
4
  import { hlm } from '@spartan-ng/ui-core';
@@ -29,16 +29,11 @@ export class HlmSelectTriggerComponent {
29
29
  @ContentChild(HlmIconComponent, { static: false })
30
30
  protected icon!: HlmIconComponent;
31
31
 
32
- private readonly classNames = signal<ClassValue>('');
33
- // eslint-disable-next-line @angular-eslint/no-input-rename
34
- @Input({ alias: 'class' })
35
- set _class(classNames: ClassValue) {
36
- this.classNames.set(classNames);
37
- }
32
+ public readonly userClass = input<ClassValue>('', { alias: 'class' });
38
33
  protected readonly _computedClass = computed(() =>
39
34
  hlm(
40
35
  'flex h-10 items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 w-[180px]',
41
- this.classNames(),
36
+ this.userClass(),
42
37
  ),
43
38
  );
44
39
  }
@@ -1,4 +1,4 @@
1
- import { computed, Directive, Input, signal } from '@angular/core';
1
+ import { computed, Directive, input } from '@angular/core';
2
2
  import { hlm } from '@spartan-ng/ui-core';
3
3
  import { ClassValue } from 'clsx';
4
4
 
@@ -11,16 +11,11 @@ import { ClassValue } from 'clsx';
11
11
  },
12
12
  })
13
13
  export class HlmSelectValueDirective {
14
- private readonly classNames = signal<ClassValue>('');
15
- // eslint-disable-next-line @angular-eslint/no-input-rename
16
- @Input({ alias: 'class' })
17
- set _class(classNames: ClassValue) {
18
- this.classNames.set(classNames);
19
- }
14
+ public readonly userClass = input<ClassValue>('', { alias: 'class' });
20
15
  protected readonly _computedClass = computed(() =>
21
16
  hlm(
22
17
  '!inline-block ltr:text-left rtl:text-right border-border w-[calc(100%)]] min-w-0 pointer-events-none truncate',
23
- this.classNames(),
18
+ this.userClass(),
24
19
  ),
25
20
  );
26
21
  }
@@ -1,4 +1,4 @@
1
- import { computed, Directive, Input, signal } from '@angular/core';
1
+ import { computed, Directive, input } from '@angular/core';
2
2
  import { hlm } from '@spartan-ng/ui-core';
3
3
  import { ClassValue } from 'clsx';
4
4
 
@@ -11,11 +11,6 @@ import { ClassValue } from 'clsx';
11
11
  },
12
12
  })
13
13
  export class HlmSelectDirective {
14
- private readonly _classNames = signal<ClassValue>('');
15
- // eslint-disable-next-line @angular-eslint/no-input-rename
16
- @Input({ alias: 'class' })
17
- set _class(classNames: ClassValue) {
18
- this._classNames.set(classNames);
19
- }
20
- protected readonly _computedClass = computed(() => hlm('space-y-2', this._classNames()));
14
+ public readonly userClass = input<ClassValue>('', { alias: 'class' });
15
+ protected readonly _computedClass = computed(() => hlm('space-y-2', this.userClass()));
21
16
  }
@@ -1,4 +1,4 @@
1
- import { Directive, Input, computed, input, signal } from '@angular/core';
1
+ import { Directive, computed, input } from '@angular/core';
2
2
  import { hlm } from '@spartan-ng/ui-core';
3
3
  import { ClassValue } from 'clsx';
4
4
 
@@ -11,17 +11,12 @@ export type HlmSeparatorOrientation = 'horizontal' | 'vertical';
11
11
  },
12
12
  })
13
13
  export class HlmSeparatorDirective {
14
- private readonly _orientation = signal<HlmSeparatorOrientation>('horizontal');
15
- @Input()
16
- set orientation(value: HlmSeparatorOrientation) {
17
- this._orientation.set(value);
18
- }
19
-
14
+ public readonly orientation = input<HlmSeparatorOrientation>('horizontal');
20
15
  public readonly userClass = input<ClassValue>('', { alias: 'class' });
21
16
  protected _computedClass = computed(() =>
22
17
  hlm(
23
18
  'inline-flex shrink-0 border-0 bg-border',
24
- this._orientation() === 'horizontal' ? 'h-[1px] w-full' : 'h-full w-[1px]',
19
+ this.orientation() === 'horizontal' ? 'h-[1px] w-full' : 'h-full w-[1px]',
25
20
  this.userClass(),
26
21
  ),
27
22
  );
@@ -1,6 +1,6 @@
1
- import { Component, computed, input, Input, signal } from '@angular/core';
1
+ import { Component, computed, input } from '@angular/core';
2
2
  import { hlm } from '@spartan-ng/ui-core';
3
- import { cva, VariantProps } from 'class-variance-authority';
3
+ import { VariantProps, cva } from 'class-variance-authority';
4
4
  import { ClassValue } from 'clsx';
5
5
 
6
6
  export const spinnerVariants = cva('inline-block', {
@@ -45,12 +45,7 @@ export type SpinnerVariants = VariantProps<typeof spinnerVariants>;
45
45
  `,
46
46
  })
47
47
  export class HlmSpinnerComponent {
48
- private readonly _size = signal<SpinnerVariants['size']>('default');
49
- @Input()
50
- set size(value: SpinnerVariants['size']) {
51
- this._size.set(value);
52
- }
53
-
48
+ public readonly size = input<SpinnerVariants['size']>('default');
54
49
  public readonly userClass = input<ClassValue>('', { alias: 'class' });
55
- protected _computedClass = computed(() => hlm(spinnerVariants({ size: this._size() }), this.userClass()));
50
+ protected _computedClass = computed(() => hlm(spinnerVariants({ size: this.size() }), this.userClass()));
56
51
  }
@@ -1,4 +1,4 @@
1
- import { computed, Directive, Input, input, signal } from '@angular/core';
1
+ import { computed, Directive, input } from '@angular/core';
2
2
  import { hlm } from '@spartan-ng/ui-core';
3
3
  import { cva, VariantProps } from 'class-variance-authority';
4
4
  import { ClassValue } from 'clsx';
@@ -33,20 +33,10 @@ type ToggleVariants = VariantProps<typeof toggleVariants>;
33
33
  },
34
34
  })
35
35
  export class HlmToggleDirective {
36
- private readonly _variant = signal<ToggleVariants['variant']>('default');
37
- @Input()
38
- set variant(value: ToggleVariants['variant']) {
39
- this._variant.set(value);
40
- }
41
-
42
- private readonly _size = signal<ToggleVariants['size']>('default');
43
- @Input()
44
- set size(value: ToggleVariants['size']) {
45
- this._size.set(value);
46
- }
47
-
36
+ public readonly variant = input<ToggleVariants['variant']>('default');
37
+ public readonly size = input<ToggleVariants['size']>('default');
48
38
  public readonly userClass = input<ClassValue>('', { alias: 'class' });
49
39
  protected _computedClass = computed(() =>
50
- hlm(toggleVariants({ variant: this._variant(), size: this._size() }), this.userClass()),
40
+ hlm(toggleVariants({ variant: this.variant(), size: this.size() }), this.userClass()),
51
41
  );
52
42
  }
@@ -38,8 +38,7 @@ export class HlmTooltipTriggerDirective {
38
38
  }
39
39
 
40
40
  @Input()
41
- set hlmTooltipTrigger(value: TemplateRef<unknown> | null | string) {
42
- if (typeof value === 'string') return;
41
+ set hlmTooltipTrigger(value: string | TemplateRef<unknown> | null) {
43
42
  this._brnTooltipTrigger.content = value;
44
43
  }
45
44
  }