@eduboxpro/studio 0.1.6 → 0.1.7
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/fesm2022/eduboxpro-studio.mjs +588 -3
- package/fesm2022/eduboxpro-studio.mjs.map +1 -1
- package/index.d.ts +408 -3
- package/package.json +1 -1
- package/src/styles/studio.scss +5 -1
package/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as _angular_core from '@angular/core';
|
|
2
2
|
import { InjectionToken, EnvironmentProviders, ElementRef, Signal } from '@angular/core';
|
|
3
|
-
import { icons } from 'lucide-angular';
|
|
4
3
|
import { ControlValueAccessor } from '@angular/forms';
|
|
4
|
+
import { icons } from 'lucide-angular';
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* Theme mode: light or dark
|
|
@@ -174,6 +174,30 @@ interface InputDefaultsConfig {
|
|
|
174
174
|
floatingLabel?: boolean;
|
|
175
175
|
clearable?: boolean;
|
|
176
176
|
}
|
|
177
|
+
/**
|
|
178
|
+
* Checkbox component defaults configuration
|
|
179
|
+
*/
|
|
180
|
+
interface CheckboxDefaultsConfig {
|
|
181
|
+
size?: 'sm' | 'md' | 'lg';
|
|
182
|
+
color?: 'primary' | 'secondary' | 'success' | 'error';
|
|
183
|
+
variant?: 'default' | 'outlined' | 'filled';
|
|
184
|
+
radius?: 'none' | 'sm' | 'md' | 'lg' | 'full';
|
|
185
|
+
labelPosition?: 'left' | 'right';
|
|
186
|
+
}
|
|
187
|
+
/**
|
|
188
|
+
* Textarea component defaults configuration
|
|
189
|
+
*/
|
|
190
|
+
interface TextareaDefaultsConfig {
|
|
191
|
+
variant?: 'outline' | 'filled' | 'underline';
|
|
192
|
+
size?: 'sm' | 'md' | 'lg';
|
|
193
|
+
color?: 'primary' | 'secondary' | 'success' | 'error';
|
|
194
|
+
radius?: 'none' | 'sm' | 'md' | 'lg' | 'full';
|
|
195
|
+
rows?: number;
|
|
196
|
+
autoResize?: boolean;
|
|
197
|
+
resize?: 'none' | 'vertical' | 'horizontal' | 'both';
|
|
198
|
+
showCharCount?: boolean;
|
|
199
|
+
clearable?: boolean;
|
|
200
|
+
}
|
|
177
201
|
/**
|
|
178
202
|
* Components defaults configuration
|
|
179
203
|
*/
|
|
@@ -182,6 +206,8 @@ interface ComponentsConfig {
|
|
|
182
206
|
badge?: BadgeDefaultsConfig;
|
|
183
207
|
switch?: SwitchDefaultsConfig;
|
|
184
208
|
input?: InputDefaultsConfig;
|
|
209
|
+
checkbox?: CheckboxDefaultsConfig;
|
|
210
|
+
textarea?: TextareaDefaultsConfig;
|
|
185
211
|
}
|
|
186
212
|
/**
|
|
187
213
|
* Main Studio configuration interface
|
|
@@ -324,6 +350,167 @@ declare class ButtonComponent {
|
|
|
324
350
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ButtonComponent, "studio-button", never, { "variantInput": { "alias": "variant"; "required": false; "isSignal": true; }; "sizeInput": { "alias": "size"; "required": false; "isSignal": true; }; "colorInput": { "alias": "color"; "required": false; "isSignal": true; }; "radiusInput": { "alias": "radius"; "required": false; "isSignal": true; }; "shadowInput": { "alias": "shadow"; "required": false; "isSignal": true; }; "compactInput": { "alias": "compact"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "loadingText": { "alias": "loadingText"; "required": false; "isSignal": true; }; "fullWidth": { "alias": "fullWidth"; "required": false; "isSignal": true; }; "type": { "alias": "type"; "required": false; "isSignal": true; }; "icon": { "alias": "icon"; "required": false; "isSignal": true; }; "iconPosition": { "alias": "iconPosition"; "required": false; "isSignal": true; }; "href": { "alias": "href"; "required": false; "isSignal": true; }; "target": { "alias": "target"; "required": false; "isSignal": true; }; "badge": { "alias": "badge"; "required": false; "isSignal": true; }; "badgeColor": { "alias": "badgeColor"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; }, { "clicked": "clicked"; }, never, ["*"], true, never>;
|
|
325
351
|
}
|
|
326
352
|
|
|
353
|
+
/**
|
|
354
|
+
* Checkbox component for selecting boolean values
|
|
355
|
+
*
|
|
356
|
+
* @example
|
|
357
|
+
* <studio-checkbox
|
|
358
|
+
* [(ngModel)]="accepted"
|
|
359
|
+
* label="I accept terms and conditions"
|
|
360
|
+
* (changed)="onAccept($event)"
|
|
361
|
+
* />
|
|
362
|
+
*/
|
|
363
|
+
declare class CheckboxComponent implements ControlValueAccessor {
|
|
364
|
+
private readonly configService;
|
|
365
|
+
private readonly checkboxDefaults;
|
|
366
|
+
/**
|
|
367
|
+
* Size of the checkbox
|
|
368
|
+
*/
|
|
369
|
+
size: _angular_core.InputSignal<CheckboxSize>;
|
|
370
|
+
/**
|
|
371
|
+
* Color scheme
|
|
372
|
+
*/
|
|
373
|
+
color: _angular_core.InputSignal<CheckboxColor>;
|
|
374
|
+
/**
|
|
375
|
+
* Visual variant
|
|
376
|
+
*/
|
|
377
|
+
variant: _angular_core.InputSignal<CheckboxVariant>;
|
|
378
|
+
/**
|
|
379
|
+
* Border radius
|
|
380
|
+
*/
|
|
381
|
+
radius: _angular_core.InputSignal<CheckboxRadius>;
|
|
382
|
+
/**
|
|
383
|
+
* Label text
|
|
384
|
+
*/
|
|
385
|
+
label: _angular_core.InputSignal<string | undefined>;
|
|
386
|
+
/**
|
|
387
|
+
* Label position relative to checkbox
|
|
388
|
+
*/
|
|
389
|
+
labelPosition: _angular_core.InputSignal<"left" | "right">;
|
|
390
|
+
/**
|
|
391
|
+
* Additional description text
|
|
392
|
+
*/
|
|
393
|
+
description: _angular_core.InputSignal<string | undefined>;
|
|
394
|
+
/**
|
|
395
|
+
* Helper text
|
|
396
|
+
*/
|
|
397
|
+
hint: _angular_core.InputSignal<string | undefined>;
|
|
398
|
+
/**
|
|
399
|
+
* Required field
|
|
400
|
+
*/
|
|
401
|
+
required: _angular_core.InputSignal<boolean>;
|
|
402
|
+
/**
|
|
403
|
+
* Error state
|
|
404
|
+
*/
|
|
405
|
+
error: _angular_core.InputSignal<boolean>;
|
|
406
|
+
/**
|
|
407
|
+
* Error message
|
|
408
|
+
*/
|
|
409
|
+
errorMessage: _angular_core.InputSignal<string | undefined>;
|
|
410
|
+
/**
|
|
411
|
+
* Disabled state
|
|
412
|
+
*/
|
|
413
|
+
disabled: _angular_core.InputSignal<boolean>;
|
|
414
|
+
/**
|
|
415
|
+
* Readonly state
|
|
416
|
+
*/
|
|
417
|
+
readonly: _angular_core.InputSignal<boolean>;
|
|
418
|
+
/**
|
|
419
|
+
* Indeterminate state (for "select all" checkboxes)
|
|
420
|
+
*/
|
|
421
|
+
indeterminate: _angular_core.InputSignal<boolean>;
|
|
422
|
+
/**
|
|
423
|
+
* Name attribute for form control
|
|
424
|
+
*/
|
|
425
|
+
name: _angular_core.InputSignal<string | undefined>;
|
|
426
|
+
/**
|
|
427
|
+
* Tab index
|
|
428
|
+
*/
|
|
429
|
+
tabIndex: _angular_core.InputSignal<number>;
|
|
430
|
+
/**
|
|
431
|
+
* Value for checkbox groups
|
|
432
|
+
*/
|
|
433
|
+
value: _angular_core.InputSignal<any>;
|
|
434
|
+
/**
|
|
435
|
+
* Emitted when checkbox state changes
|
|
436
|
+
*/
|
|
437
|
+
changed: _angular_core.OutputEmitterRef<boolean>;
|
|
438
|
+
/**
|
|
439
|
+
* Internal checked state
|
|
440
|
+
*/
|
|
441
|
+
protected internalChecked: _angular_core.WritableSignal<boolean>;
|
|
442
|
+
/**
|
|
443
|
+
* Internal focus state
|
|
444
|
+
*/
|
|
445
|
+
protected isFocused: _angular_core.WritableSignal<boolean>;
|
|
446
|
+
/**
|
|
447
|
+
* Unique ID for accessibility
|
|
448
|
+
*/
|
|
449
|
+
protected checkboxId: _angular_core.WritableSignal<string>;
|
|
450
|
+
/**
|
|
451
|
+
* Host CSS classes
|
|
452
|
+
*/
|
|
453
|
+
protected hostClasses: _angular_core.Signal<{
|
|
454
|
+
[x: string]: boolean;
|
|
455
|
+
'studio-checkbox-wrapper': boolean;
|
|
456
|
+
'studio-checkbox-wrapper--disabled': boolean;
|
|
457
|
+
'studio-checkbox-wrapper--error': boolean;
|
|
458
|
+
'studio-checkbox-wrapper--focused': boolean;
|
|
459
|
+
'studio-checkbox-wrapper--label-left': boolean;
|
|
460
|
+
}>;
|
|
461
|
+
/**
|
|
462
|
+
* Checkbox element CSS classes
|
|
463
|
+
*/
|
|
464
|
+
protected checkboxClasses: _angular_core.Signal<{
|
|
465
|
+
[x: string]: boolean;
|
|
466
|
+
'studio-checkbox': boolean;
|
|
467
|
+
'studio-checkbox--checked': boolean;
|
|
468
|
+
'studio-checkbox--indeterminate': boolean;
|
|
469
|
+
'studio-checkbox--disabled': boolean;
|
|
470
|
+
'studio-checkbox--error': boolean;
|
|
471
|
+
}>;
|
|
472
|
+
/**
|
|
473
|
+
* Show error message
|
|
474
|
+
*/
|
|
475
|
+
protected showError: _angular_core.Signal<string | false | undefined>;
|
|
476
|
+
/**
|
|
477
|
+
* Show hint
|
|
478
|
+
*/
|
|
479
|
+
protected showHint: _angular_core.Signal<string | false | undefined>;
|
|
480
|
+
/**
|
|
481
|
+
* ARIA checked state
|
|
482
|
+
*/
|
|
483
|
+
protected ariaChecked: _angular_core.Signal<"mixed" | "true" | "false">;
|
|
484
|
+
private onChange;
|
|
485
|
+
private onTouched;
|
|
486
|
+
writeValue(value: boolean): void;
|
|
487
|
+
registerOnChange(fn: (value: boolean) => void): void;
|
|
488
|
+
registerOnTouched(fn: () => void): void;
|
|
489
|
+
setDisabledState(isDisabled: boolean): void;
|
|
490
|
+
/**
|
|
491
|
+
* Handle checkbox toggle
|
|
492
|
+
*/
|
|
493
|
+
protected handleChange(event: Event): void;
|
|
494
|
+
/**
|
|
495
|
+
* Handle focus
|
|
496
|
+
*/
|
|
497
|
+
protected handleFocus(): void;
|
|
498
|
+
/**
|
|
499
|
+
* Handle blur
|
|
500
|
+
*/
|
|
501
|
+
protected handleBlur(): void;
|
|
502
|
+
/**
|
|
503
|
+
* Handle label click
|
|
504
|
+
*/
|
|
505
|
+
protected handleLabelClick(event: Event): void;
|
|
506
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<CheckboxComponent, never>;
|
|
507
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<CheckboxComponent, "studio-checkbox", never, { "size": { "alias": "size"; "required": false; "isSignal": true; }; "color": { "alias": "color"; "required": false; "isSignal": true; }; "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "radius": { "alias": "radius"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "labelPosition": { "alias": "labelPosition"; "required": false; "isSignal": true; }; "description": { "alias": "description"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "error": { "alias": "error"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "readonly": { "alias": "readonly"; "required": false; "isSignal": true; }; "indeterminate": { "alias": "indeterminate"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "tabIndex": { "alias": "tabIndex"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; }, { "changed": "changed"; }, never, never, true, never>;
|
|
508
|
+
}
|
|
509
|
+
type CheckboxSize = 'sm' | 'md' | 'lg';
|
|
510
|
+
type CheckboxColor = 'primary' | 'secondary' | 'success' | 'error';
|
|
511
|
+
type CheckboxVariant = 'default' | 'outlined' | 'filled';
|
|
512
|
+
type CheckboxRadius = 'none' | 'sm' | 'md' | 'lg' | 'full';
|
|
513
|
+
|
|
327
514
|
/**
|
|
328
515
|
* Icon component with Lucide icons support
|
|
329
516
|
*
|
|
@@ -491,6 +678,224 @@ declare class SwitchComponent {
|
|
|
491
678
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<SwitchComponent, "studio-switch", never, { "checked": { "alias": "checked"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "labelPosition": { "alias": "labelPosition"; "required": false; "isSignal": true; }; "showIcons": { "alias": "showIcons"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "sizeInput": { "alias": "size"; "required": false; "isSignal": true; }; "colorInput": { "alias": "color"; "required": false; "isSignal": true; }; }, { "checked": "checkedChange"; "checkedChange": "checkedChange"; }, never, never, true, never>;
|
|
492
679
|
}
|
|
493
680
|
|
|
681
|
+
/**
|
|
682
|
+
* Textarea component for multi-line text input
|
|
683
|
+
*
|
|
684
|
+
* @example
|
|
685
|
+
* <studio-textarea
|
|
686
|
+
* [(ngModel)]="message"
|
|
687
|
+
* label="Your message"
|
|
688
|
+
* placeholder="Enter your message..."
|
|
689
|
+
* [rows]="4"
|
|
690
|
+
* />
|
|
691
|
+
*/
|
|
692
|
+
declare class TextareaComponent implements ControlValueAccessor {
|
|
693
|
+
private readonly configService;
|
|
694
|
+
private readonly textareaDefaults;
|
|
695
|
+
variant: _angular_core.InputSignal<TextareaVariant>;
|
|
696
|
+
size: _angular_core.InputSignal<TextareaSize>;
|
|
697
|
+
color: _angular_core.InputSignal<TextareaColor>;
|
|
698
|
+
radius: _angular_core.InputSignal<TextareaRadius>;
|
|
699
|
+
/**
|
|
700
|
+
* Label text
|
|
701
|
+
*/
|
|
702
|
+
label: _angular_core.InputSignal<string | undefined>;
|
|
703
|
+
/**
|
|
704
|
+
* Floating label (moves up when focused/filled)
|
|
705
|
+
*/
|
|
706
|
+
floatingLabel: _angular_core.InputSignal<boolean>;
|
|
707
|
+
/**
|
|
708
|
+
* Placeholder text
|
|
709
|
+
*/
|
|
710
|
+
placeholder: _angular_core.InputSignal<string | undefined>;
|
|
711
|
+
/**
|
|
712
|
+
* Helper text
|
|
713
|
+
*/
|
|
714
|
+
hint: _angular_core.InputSignal<string | undefined>;
|
|
715
|
+
/**
|
|
716
|
+
* Number of visible text rows
|
|
717
|
+
*/
|
|
718
|
+
rows: _angular_core.InputSignal<number>;
|
|
719
|
+
/**
|
|
720
|
+
* Minimum rows for auto-resize
|
|
721
|
+
*/
|
|
722
|
+
minRows: _angular_core.InputSignal<number | undefined>;
|
|
723
|
+
/**
|
|
724
|
+
* Maximum rows for auto-resize
|
|
725
|
+
*/
|
|
726
|
+
maxRows: _angular_core.InputSignal<number | undefined>;
|
|
727
|
+
/**
|
|
728
|
+
* Enable auto-resize based on content
|
|
729
|
+
*/
|
|
730
|
+
autoResize: _angular_core.InputSignal<boolean>;
|
|
731
|
+
/**
|
|
732
|
+
* Resize behavior
|
|
733
|
+
*/
|
|
734
|
+
resize: _angular_core.InputSignal<"none" | "vertical" | "horizontal" | "both">;
|
|
735
|
+
/**
|
|
736
|
+
* Maximum character length
|
|
737
|
+
*/
|
|
738
|
+
maxLength: _angular_core.InputSignal<number | undefined>;
|
|
739
|
+
/**
|
|
740
|
+
* Show character counter
|
|
741
|
+
*/
|
|
742
|
+
showCharCount: _angular_core.InputSignal<boolean>;
|
|
743
|
+
/**
|
|
744
|
+
* Character counter position
|
|
745
|
+
*/
|
|
746
|
+
charCountPosition: _angular_core.InputSignal<"bottom-right" | "bottom-left">;
|
|
747
|
+
/**
|
|
748
|
+
* Required field
|
|
749
|
+
*/
|
|
750
|
+
required: _angular_core.InputSignal<boolean>;
|
|
751
|
+
/**
|
|
752
|
+
* Minimum character length
|
|
753
|
+
*/
|
|
754
|
+
minLength: _angular_core.InputSignal<number | undefined>;
|
|
755
|
+
/**
|
|
756
|
+
* Error state
|
|
757
|
+
*/
|
|
758
|
+
error: _angular_core.InputSignal<boolean>;
|
|
759
|
+
/**
|
|
760
|
+
* Error message
|
|
761
|
+
*/
|
|
762
|
+
errorMessage: _angular_core.InputSignal<string | undefined>;
|
|
763
|
+
/**
|
|
764
|
+
* Disabled state
|
|
765
|
+
*/
|
|
766
|
+
disabled: _angular_core.InputSignal<boolean>;
|
|
767
|
+
/**
|
|
768
|
+
* Readonly state
|
|
769
|
+
*/
|
|
770
|
+
readonly: _angular_core.InputSignal<boolean>;
|
|
771
|
+
/**
|
|
772
|
+
* Full width (100% of parent)
|
|
773
|
+
*/
|
|
774
|
+
fullWidth: _angular_core.InputSignal<boolean>;
|
|
775
|
+
/**
|
|
776
|
+
* Name attribute for form control
|
|
777
|
+
*/
|
|
778
|
+
name: _angular_core.InputSignal<string | undefined>;
|
|
779
|
+
/**
|
|
780
|
+
* Autocomplete attribute
|
|
781
|
+
*/
|
|
782
|
+
autocomplete: _angular_core.InputSignal<string | undefined>;
|
|
783
|
+
/**
|
|
784
|
+
* Spellcheck attribute
|
|
785
|
+
*/
|
|
786
|
+
spellcheck: _angular_core.InputSignal<boolean>;
|
|
787
|
+
/**
|
|
788
|
+
* Show clear button
|
|
789
|
+
*/
|
|
790
|
+
clearable: _angular_core.InputSignal<boolean>;
|
|
791
|
+
/**
|
|
792
|
+
* Loading state
|
|
793
|
+
*/
|
|
794
|
+
loading: _angular_core.InputSignal<boolean>;
|
|
795
|
+
/**
|
|
796
|
+
* Emitted when value changes
|
|
797
|
+
*/
|
|
798
|
+
changed: _angular_core.OutputEmitterRef<string>;
|
|
799
|
+
/**
|
|
800
|
+
* Emitted on focus
|
|
801
|
+
*/
|
|
802
|
+
focused: _angular_core.OutputEmitterRef<FocusEvent>;
|
|
803
|
+
/**
|
|
804
|
+
* Emitted on blur
|
|
805
|
+
*/
|
|
806
|
+
blurred: _angular_core.OutputEmitterRef<FocusEvent>;
|
|
807
|
+
/**
|
|
808
|
+
* Emitted on key press
|
|
809
|
+
*/
|
|
810
|
+
keyPressed: _angular_core.OutputEmitterRef<KeyboardEvent>;
|
|
811
|
+
/**
|
|
812
|
+
* Internal value
|
|
813
|
+
*/
|
|
814
|
+
protected internalValue: _angular_core.WritableSignal<string>;
|
|
815
|
+
/**
|
|
816
|
+
* Internal focus state
|
|
817
|
+
*/
|
|
818
|
+
protected isFocused: _angular_core.WritableSignal<boolean>;
|
|
819
|
+
/**
|
|
820
|
+
* Unique ID for accessibility
|
|
821
|
+
*/
|
|
822
|
+
protected textareaId: _angular_core.WritableSignal<string>;
|
|
823
|
+
/**
|
|
824
|
+
* Textarea element reference
|
|
825
|
+
*/
|
|
826
|
+
protected textareaEl: _angular_core.Signal<ElementRef<HTMLTextAreaElement> | undefined>;
|
|
827
|
+
protected hostClasses: _angular_core.Signal<string>;
|
|
828
|
+
/**
|
|
829
|
+
* Textarea element CSS classes
|
|
830
|
+
*/
|
|
831
|
+
protected textareaClasses: _angular_core.Signal<string>;
|
|
832
|
+
/**
|
|
833
|
+
* Show error message
|
|
834
|
+
*/
|
|
835
|
+
protected showError: _angular_core.Signal<string | false | undefined>;
|
|
836
|
+
/**
|
|
837
|
+
* Show hint
|
|
838
|
+
*/
|
|
839
|
+
protected showHint: _angular_core.Signal<string | false | undefined>;
|
|
840
|
+
/**
|
|
841
|
+
* Character count text
|
|
842
|
+
*/
|
|
843
|
+
protected charCountText: _angular_core.Signal<string>;
|
|
844
|
+
/**
|
|
845
|
+
* Is character limit exceeded
|
|
846
|
+
*/
|
|
847
|
+
protected isCharLimitExceeded: _angular_core.Signal<boolean>;
|
|
848
|
+
/**
|
|
849
|
+
* Computed placeholder (empty if floating label)
|
|
850
|
+
*/
|
|
851
|
+
protected computedPlaceholder: _angular_core.Signal<string | undefined>;
|
|
852
|
+
/**
|
|
853
|
+
* Show floating label in "up" position
|
|
854
|
+
*/
|
|
855
|
+
protected showFloatingLabelUp: _angular_core.Signal<boolean>;
|
|
856
|
+
private onChange;
|
|
857
|
+
private onTouched;
|
|
858
|
+
writeValue(value: string): void;
|
|
859
|
+
registerOnChange(fn: (value: string) => void): void;
|
|
860
|
+
registerOnTouched(fn: () => void): void;
|
|
861
|
+
setDisabledState(isDisabled: boolean): void;
|
|
862
|
+
constructor();
|
|
863
|
+
/**
|
|
864
|
+
* Handle textarea input
|
|
865
|
+
*/
|
|
866
|
+
protected handleInput(event: Event): void;
|
|
867
|
+
/**
|
|
868
|
+
* Handle focus
|
|
869
|
+
*/
|
|
870
|
+
protected handleFocus(event: FocusEvent): void;
|
|
871
|
+
/**
|
|
872
|
+
* Handle blur
|
|
873
|
+
*/
|
|
874
|
+
protected handleBlur(event: FocusEvent): void;
|
|
875
|
+
/**
|
|
876
|
+
* Handle key press
|
|
877
|
+
*/
|
|
878
|
+
protected handleKeyPress(event: KeyboardEvent): void;
|
|
879
|
+
/**
|
|
880
|
+
* Clear textarea value
|
|
881
|
+
*/
|
|
882
|
+
protected handleClear(): void;
|
|
883
|
+
/**
|
|
884
|
+
* Adjust textarea height for auto-resize
|
|
885
|
+
*/
|
|
886
|
+
private adjustHeightIfNeeded;
|
|
887
|
+
/**
|
|
888
|
+
* Adjust textarea height based on content
|
|
889
|
+
*/
|
|
890
|
+
private adjustHeight;
|
|
891
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<TextareaComponent, never>;
|
|
892
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<TextareaComponent, "studio-textarea", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "color": { "alias": "color"; "required": false; "isSignal": true; }; "radius": { "alias": "radius"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "floatingLabel": { "alias": "floatingLabel"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "rows": { "alias": "rows"; "required": false; "isSignal": true; }; "minRows": { "alias": "minRows"; "required": false; "isSignal": true; }; "maxRows": { "alias": "maxRows"; "required": false; "isSignal": true; }; "autoResize": { "alias": "autoResize"; "required": false; "isSignal": true; }; "resize": { "alias": "resize"; "required": false; "isSignal": true; }; "maxLength": { "alias": "maxLength"; "required": false; "isSignal": true; }; "showCharCount": { "alias": "showCharCount"; "required": false; "isSignal": true; }; "charCountPosition": { "alias": "charCountPosition"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "minLength": { "alias": "minLength"; "required": false; "isSignal": true; }; "error": { "alias": "error"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "readonly": { "alias": "readonly"; "required": false; "isSignal": true; }; "fullWidth": { "alias": "fullWidth"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "autocomplete": { "alias": "autocomplete"; "required": false; "isSignal": true; }; "spellcheck": { "alias": "spellcheck"; "required": false; "isSignal": true; }; "clearable": { "alias": "clearable"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; }, { "changed": "changed"; "focused": "focused"; "blurred": "blurred"; "keyPressed": "keyPressed"; }, never, never, true, never>;
|
|
893
|
+
}
|
|
894
|
+
type TextareaVariant = 'outline' | 'filled' | 'underline';
|
|
895
|
+
type TextareaSize = 'sm' | 'md' | 'lg';
|
|
896
|
+
type TextareaColor = 'primary' | 'secondary' | 'success' | 'error';
|
|
897
|
+
type TextareaRadius = 'none' | 'sm' | 'md' | 'lg' | 'full';
|
|
898
|
+
|
|
494
899
|
/**
|
|
495
900
|
* Theme toggle switch with sun/moon icons
|
|
496
901
|
*
|
|
@@ -608,5 +1013,5 @@ declare function loadGoogleFonts(fonts: Array<{
|
|
|
608
1013
|
display?: 'auto' | 'block' | 'swap' | 'fallback' | 'optional';
|
|
609
1014
|
}>): void;
|
|
610
1015
|
|
|
611
|
-
export { BadgeComponent, ButtonComponent, IconComponent, InputComponent, STUDIO_CONFIG, StudioConfigService, SwitchComponent, ThemeSwitchComponent, classNames, isSafeUrl, loadGoogleFont, loadGoogleFonts, provideStudioConfig, provideStudioIcons, sanitizeUrl, withConfigDefault };
|
|
612
|
-
export type { BadgeDefaultsConfig, ButtonDefaultsConfig, ColorConfig, ComponentsConfig, InputDefaultsConfig, InputMode, InputType, StudioConfig, StudioThemeConfig, SwitchDefaultsConfig, ThemeMode };
|
|
1016
|
+
export { BadgeComponent, ButtonComponent, CheckboxComponent, IconComponent, InputComponent, STUDIO_CONFIG, StudioConfigService, SwitchComponent, TextareaComponent, ThemeSwitchComponent, classNames, isSafeUrl, loadGoogleFont, loadGoogleFonts, provideStudioConfig, provideStudioIcons, sanitizeUrl, withConfigDefault };
|
|
1017
|
+
export type { BadgeDefaultsConfig, ButtonDefaultsConfig, CheckboxColor, CheckboxDefaultsConfig, CheckboxRadius, CheckboxSize, CheckboxVariant, ColorConfig, ComponentsConfig, InputDefaultsConfig, InputMode, InputType, StudioConfig, StudioThemeConfig, SwitchDefaultsConfig, TextareaColor, TextareaDefaultsConfig, TextareaRadius, TextareaSize, TextareaVariant, ThemeMode };
|
package/package.json
CHANGED
package/src/styles/studio.scss
CHANGED
|
@@ -20,10 +20,14 @@ studio-input,
|
|
|
20
20
|
studio-badge,
|
|
21
21
|
studio-switch,
|
|
22
22
|
studio-theme-switch,
|
|
23
|
+
studio-checkbox,
|
|
24
|
+
studio-textarea,
|
|
23
25
|
studio-button *,
|
|
24
26
|
studio-input *,
|
|
25
27
|
studio-badge *,
|
|
26
28
|
studio-switch *,
|
|
27
|
-
studio-theme-switch
|
|
29
|
+
studio-theme-switch *,
|
|
30
|
+
studio-checkbox *,
|
|
31
|
+
studio-textarea * {
|
|
28
32
|
font-family: var(--studio-font-family) !important;
|
|
29
33
|
}
|