@ngbase/adk 0.1.6 → 0.1.8

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.
Files changed (70) hide show
  1. package/breadcrumb/breadcrumb-separator.d.ts +1 -5
  2. package/breadcrumb/breadcrumb.d.ts +1 -0
  3. package/breadcrumb/breadcrumbs.d.ts +3 -1
  4. package/breadcrumb/public-api.d.ts +1 -1
  5. package/fesm2022/ngbase-adk-breadcrumb.mjs +32 -34
  6. package/fesm2022/ngbase-adk-breadcrumb.mjs.map +1 -1
  7. package/fesm2022/ngbase-adk-tabs.mjs +2 -1
  8. package/fesm2022/ngbase-adk-tabs.mjs.map +1 -1
  9. package/package.json +13 -13
  10. package/schematics/components/files/accordion/accordion-llm.md.template +35 -0
  11. package/schematics/components/files/alert/alert-llm.md.template +34 -0
  12. package/schematics/components/files/autocomplete/autocomplete-llm.md.template +76 -0
  13. package/schematics/components/files/avatar/avatar-llm.md.template +37 -0
  14. package/schematics/components/files/avatar/avatar.ts.template +5 -2
  15. package/schematics/components/files/badge/badge-llm.md.template +21 -0
  16. package/schematics/components/files/badge/badge.ts.template +8 -3
  17. package/schematics/components/files/breadcrumb/breadcrumb-llm.md.template +26 -0
  18. package/schematics/components/files/breadcrumb/breadcrumb.ts.template +9 -18
  19. package/schematics/components/files/button/button-llm.md.template +22 -0
  20. package/schematics/components/files/card/card-llm.md.template +16 -0
  21. package/schematics/components/files/carousel/carousel-llm.md.template +38 -0
  22. package/schematics/components/files/checkbox/checkbox-llm.md.template +27 -0
  23. package/schematics/components/files/checkbox/focus-style.directive.ts.template +9 -6
  24. package/schematics/components/files/checkbox/index.ts.template +1 -1
  25. package/schematics/components/files/chip/chip-llm.md.template +29 -0
  26. package/schematics/components/files/color-picker/color-picker-llm.md.template +27 -0
  27. package/schematics/components/files/datepicker/datepicker-llm.md.template +43 -0
  28. package/schematics/components/files/dialog/dialog-llm.md.template +69 -0
  29. package/schematics/components/files/drawer/drawer-llm.md.template +54 -0
  30. package/schematics/components/files/form-field/form-field-llm.md.template +56 -0
  31. package/schematics/components/files/form-field/form-field.ts.template +2 -2
  32. package/schematics/components/files/form-field/input-style.directive.ts.template +2 -3
  33. package/schematics/components/files/hover-card/hover-card-llm.md.template +26 -0
  34. package/schematics/components/files/icon/icon-llm.md.template +19 -0
  35. package/schematics/components/files/inline-edit/inline-edit-llm.md.template +22 -0
  36. package/schematics/components/files/list/list-llm.md.template +23 -0
  37. package/schematics/components/files/list/list.ts.template +2 -1
  38. package/schematics/components/files/mask/mask-llm.md.template +19 -0
  39. package/schematics/components/files/menu/context-menu-llm.md.template +28 -0
  40. package/schematics/components/files/menu/menu-llm.md.template +37 -0
  41. package/schematics/components/files/otp/otp-llm.md.template +21 -0
  42. package/schematics/components/files/pagination/pagination-llm.md.template +29 -0
  43. package/schematics/components/files/pagination/pagination.ts.template +11 -12
  44. package/schematics/components/files/popover/popover-llm.md.template +59 -0
  45. package/schematics/components/files/progress/progress-llm.md.template +19 -0
  46. package/schematics/components/files/radio/radio-llm.md.template +36 -0
  47. package/schematics/components/files/resizable/resizable-llm.md.template +31 -0
  48. package/schematics/components/files/select/option.ts.template +2 -2
  49. package/schematics/components/files/select/select-llm.md.template +87 -0
  50. package/schematics/components/files/selectable/selectable-llm.md.template +31 -0
  51. package/schematics/components/files/selectable/selectable.ts.template +4 -3
  52. package/schematics/components/files/sheet/sheet-llm.md.template +54 -0
  53. package/schematics/components/files/sidenav/sidenav-llm.md.template +37 -0
  54. package/schematics/components/files/skeleton/skeleton-llm.md.template +22 -0
  55. package/schematics/components/files/slider/slider-llm.md.template +35 -0
  56. package/schematics/components/files/sonner/sonner-llm.md.template +34 -0
  57. package/schematics/components/files/spinner/spinner-llm.md.template +29 -0
  58. package/schematics/components/files/stepper/stepper-llm.md.template +32 -0
  59. package/schematics/components/files/switch/switch-llm.md.template +23 -0
  60. package/schematics/components/files/table/table-llm.md.template +31 -0
  61. package/schematics/components/files/tabs/tab.ts.template +1 -1
  62. package/schematics/components/files/tabs/tabs-llm.md.template +48 -0
  63. package/schematics/components/files/theme/index.ts.template +1 -1
  64. package/schematics/components/files/theme/{theme-button.component.ts.template → theme-button.ts.template} +2 -1
  65. package/schematics/components/files/theme/theme-llm.md.template +23 -0
  66. package/schematics/components/files/theme/theme.service.ts.template +1 -3
  67. package/schematics/components/files/toggle/toggle-llm.md.template +19 -0
  68. package/schematics/components/files/toggle-group/toggle-group-llm.md.template +32 -0
  69. package/schematics/components/files/tooltip/tooltip-llm.md.template +37 -0
  70. package/schematics/components/schema.json +2 -0
