@juligc99/loro-ui 0.0.14 → 0.0.16
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/juligc99-loro-ui.mjs +174 -1925
- package/fesm2022/juligc99-loro-ui.mjs.map +1 -1
- package/package.json +12 -10
- package/types/juligc99-loro-ui.d.ts +132 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@juligc99/loro-ui",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.16",
|
|
4
4
|
"description": "Loro UI design system and Angular component library.",
|
|
5
5
|
"author": "juligc99",
|
|
6
6
|
"license": "MIT",
|
|
@@ -26,6 +26,17 @@
|
|
|
26
26
|
"access": "public",
|
|
27
27
|
"registry": "https://registry.npmjs.org/"
|
|
28
28
|
},
|
|
29
|
+
"exports": {
|
|
30
|
+
".": {
|
|
31
|
+
"types": "./types/juligc99-loro-ui.d.ts",
|
|
32
|
+
"default": "./fesm2022/juligc99-loro-ui.mjs"
|
|
33
|
+
},
|
|
34
|
+
"./package.json": {
|
|
35
|
+
"default": "./package.json"
|
|
36
|
+
},
|
|
37
|
+
"./design-tokens/loro-theme.scss": "./design-tokens/loro-theme.scss",
|
|
38
|
+
"./styles/breakpoints": "./styles/_breakpoints.scss"
|
|
39
|
+
},
|
|
29
40
|
"peerDependencies": {
|
|
30
41
|
"@angular/aria": ">=21 <23",
|
|
31
42
|
"@angular/common": ">=21 <23",
|
|
@@ -45,14 +56,5 @@
|
|
|
45
56
|
],
|
|
46
57
|
"module": "fesm2022/juligc99-loro-ui.mjs",
|
|
47
58
|
"typings": "types/juligc99-loro-ui.d.ts",
|
|
48
|
-
"exports": {
|
|
49
|
-
"./package.json": {
|
|
50
|
-
"default": "./package.json"
|
|
51
|
-
},
|
|
52
|
-
".": {
|
|
53
|
-
"types": "./types/juligc99-loro-ui.d.ts",
|
|
54
|
-
"default": "./fesm2022/juligc99-loro-ui.mjs"
|
|
55
|
-
}
|
|
56
|
-
},
|
|
57
59
|
"type": "module"
|
|
58
60
|
}
|
|
@@ -952,12 +952,141 @@ declare class LoroAppNav {
|
|
|
952
952
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LoroAppNav, "loro-app-nav", never, { "items": { "alias": "items"; "required": false; "isSignal": true; }; "utilityItems": { "alias": "utilityItems"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "showUtilityItems": { "alias": "showUtilityItems"; "required": false; "isSignal": true; }; "compactDesktop": { "alias": "compactDesktop"; "required": false; "isSignal": true; }; }, { "itemClick": "itemClick"; "utilityItemClick": "utilityItemClick"; "navItemClick": "navItemClick"; }, never, never, true, never>;
|
|
953
953
|
}
|
|
954
954
|
|
|
955
|
+
/**
|
|
956
|
+
* LoroButton Type Definitions
|
|
957
|
+
*
|
|
958
|
+
* Centralized type definitions for the LoroButton component.
|
|
959
|
+
* Use these types for consistency across the application.
|
|
960
|
+
*
|
|
961
|
+
* @example
|
|
962
|
+
* const config: LoroButtonConfig = {
|
|
963
|
+
* variant: 'primary',
|
|
964
|
+
* size: 'md',
|
|
965
|
+
* disabled: false,
|
|
966
|
+
* };
|
|
967
|
+
*/
|
|
968
|
+
/**
|
|
969
|
+
* Visual variant style of the button
|
|
970
|
+
* @type {'primary' | 'outline' | 'ghost' | 'danger' | 'soft' | 'social' | 'action' | 'navigation'}
|
|
971
|
+
*/
|
|
955
972
|
type LoroButtonVariant = 'primary' | 'outline' | 'ghost' | 'danger' | 'soft' | 'social' | 'action' | 'navigation';
|
|
973
|
+
/**
|
|
974
|
+
* Button visual type (semantic grouping)
|
|
975
|
+
* @type {'primary' | 'secondary' | 'tertiary'}
|
|
976
|
+
*/
|
|
956
977
|
type LoroButtonType = 'primary' | 'secondary' | 'tertiary';
|
|
978
|
+
/**
|
|
979
|
+
* Button color theme
|
|
980
|
+
* @type {'primary' | 'secondary' | 'tertiary' | 'danger'}
|
|
981
|
+
*/
|
|
957
982
|
type LoroButtonColor = 'primary' | 'secondary' | 'tertiary' | 'danger';
|
|
983
|
+
/**
|
|
984
|
+
* Button size preset
|
|
985
|
+
* @type {'sm' | 'md' | 'lg'}
|
|
986
|
+
*/
|
|
958
987
|
type LoroButtonSize = 'sm' | 'md' | 'lg';
|
|
988
|
+
/**
|
|
989
|
+
* Button width behavior
|
|
990
|
+
* @type {'fit-content' | 'full'}
|
|
991
|
+
*/
|
|
959
992
|
type LoroButtonWidth = 'fit-content' | 'full';
|
|
993
|
+
/**
|
|
994
|
+
* Icon display mode within the button
|
|
995
|
+
* @type {'none' | 'with-icon' | 'only-icon'}
|
|
996
|
+
*/
|
|
960
997
|
type LoroButtonIconMode = 'none' | 'with-icon' | 'only-icon';
|
|
998
|
+
/**
|
|
999
|
+
* Button HTML type
|
|
1000
|
+
* @type {'button' | 'submit' | 'reset'}
|
|
1001
|
+
*/
|
|
1002
|
+
type LoroButtonHtmlType = 'button' | 'submit' | 'reset';
|
|
1003
|
+
|
|
1004
|
+
/**
|
|
1005
|
+
* LoroButton Constants
|
|
1006
|
+
*
|
|
1007
|
+
* Default values, valid options, and configuration constants for the LoroButton component.
|
|
1008
|
+
* Update these to maintain consistency across all button usage.
|
|
1009
|
+
*/
|
|
1010
|
+
|
|
1011
|
+
/**
|
|
1012
|
+
* Default input values for LoroButton
|
|
1013
|
+
*/
|
|
1014
|
+
declare const LORO_BUTTON_DEFAULTS: {
|
|
1015
|
+
readonly text: "";
|
|
1016
|
+
readonly label: "";
|
|
1017
|
+
readonly variant: "primary";
|
|
1018
|
+
readonly type: "primary";
|
|
1019
|
+
readonly color: "primary";
|
|
1020
|
+
readonly size: "md";
|
|
1021
|
+
readonly fullWidth: false;
|
|
1022
|
+
readonly buttonWidth: "fit-content";
|
|
1023
|
+
readonly disabled: false;
|
|
1024
|
+
readonly loading: false;
|
|
1025
|
+
readonly selected: false;
|
|
1026
|
+
readonly htmlType: "button";
|
|
1027
|
+
readonly iconMode: "none";
|
|
1028
|
+
readonly socialMobileCompact: true;
|
|
1029
|
+
readonly iconSize: 23;
|
|
1030
|
+
readonly iconButtonSize: null;
|
|
1031
|
+
readonly iconColor: "";
|
|
1032
|
+
};
|
|
1033
|
+
/**
|
|
1034
|
+
* Valid options for button variants
|
|
1035
|
+
*/
|
|
1036
|
+
declare const LORO_BUTTON_VARIANTS: readonly LoroButtonVariant[];
|
|
1037
|
+
/**
|
|
1038
|
+
* Valid options for button types
|
|
1039
|
+
*/
|
|
1040
|
+
declare const LORO_BUTTON_TYPES: readonly LoroButtonType[];
|
|
1041
|
+
/**
|
|
1042
|
+
* Valid options for button colors
|
|
1043
|
+
*/
|
|
1044
|
+
declare const LORO_BUTTON_COLORS: readonly LoroButtonColor[];
|
|
1045
|
+
/**
|
|
1046
|
+
* Valid options for button sizes
|
|
1047
|
+
*/
|
|
1048
|
+
declare const LORO_BUTTON_SIZES: readonly LoroButtonSize[];
|
|
1049
|
+
/**
|
|
1050
|
+
* Valid options for icon modes
|
|
1051
|
+
*/
|
|
1052
|
+
declare const LORO_BUTTON_ICON_MODES: readonly LoroButtonIconMode[];
|
|
1053
|
+
/**
|
|
1054
|
+
* CSS class names used by LoroButton (BEM notation)
|
|
1055
|
+
*/
|
|
1056
|
+
declare const LORO_BUTTON_CLASSES: {
|
|
1057
|
+
readonly container: "loro-button";
|
|
1058
|
+
readonly variant: (variant: LoroButtonVariant) => string;
|
|
1059
|
+
readonly size: (size: LoroButtonSize) => string;
|
|
1060
|
+
readonly color: (color: LoroButtonColor) => string;
|
|
1061
|
+
readonly width: (width: LoroButtonWidth) => "loro-button--full" | undefined;
|
|
1062
|
+
readonly state: {
|
|
1063
|
+
readonly disabled: "loro-button--disabled";
|
|
1064
|
+
readonly loading: "loro-button--loading";
|
|
1065
|
+
readonly selected: "loro-button--selected";
|
|
1066
|
+
};
|
|
1067
|
+
readonly elements: {
|
|
1068
|
+
readonly label: "loro-button__label";
|
|
1069
|
+
readonly spinner: "loro-button__spinner";
|
|
1070
|
+
readonly srStatus: "loro-button__sr-status";
|
|
1071
|
+
};
|
|
1072
|
+
};
|
|
1073
|
+
|
|
1074
|
+
/**
|
|
1075
|
+
* LoroButton Component
|
|
1076
|
+
*
|
|
1077
|
+
* A versatile, accessible button component with multiple variants, sizes, and states.
|
|
1078
|
+
* Follows Angular 21 best practices with signals, OnPush change detection, and semantic HTML.
|
|
1079
|
+
*
|
|
1080
|
+
* @example
|
|
1081
|
+
* ```html
|
|
1082
|
+
* <loro-button
|
|
1083
|
+
* [text]="'Click me'"
|
|
1084
|
+
* variant="primary"
|
|
1085
|
+
* size="md"
|
|
1086
|
+
* (change)="onButtonClick()"
|
|
1087
|
+
* />
|
|
1088
|
+
* ```
|
|
1089
|
+
*/
|
|
961
1090
|
declare class LoroButton {
|
|
962
1091
|
label: _angular_core.InputSignal<string>;
|
|
963
1092
|
text: _angular_core.InputSignal<string>;
|
|
@@ -1040,7 +1169,7 @@ declare class LoroAuthSocialButton {
|
|
|
1040
1169
|
outline: _angular_core.InputSignal<boolean>;
|
|
1041
1170
|
selected: _angular_core.InputSignal<boolean>;
|
|
1042
1171
|
iconSize: _angular_core.InputSignal<number>;
|
|
1043
|
-
protected readonly nativeIconSrc: _angular_core.Signal<"
|
|
1172
|
+
protected readonly nativeIconSrc: _angular_core.Signal<"assets/loro-ui/icons/apple.svg" | "assets/loro-ui/icons/google.svg" | "">;
|
|
1044
1173
|
protected releaseFocus(event: Event): void;
|
|
1045
1174
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<LoroAuthSocialButton, never>;
|
|
1046
1175
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LoroAuthSocialButton, "loro-auth-social-button", never, { "icon": { "alias": "icon"; "required": true; "isSignal": true; }; "label": { "alias": "label"; "required": true; "isSignal": true; }; "outline": { "alias": "outline"; "required": false; "isSignal": true; }; "selected": { "alias": "selected"; "required": false; "isSignal": true; }; "iconSize": { "alias": "iconSize"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
@@ -1716,5 +1845,5 @@ declare class LoroHapticsService {
|
|
|
1716
1845
|
static ɵprov: _angular_core.ɵɵInjectableDeclaration<LoroHapticsService>;
|
|
1717
1846
|
}
|
|
1718
1847
|
|
|
1719
|
-
export { Footer, LORO_ICON_ASSETS, LORO_ICON_LEGACY_NAMES, LORO_ICON_PATHS, LORO_IMAGE_ASSETS, LORO_IMAGE_LEGACY_NAMES, LORO_IMAGE_PATHS, LoroAccordion, LoroAlert, LoroAppNav, LoroAssistantCard, LoroAuthField, LoroAuthSocialButton, LoroBadge, LoroButton, LoroCard, LoroCardNav, LoroCheckbox, LoroDashboardCard, LoroDivider, LoroDropdown, LoroFilterChip, LoroHapticsService, LoroIcon, LoroImage, LoroInput, LoroModal, LoroNotification, LoroNotificationPanel, LoroNotificationRow, LoroProductRow, LoroProductSection, LoroProfileCard, LoroProfileHero, LoroRadio, LoroSegmentedControl, LoroSelect, LoroSpinner, LoroStatCard, LoroStoreRankCard, LoroSummaryBar, LoroTab, LoroTextArea, LoroToast, LoroToggle, LoroUpload };
|
|
1720
|
-
export type { LoroAlertAnnouncement, LoroAlertVariant, LoroAppNavClick, LoroAppNavItem, LoroAuthFieldState, LoroBadgeVariant, LoroButtonColor, LoroButtonIconMode, LoroButtonSize, LoroButtonType, LoroButtonVariant, LoroButtonWidth, LoroCardJustify, LoroCardNavTrailing, LoroCardNavVariant, LoroCardVariant, LoroDividerAlign, LoroDropdownOption, LoroIconAsset, LoroIconAssetName, LoroIconColor, LoroIconColorToken, LoroIconLegacyName, LoroIconName, LoroIconRenderMode, LoroIconSize, LoroImageAsset, LoroImageAssetName, LoroImageLegacyName, LoroImageName, LoroInputState, LoroInputUnit, LoroInputVariant, LoroModalPlacement, LoroModalSize, LoroNotificationItem, LoroProductRowStatus, LoroProductRowVariant, LoroRadioVariant, LoroSegmentedOption, LoroStatCardVariant, LoroStoreRankCardVariant, LoroTabAlign, LoroTabOption, LoroToastPosition, LoroToastVariant };
|
|
1848
|
+
export { Footer, LORO_BUTTON_CLASSES, LORO_BUTTON_COLORS, LORO_BUTTON_DEFAULTS, LORO_BUTTON_ICON_MODES, LORO_BUTTON_SIZES, LORO_BUTTON_TYPES, LORO_BUTTON_VARIANTS, LORO_ICON_ASSETS, LORO_ICON_LEGACY_NAMES, LORO_ICON_PATHS, LORO_IMAGE_ASSETS, LORO_IMAGE_LEGACY_NAMES, LORO_IMAGE_PATHS, LoroAccordion, LoroAlert, LoroAppNav, LoroAssistantCard, LoroAuthField, LoroAuthSocialButton, LoroBadge, LoroButton, LoroCard, LoroCardNav, LoroCheckbox, LoroDashboardCard, LoroDivider, LoroDropdown, LoroFilterChip, LoroHapticsService, LoroIcon, LoroImage, LoroInput, LoroModal, LoroNotification, LoroNotificationPanel, LoroNotificationRow, LoroProductRow, LoroProductSection, LoroProfileCard, LoroProfileHero, LoroRadio, LoroSegmentedControl, LoroSelect, LoroSpinner, LoroStatCard, LoroStoreRankCard, LoroSummaryBar, LoroTab, LoroTextArea, LoroToast, LoroToggle, LoroUpload };
|
|
1849
|
+
export type { LoroAlertAnnouncement, LoroAlertVariant, LoroAppNavClick, LoroAppNavItem, LoroAuthFieldState, LoroBadgeVariant, LoroButtonColor, LoroButtonHtmlType, LoroButtonIconMode, LoroButtonSize, LoroButtonType, LoroButtonVariant, LoroButtonWidth, LoroCardJustify, LoroCardNavTrailing, LoroCardNavVariant, LoroCardVariant, LoroDividerAlign, LoroDropdownOption, LoroIconAsset, LoroIconAssetName, LoroIconColor, LoroIconColorToken, LoroIconLegacyName, LoroIconName, LoroIconRenderMode, LoroIconSize, LoroImageAsset, LoroImageAssetName, LoroImageLegacyName, LoroImageName, LoroInputState, LoroInputUnit, LoroInputVariant, LoroModalPlacement, LoroModalSize, LoroNotificationItem, LoroProductRowStatus, LoroProductRowVariant, LoroRadioVariant, LoroSegmentedOption, LoroStatCardVariant, LoroStoreRankCardVariant, LoroTabAlign, LoroTabOption, LoroToastPosition, LoroToastVariant };
|