@@ -0,0 +1,26 @@
1
+ # MEE Breadcrumb
2
+
3
+ ```typescript
4
+ import { Breadcrumb, Breadcrumbs, BreadcrumbsSeparator } from '@/ui/breadcrumb';
5
+ ```
6
+
7
+ ## Components
8
+
9
+ ### `<<%= name %>-breadcrumbs>`
10
+
11
+ ### `<<%= name %>-breadcrumb>`
12
+
13
+ ### `<<%= name %>-breadcrumbs-separator>` - Optional
14
+
15
+ ## Usage
16
+
17
+ ```html
18
+ <<%= name %>-breadcrumbs>
19
+ <ng-template <%= name %>BreadcrumbsSeparator>
20
+ <<%= name %>-icon name="lucideChevronRight"></<%= name %>-icon>
21
+ </ng-template>
22
+
23
+ <a <%= name %>Breadcrumb routerLink="/home">Home</a>
24
+ <<%= name %>-breadcrumb>Contact</<%= name %>-breadcrumb>
25
+ </<%= name %>-breadcrumbs>
26
+ ```
@@ -8,14 +8,16 @@ import {
8
8
  NgbBreadcrumbLink,
9
9
  NgbBreadcrumbs,
10
10
  NgbBreadcrumbSeparator,
11
- NgbBreadcrumbSeparatorAria,
12
11
  } from '@ngbase/adk/breadcrumb';
13
12
 
14
13
  @Component({
15
14
  selector: '<%= name %>-breadcrumbs',
16
15
  changeDetection: ChangeDetectionStrategy.OnPush,
16
+ viewProviders: [provideIcons({ lucideChevronRight })],
17
17
  hostDirectives: [NgbBreadcrumbs],
18
- template: `<ng-content />`,
18
+ imports: [Icon, NgbBreadcrumbSeparator],
19
+ template: `<ng-content />
20
+ <<%= name %>-icon *ngbBreadcrumbsSeparator name="lucideChevronRight" class="text-muted-foreground" /> `,
19
21
  host: {
20
22
  class: 'flex items-center gap-2',
21
23
  },
@@ -23,25 +25,14 @@ import {
23
25
  export class Breadcrumbs {}
24
26
 
25
27
  @Component({
26
- selector: '<%= name %>-breadcrumb',
28
+ selector: '<%= name %>-breadcrumb, [<%= name %>Breadcrumb]',
27
29
  changeDetection: ChangeDetectionStrategy.OnPush,
28
30
  providers: [aliasBreadcrumb(Breadcrumb)],
29
- viewProviders: [provideIcons({ lucideChevronRight })],
30
- imports: [Icon, NgbBreadcrumbLink, NgbBreadcrumbSeparatorAria],
31
- template: `
32
- <a class='hover:text-primary aria-[current="page"]:text-primary' ngbBreadcrumbLink>
33
- <ng-content />
34
- </a>
35
- @if (!active()) {
36
- <<%= name %>-icon
37
- ngbBreadcrumbSeparatorAria
38
- name="lucideChevronRight"
39
- class="text-muted-foreground"
40
- />
41
- }
42
- `,
31
+ hostDirectives: [NgbBreadcrumbLink],
32
+ template: `<ng-content />`,
43
33
  host: {
44
- class: 'flex items-center gap-2 text-muted-foreground',
34
+ class:
35
+ 'flex items-center gap-2 text-muted-foreground aria-[current="page"]:text-primary hover:text-primary cursor-pointer',
45
36
  },
46
37
  })
47
38
  export class Breadcrumb extends NgbBreadcrumb {}
@@ -0,0 +1,22 @@
1
+ # MEE Button
2
+
3
+ ```typescript
4
+ import { Button } from '@/ui/button';
5
+ ```
6
+
7
+ ## Components
8
+
9
+ ### `[<%= name %>Button]`
10
+
11
+ - ButtonVariant = 'primary' | 'secondary' | 'ghost' | 'outline' | 'icon'
12
+ - **Inputs:**
13
+
14
+ - `variant`: ButtonVariant = 'primary'
15
+
16
+ - **Export:** `#button="<%= name %>Button"` - Template reference
17
+
18
+ ## Usage
19
+
20
+ ```html
21
+ <button <%= name %>Button>Button</button> <button <%= name %>Button variant="ghost">Button</button>
22
+ ```
@@ -0,0 +1,16 @@
1
+ # MEE Card
2
+
3
+ ```typescript
4
+ import { Card } from '@/ui/card';
5
+ ```
6
+
7
+ ## Components
8
+
9
+ ### `<<%= name %>-card>, [<%= name %>Card]`
10
+
11
+ ## Usage
12
+
13
+ ```html
14
+ <<%= name %>-card>Card</<%= name %>-card>
15
+ <div <%= name %>Card>Card</div>
16
+ ```
@@ -0,0 +1,38 @@
1
+ # MEE Carousel
2
+
3
+ ```typescript
4
+ import { Carousel, CarouselItem, CarouselButton } from '@/ui/carousel';
5
+ ```
6
+
7
+ ## Components
8
+
9
+ ### `<<%= name %>-carousel>, [<%= name %>Carousel]`
10
+
11
+ - **Export:** `#carousel="<%= name %>Carousel"` - Template reference
12
+
13
+ ### `[<%= name %>CarouselItem]`
14
+
15
+ - **Export:** `#carouselItem="<%= name %>CarouselItem"` - Template reference
16
+
17
+ ### `<<%= name %>-carousel-button>, [<%= name %>CarouselButton]`
18
+
19
+ - **Inputs:**
20
+
21
+ - `<%= name %>CarouselButton`: 'next' | 'prev' | number - Carousel button
22
+
23
+ - **Export:** `#carouselButton="<%= name %>CarouselButton"` - Template reference
24
+
25
+ ## Usage
26
+
27
+ ```html
28
+ <<%= name %>-carousel>
29
+ <div <%= name %>CarouselItem class="pl-4lg:basis-1/3 aspect-square shrink-0 grow-0 basis-full">
30
+ Item 1
31
+ </div>
32
+ <div <%= name %>CarouselItem class="pl-4lg:basis-1/3 aspect-square shrink-0 grow-0 basis-full">
33
+ Item 2
34
+ </div>
35
+ <button <%= name %>CarouselButton="next">Next</button>
36
+ <button <%= name %>CarouselButton="prev">Prev</button>
37
+ </<%= name %>-carousel>
38
+ ```
@@ -0,0 +1,27 @@
1
+ # MEE Checkbox
2
+
3
+ ```typescript
4
+ import { Checkbox } from '<%= basepath %>/checkbox';
5
+ ```
6
+
7
+ ## Component
8
+
9
+ ### `<<%= name %>-checkbox>`
10
+
11
+ - **Inputs:**
12
+
13
+ - `disabled`: boolean - Whether the checkbox is disabled
14
+ - `checked`: boolean - Whether the checkbox is checked (2way)
15
+ - `indeterminate`: boolean - Whether the checkbox is indeterminate
16
+
17
+ - **Outputs:**
18
+
19
+ - `checkedChange`: boolean - Whether the checkbox is checked
20
+ - `change`: boolean - Whether the checkbox is checked
21
+
22
+ ## Usage
23
+
24
+ ```html
25
+ <<%= name %>-checkbox [checked]="true" (checkedChange)="onChange($event)" />
26
+ <<%= name %>-checkbox [(checked)]="property" />
27
+ ```
@@ -1,12 +1,15 @@
1
- import { booleanAttribute, Directive, input } from '@angular/core';
1
+ import { Directive } from '@angular/core';
2
+
3
+ export const focusStyles = {
4
+ within: 'focus-within:ring-[2px] focus-within:border-primary',
5
+ focus:
6
+ 'outline-none focus-visible:ring-[2px] ring-primary/30 ring-offset-background focus-visible:border-primary',
7
+ };
2
8
 
3
9
  @Directive({
4
10
  selector: '[<%= name %>FocusStyle]',
5
11
  host: {
6
- class: 'outline-none',
7
- '[class]': `!unfocus() ? 'focus-visible:ring-2 focus-within:ring-2 focus-within:ring-offset-2 ring-primary focus-visible:ring-offset-2 ring-offset-background data-[focus]:ring-2 data-[focus]:ring-offset-2 data-[focus]:ring-offset-background data-[focus]:ring-primary' : ''`,
12
+ class: focusStyles.focus,
8
13
  },
9
14
  })
10
- export class FocusStyle {
11
- unfocus = input(false, { transform: booleanAttribute });
12
- }
15
+ export class FocusStyle {}
@@ -3,4 +3,4 @@
3
3
  */
4
4
 
5
5
  export * from './checkbox';
6
- export { FocusStyle as ɵFocusStyle } from './focus-style.directive';
6
+ export { FocusStyle as ɵFocusStyle, focusStyles as ɵFocusStyles } from './focus-style.directive';
@@ -0,0 +1,29 @@
1
+ # MEE Chip
2
+
3
+ ```typescript
4
+ import { Chip, ChipGroup } from '<%= basepath %>/chip';
5
+ ```
6
+
7
+ ## Components
8
+
9
+ ### `<<%= name %>-chip-group>`
10
+
11
+ ### `<<%= name %>-chip>, [<%= name %>Chip]`
12
+
13
+ - **Inputs:**
14
+
15
+ - `removable`: boolean - Whether the chip is removable
16
+ - `value`: any - The value of the chip
17
+
18
+ - **Outputs:**
19
+
20
+ - `close`: void - Emits when the chip is closed
21
+
22
+ ## Usage
23
+
24
+ ```html
25
+ <<%= name %>-chip-group>
26
+ <<%= name %>-chip [value]="item" [removable]="true">Text</<%= name %>-chip>
27
+ <button <%= name %>Chip [value]="item" [removable]="true">Text</button>
28
+ </<%= name %>-chip-group>
29
+ ```
@@ -0,0 +1,27 @@
1
+ # MEE Color Picker
2
+
3
+ ```typescript
4
+ import { FormField, Label } from '@/ui/form-field';
5
+ import { ColorInput } from '@/ui/color-picker';
6
+ ```
7
+
8
+ ## Components
9
+
10
+ ### `<<%= name %>-color-input>`
11
+
12
+ ColorFormat: `hex` | `rgb` | `hsl` | `hsb`
13
+
14
+ - **Inputs:**
15
+
16
+ - `format`: ColorFormat - The format of the color input
17
+ - `presetColors`: string[] - The preset colors of the color input
18
+ - `value`: string - The value of the color input (2way)
19
+
20
+ ## Usage
21
+
22
+ ```html
23
+ <<%= name %>-form-field>
24
+ <label <%= name %>Label>Color</label>
25
+ <<%= name %>-color-input [format]="format" [presetColors]="presetColors" [(value)]="value" />
26
+ </<%= name %>-form-field>
27
+ ```
@@ -0,0 +1,43 @@
1
+ # MEE Datepicker
2
+
3
+ ```typescript
4
+ import { FormField, Label } from '@/ui/form-field';
5
+ import { DatepickerTrigger } from '@/ui/datepicker';
6
+ ```
7
+
8
+ ## Components
9
+
10
+ ### `[<%= name %>DatepickerTrigger]`
11
+
12
+ - **Inputs:**
13
+
14
+ - `noOfCalendars`: number - The number of calendars to display
15
+ - `range`: boolean - Whether to display a range of dates
16
+ - `time`: boolean - Whether to display a time picker
17
+ - `format`: string - The format of the date input
18
+ - `fieldFormat`: string - The format of the date input in the datepicker group
19
+ - `dateFilter`: (date: Date) => boolean - A function to filter dates
20
+ - `pickerType`: 'date' | 'month' | 'year' - The type of picker to display
21
+ - `pickerTemplate`: TemplateRef<any> - A template to display in the picker
22
+
23
+ ## Usage
24
+
25
+ ```html
26
+ <<%= name %>-form-field>
27
+ <label <%= name %>Label>Date</label>
28
+ <<%= name %>-datepicker-trigger
29
+ [noOfCalendars]="noOfCalendars"
30
+ [range]="range"
31
+ [time]="time"
32
+ [format]="format"
33
+ [fieldFormat]="fieldFormat"
34
+ [dateFilter]="dateFilter"
35
+ [pickerType]="'date'"
36
+ [pickerTemplate]="pickerTemplate"
37
+ />
38
+ <ng-template #pickerTemplate>
39
+ <button <%= name %>Button>Today</button>
40
+ <button <%= name %>Button>Yesterday</button>
41
+ </ng-template>
42
+ </<%= name %>-form-field>
43
+ ```
@@ -0,0 +1,69 @@
1
+ # MEE Dialog
2
+
3
+ ```typescript
4
+ import { dialogPortal } from '@/ui/dialog';
5
+ ```
6
+
7
+ ## Notes:
8
+
9
+ DialogOptions:
10
+
11
+ - backdrop: boolean - Whether to show a backdrop
12
+ - backdropColor: boolean - Whether to use the backdrop color
13
+ - hideOverlay: boolean - Whether to hide the overlay
14
+ - data: any - The data to pass to the dialog
15
+ - title: string - The title of the dialog
16
+ - fullWindow: boolean - Whether to use the full window
17
+ - minWidth: string - The minimum width of the dialog
18
+ - minHeight: string - The minimum height of the dialog
19
+ - width: string - The width of the dialog
20
+ - height: string - The height of the dialog
21
+ - maxWidth: string - The maximum width of the dialog
22
+ - maxHeight: string - The maximum height of the dialog
23
+ - classNames: string[] - The class names of the dialog
24
+ - header: boolean - Whether to show a header
25
+ - disableClose: boolean - Whether to disable the close button
26
+ - ayId: string - The id of the dialog
27
+ - focusTrap: boolean - Whether to focus the dialog
28
+ - afterFocusEl: HTMLElement - The element to focus after the dialog is opened
29
+
30
+ ## Usage
31
+
32
+ ```html
33
+ <ng-template #dialogTemplate>
34
+ <div>
35
+ <h1>Dialog</h1>
36
+ </div>
37
+ </ng-template>
38
+ ```
39
+
40
+ ```typescript
41
+ import { DialogRef } from '@ngbase/adk/portal';
42
+ @Component({
43
+ template: `content`,
44
+ })
45
+ export class AddTaskComponent {
46
+ readonly dialogRef = inject<DialogRef<Task>>(DialogRef);
47
+ readonly data = this.dialogRef.data;
48
+
49
+ close() {
50
+ this.dialogRef.close(data);
51
+ }
52
+ }
53
+
54
+ const ref = dialog.open(AddTaskComponent, {
55
+ backdrop: true,
56
+ hideOverlay: false,
57
+ data: {},
58
+ });
59
+
60
+ ref.afterClosed.subscribe(data => {
61
+ console.log(data);
62
+ });
63
+
64
+ dialog.open(dialogContent(), {
65
+ backdrop: true,
66
+ hideOverlay: false,
67
+ data: {},
68
+ });
69
+ ```
@@ -0,0 +1,54 @@
1
+ # MEE Drawer
2
+
3
+ ```typescript
4
+ import { drawerPortal } from '@/ui/drawer';
5
+ ```
6
+
7
+ ## Notes:
8
+
9
+ DrawerOptions:
10
+
11
+ - backdrop: boolean - Whether to show a backdrop
12
+ - backdropColor: boolean - Whether to use the backdrop color
13
+ - hideOverlay: boolean - Whether to hide the overlay
14
+ - data: any - The data to pass to the drawer
15
+ - title: string - The title of the drawer
16
+ - fullWindow: boolean - Whether to use the full window
17
+ - minWidth: string - The minimum width of the drawer
18
+ - minHeight: string - The minimum height of the drawer
19
+ - width: string - The width of the drawer
20
+ - height: string - The height of the drawer
21
+ - maxWidth: string - The maximum width of the drawer
22
+ - maxHeight: string - The maximum height of the drawer
23
+ - classNames: string[] - The class names of the drawer
24
+ - header: boolean - Whether to show a header
25
+ - disableClose: boolean - Whether to disable the close button
26
+ - ayId: string - The id of the drawer
27
+ - focusTrap: boolean - Whether to focus the drawer
28
+ - afterFocusEl: HTMLElement - The element to focus after the drawer is opened
29
+
30
+ ## Usage
31
+
32
+ ```html
33
+ <ng-template #drawerContent>
34
+ <div>
35
+ <h1>Drawer</h1>
36
+ </div>
37
+ </ng-template>
38
+ ```
39
+
40
+ ```typescript
41
+ const drawer = drawerPortal();
42
+
43
+ drawer.open(DrawerComponent, {
44
+ backdrop: true,
45
+ hideOverlay: false,
46
+ data: {},
47
+ });
48
+
49
+ drawer.open(drawerContent, {
50
+ backdrop: true,
51
+ hideOverlay: false,
52
+ data: {},
53
+ });
54
+ ```
@@ -0,0 +1,56 @@
1
+ # MEE Form Field
2
+
3
+ ```typescript
4
+ import { Icon } from '@/ui/icon';
5
+ import {
6
+ FormField,
7
+ Label,
8
+ Description,
9
+ InputPrefix,
10
+ InputSuffix,
11
+ InputError,
12
+ MeeInput,
13
+ } from '@/ui/form-field';
14
+ ```
15
+
16
+ ## Components
17
+
18
+ ### `<%= name %>-form-field, [<%= name %>FormField]`
19
+
20
+ ### `[<%= name %>Label]`
21
+
22
+ ### `[<%= name %>Description]`
23
+
24
+ ### `[<%= name %>Prefix]`
25
+
26
+ ### `[<%= name %>Suffix]`
27
+
28
+ ### `[<%= name %>Error]`
29
+
30
+ - **Inputs**
31
+ - `<%= name %>Error`: string - condition to show the error similar to ngIf
32
+
33
+ ### `[<%= name %>Input]`
34
+
35
+ - **Inputs**
36
+ - `value`: string - The value of the input (2way)
37
+ - **Outputs**
38
+ - `valueChange`: EventEmitter<string> - The event emitter for the value change
39
+
40
+ ## Usage
41
+
42
+ ```html
43
+ <<%= name %>-form-field>
44
+ <label <%= name %>Label>Label</label>
45
+ <input <%= name %>Input [(value)]="value" />
46
+ <p <%= name %>Description>Description</p>
47
+ <p <%= name %>Error="required">Error</p>
48
+ <p <%= name %>Error="!required && minlength">Error</p>
49
+ <<%= name %>-icon <%= name %>Prefix name="info" />
50
+ <<%= name %>-icon <%= name %>Suffix name="info" />
51
+ </<%= name %>-form-field>
52
+
53
+ <<%= name %>-form-field>
54
+ <input <%= name %>Input [(ngModel)]="value" />
55
+ </<%= name %>-form-field>
56
+ ```
@@ -25,7 +25,7 @@ import { NgbSelectTarget } from '@ngbase/adk/select';
25
25
  template: `
26
26
  <ng-content select="[<%= name %>Label]" />
27
27
  <ng-content select="[<%= name %>Description]" />
28
- <div class="mt-1 flex items-center" #target <%= name %>InputStyle>
28
+ <div class="flex items-center" #target <%= name %>InputStyle>
29
29
  <ng-content select="[<%= name %>Prefix]" />
30
30
  <ng-content />
31
31
  <ng-content select="[<%= name %>Suffix]" />
@@ -52,7 +52,7 @@ export class FormField {
52
52
  '[class.border-red-500]': 'formField?.hasErrors()',
53
53
  },
54
54
  })
55
- export class Input {
55
+ export class MeeInput {
56
56
  readonly formField = inject(NgbFormField, { optional: true });
57
57
  }
58
58
 
@@ -1,11 +1,10 @@
1
1
  import { Directive } from '@angular/core';
2
- import { ɵFocusStyle as FocusStyle } from '<%= basepath %>/checkbox';
2
+ import { ɵFocusStyles as focusStyles } from '<%= basepath %>/checkbox';
3
3
 
4
4
  @Directive({
5
5
  selector: '[<%= name %>InputStyle]',
6
- hostDirectives: [{ directive: FocusStyle, inputs: ['unfocus'] }],
7
6
  host: {
8
- class: 'inline-block rounded-lg bg-transparent px-2.5 py-2 border font-normal min-h-10',
7
+ class: `mis inline-block rounded-lg bg-transparent px-2.5 py-2 border font-normal min-h-10 ${focusStyles.focus} ${focusStyles.within}`,
9
8
  },
10
9
  })
11
10
  export class InputStyle {}
@@ -0,0 +1,26 @@
1
+ # Hover Card
2
+
3
+ ```typescript
4
+ import { HoverCard } from '@/ui/hover-card';
5
+ ```
6
+
7
+ ## Components
8
+
9
+ ### `<%= name %>-hover-card`
10
+
11
+ - **Inputs**
12
+ - `<%= name %>HoverCard`: TemplateRef<any> - The template to show when hovering over the element
13
+ - `options`: PopoverOptions - The options for the hover card
14
+ - `delay`: number - The delay in milliseconds before the hover card is shown
15
+
16
+ ## Usage
17
+
18
+ ```html
19
+ <button [<%= name %>HoverCard]="myTemplate" <%= name %>Button="ghost" class="underline">
20
+ Hover over to show hover card
21
+ </button>
22
+
23
+ <ng-template #myTemplate>
24
+ <div>Hover card content</div>
25
+ </ng-template>
26
+ ```
@@ -0,0 +1,19 @@
1
+ # Icon
2
+
3
+ ```typescript
4
+ import { Icon } from '@/ui/icon';
5
+ ```
6
+
7
+ ## Components
8
+
9
+ ### `<%= name %>-icon`
10
+
11
+ - **Inputs**
12
+ - `name`: string - The name of the icon to display
13
+ - `size`: string - The size of the icon to display
14
+
15
+ ## Usage
16
+
17
+ ```html
18
+ <<%= name %>-icon name="info" />
19
+ ```
@@ -0,0 +1,22 @@
1
+ # Inline Edit
2
+
3
+ ```typescript
4
+ import { InlineEdit } from '@/ui/inline-edit';
5
+ ```
6
+
7
+ ## Components
8
+
9
+ ### `<%= name %>-inline-edit`
10
+
11
+ - **Inputs**
12
+ - `value`: string - The value of the input (2way)
13
+ - `editOn`: 'click' | 'dblclick' = 'dblclick' - The event to trigger the edit
14
+ - **Outputs**
15
+ - `valueChange`: EventEmitter<string> - The event emitter for the value change
16
+
17
+ ## Usage
18
+
19
+ ```html
20
+ <<%= name %>-inline-edit [value]="value" [editOn]="editOn" (valueChange)="onValueChange($event)" />
21
+ <<%= name %>-inline-edit [(value)]="value" />
22
+ ```
@@ -0,0 +1,23 @@
1
+ # List
2
+
3
+ ```typescript
4
+ import { List } from '@/ui/list';
5
+ ```
6
+
7
+ ## Components
8
+
9
+ ### `[<%= name %>List]`
10
+
11
+ - **inputs**
12
+
13
+ - `disabled`: boolean
14
+
15
+ - **exports** - `<%= name %>List`
16
+
17
+ ## Usage
18
+
19
+ ```html
20
+ <button <%= name %>List>Item 1</button>
21
+ <button <%= name %>List>Item 2</button>
22
+ <button <%= name %>List>Item 3</button>
23
+ ```
@@ -1,5 +1,6 @@
1
1
  import { Directive } from '@angular/core';
2
2
  import { NgbList, NgbListActionGroup, provideList } from '@ngbase/adk/list';
3
+ import { FocusStyle } from '../checkbox/focus-style.directive';
3
4
 
4
5
  @Directive({
5
6
  selector: '[<%= name %>ListStyle]',
@@ -12,7 +13,7 @@ export class ListStyle {}
12
13
 
13
14
  @Directive({
14
15
  selector: '[<%= name %>List]',
15
- hostDirectives: [ListStyle],
16
+ hostDirectives: [ListStyle, FocusStyle],
16
17
  providers: [provideList(List)],
17
18
  host: {
18
19
  role: 'list',
@@ -0,0 +1,19 @@
1
+ # Mask
2
+
3
+ ```typescript
4
+ import { Mask } from '@/ui/mask';
5
+ ```
6
+
7
+ ## Components
8
+
9
+ ### `<%= name %>Mask`
10
+
11
+ - **Inputs**
12
+ - `<%= name %>Mask`: string - The mask pattern to apply to the input
13
+ - `showMaskType`: boolean = false - Whether to show the mask type
14
+
15
+ ## Usage
16
+
17
+ ```html
18
+ <<%= name %>-mask [<%= name %>Mask]="'(000) 000-0000'" [showMaskType]="showMaskType" />
19
+ ```