@ecohouse/ui 0.1.11 → 0.1.12

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/dist/index.d.cts CHANGED
@@ -156,6 +156,11 @@ declare function LogOutIcon({ size, color, strokeWidth }: IconProps): react.JSX.
156
156
 
157
157
  declare function MailIcon({ size, color, strokeWidth }: IconProps): react.JSX.Element;
158
158
 
159
+ interface MenuIconProps extends IconProps {
160
+ open?: boolean;
161
+ }
162
+ declare function MenuIcon({ size, color, strokeWidth, open, }: MenuIconProps): react.JSX.Element;
163
+
159
164
  declare function MinusIcon({ size, color, strokeWidth }: IconProps): react.JSX.Element;
160
165
 
161
166
  declare function NavigateIcon({ size, color, strokeWidth }: IconProps): react.JSX.Element;
@@ -236,6 +241,7 @@ declare const icons: {
236
241
  readonly linkedin: typeof LinkedInIcon;
237
242
  readonly logOut: typeof LogOutIcon;
238
243
  readonly mail: typeof MailIcon;
244
+ readonly menu: typeof MenuIcon;
239
245
  readonly minus: typeof MinusIcon;
240
246
  readonly navigate: typeof NavigateIcon;
241
247
  readonly phone: typeof PhoneIcon;
@@ -253,7 +259,7 @@ declare const icons: {
253
259
  type IconName = keyof typeof icons;
254
260
  declare const iconNames: IconName[];
255
261
  declare const iconGroups: {
256
- readonly navigation: readonly ["arrowRight", "chevronDown", "chevronLeft", "home", "navigate"];
262
+ readonly navigation: readonly ["arrowRight", "chevronDown", "chevronLeft", "home", "menu", "navigate"];
257
263
  readonly actions: readonly ["show", "bell", "camera", "key", "check", "checkBadge", "search", "calendar", "calendarOutline", "heart", "star", "starFilled", "minus", "plus"];
258
264
  readonly objects: readonly ["bag", "building", "clock", "user", "usersAlt", "video"];
259
265
  readonly communication: readonly ["mail", "phone"];
@@ -412,6 +418,8 @@ type DatePickerBaseProps = Omit<ViewProps, "style" | "children"> & {
412
418
  formatValue?: (date: Date) => string;
413
419
  /** First day of the week column (0 = Sunday, 1 = Monday). Defaults to Monday. */
414
420
  weekStartsOn?: 0 | 1;
421
+ /** Styles the calendar popup independently from the trigger width. */
422
+ calendarStyle?: StyleProp<ViewStyle>;
415
423
  style?: StyleProp<ViewStyle>;
416
424
  className?: string;
417
425
  };
@@ -863,4 +871,4 @@ declare const textareaTypography: {
863
871
  };
864
872
  };
865
873
 
866
- export { ArrowRightIcon, Avatar, type AvatarMenuItem, type AvatarProps, BRAND_LOGO_COLORS, BRAND_LOGO_DEFAULT_HEIGHT, BRAND_LOGO_DEFAULT_WIDTH, Badge, type BadgeProps, type BadgeVariant, BagIcon, BellIcon, BrandLogo, type BrandLogoProps, type BrandLogoVariant, BuildingIcon, Button, type ButtonProps, type ButtonSize, type ButtonVariant, CalendarIcon, CalendarOutlineIcon, CameraIcon, CheckBadgeIcon, CheckIcon, Checkbox, type CheckboxProps, type CheckboxVariant, ChevronDownIcon, ChevronLeftIcon, ClockIcon, CommentCard, type CommentCardProps, Counter, type CounterProps, DatePicker, type DatePickerProps, type DatePickerRangeProps, type DatePickerSingleProps, type DateRange, FacebookIcon, GlobeIcon, type GreyStep, HeartIcon, HelpCircleIcon, HomeIcon, Icon, type IconByNameProps, type IconComponent, type IconGroup, type IconName, type IconProps, Input, type InputProps, type InputSize, InstagramIcon, KeyIcon, type LanguageOption, LanguageSwitcher, type LanguageSwitcherProps, LayoutGridIcon, LinkedInIcon, LogOutIcon, MailIcon, MenuItem, type MenuItemProps, MinusIcon, NavigateIcon, PhoneIcon, PlusIcon, RatingInput, type RatingInputProps, SearchIcon, SegmentedToggle, type SegmentedToggleOption, type SegmentedToggleProps, Select, type SelectMultipleProps, type SelectOption, type SelectProps, type SelectSingleProps, SettingsIcon, ShowIcon, SidebarIcon, StarFilledIcon, StarIcon, type StarIconProps, StatCard, type StatCardProps, Textarea, type TextareaProps, Toggle, type ToggleProps, UserIcon, UsersAltIcon, VideoIcon, avatarTypography, badgeTypography, buttonTypography, colors, commentCardTypography, counterTypography, datePickerTypography, defaultLanguageOptions, fonts, getIconsByGroup, grey, iconGroupNames, iconGroups, iconNames, icons, inputTypography, languageSwitcherTypography, ratingTypography, segmentedToggleTypography, selectTypography, statCardTypography, textareaTypography };
874
+ export { ArrowRightIcon, Avatar, type AvatarMenuItem, type AvatarProps, BRAND_LOGO_COLORS, BRAND_LOGO_DEFAULT_HEIGHT, BRAND_LOGO_DEFAULT_WIDTH, Badge, type BadgeProps, type BadgeVariant, BagIcon, BellIcon, BrandLogo, type BrandLogoProps, type BrandLogoVariant, BuildingIcon, Button, type ButtonProps, type ButtonSize, type ButtonVariant, CalendarIcon, CalendarOutlineIcon, CameraIcon, CheckBadgeIcon, CheckIcon, Checkbox, type CheckboxProps, type CheckboxVariant, ChevronDownIcon, ChevronLeftIcon, ClockIcon, CommentCard, type CommentCardProps, Counter, type CounterProps, DatePicker, type DatePickerProps, type DatePickerRangeProps, type DatePickerSingleProps, type DateRange, FacebookIcon, GlobeIcon, type GreyStep, HeartIcon, HelpCircleIcon, HomeIcon, Icon, type IconByNameProps, type IconComponent, type IconGroup, type IconName, type IconProps, Input, type InputProps, type InputSize, InstagramIcon, KeyIcon, type LanguageOption, LanguageSwitcher, type LanguageSwitcherProps, LayoutGridIcon, LinkedInIcon, LogOutIcon, MailIcon, MenuIcon, type MenuIconProps, MenuItem, type MenuItemProps, MinusIcon, NavigateIcon, PhoneIcon, PlusIcon, RatingInput, type RatingInputProps, SearchIcon, SegmentedToggle, type SegmentedToggleOption, type SegmentedToggleProps, Select, type SelectMultipleProps, type SelectOption, type SelectProps, type SelectSingleProps, SettingsIcon, ShowIcon, SidebarIcon, StarFilledIcon, StarIcon, type StarIconProps, StatCard, type StatCardProps, Textarea, type TextareaProps, Toggle, type ToggleProps, UserIcon, UsersAltIcon, VideoIcon, avatarTypography, badgeTypography, buttonTypography, colors, commentCardTypography, counterTypography, datePickerTypography, defaultLanguageOptions, fonts, getIconsByGroup, grey, iconGroupNames, iconGroups, iconNames, icons, inputTypography, languageSwitcherTypography, ratingTypography, segmentedToggleTypography, selectTypography, statCardTypography, textareaTypography };
package/dist/index.d.ts CHANGED
@@ -156,6 +156,11 @@ declare function LogOutIcon({ size, color, strokeWidth }: IconProps): react.JSX.
156
156
 
157
157
  declare function MailIcon({ size, color, strokeWidth }: IconProps): react.JSX.Element;
158
158
 
159
+ interface MenuIconProps extends IconProps {
160
+ open?: boolean;
161
+ }
162
+ declare function MenuIcon({ size, color, strokeWidth, open, }: MenuIconProps): react.JSX.Element;
163
+
159
164
  declare function MinusIcon({ size, color, strokeWidth }: IconProps): react.JSX.Element;
160
165
 
161
166
  declare function NavigateIcon({ size, color, strokeWidth }: IconProps): react.JSX.Element;
@@ -236,6 +241,7 @@ declare const icons: {
236
241
  readonly linkedin: typeof LinkedInIcon;
237
242
  readonly logOut: typeof LogOutIcon;
238
243
  readonly mail: typeof MailIcon;
244
+ readonly menu: typeof MenuIcon;
239
245
  readonly minus: typeof MinusIcon;
240
246
  readonly navigate: typeof NavigateIcon;
241
247
  readonly phone: typeof PhoneIcon;
@@ -253,7 +259,7 @@ declare const icons: {
253
259
  type IconName = keyof typeof icons;
254
260
  declare const iconNames: IconName[];
255
261
  declare const iconGroups: {
256
- readonly navigation: readonly ["arrowRight", "chevronDown", "chevronLeft", "home", "navigate"];
262
+ readonly navigation: readonly ["arrowRight", "chevronDown", "chevronLeft", "home", "menu", "navigate"];
257
263
  readonly actions: readonly ["show", "bell", "camera", "key", "check", "checkBadge", "search", "calendar", "calendarOutline", "heart", "star", "starFilled", "minus", "plus"];
258
264
  readonly objects: readonly ["bag", "building", "clock", "user", "usersAlt", "video"];
259
265
  readonly communication: readonly ["mail", "phone"];
@@ -412,6 +418,8 @@ type DatePickerBaseProps = Omit<ViewProps, "style" | "children"> & {
412
418
  formatValue?: (date: Date) => string;
413
419
  /** First day of the week column (0 = Sunday, 1 = Monday). Defaults to Monday. */
414
420
  weekStartsOn?: 0 | 1;
421
+ /** Styles the calendar popup independently from the trigger width. */
422
+ calendarStyle?: StyleProp<ViewStyle>;
415
423
  style?: StyleProp<ViewStyle>;
416
424
  className?: string;
417
425
  };
@@ -863,4 +871,4 @@ declare const textareaTypography: {
863
871
  };
864
872
  };
865
873
 
866
- export { ArrowRightIcon, Avatar, type AvatarMenuItem, type AvatarProps, BRAND_LOGO_COLORS, BRAND_LOGO_DEFAULT_HEIGHT, BRAND_LOGO_DEFAULT_WIDTH, Badge, type BadgeProps, type BadgeVariant, BagIcon, BellIcon, BrandLogo, type BrandLogoProps, type BrandLogoVariant, BuildingIcon, Button, type ButtonProps, type ButtonSize, type ButtonVariant, CalendarIcon, CalendarOutlineIcon, CameraIcon, CheckBadgeIcon, CheckIcon, Checkbox, type CheckboxProps, type CheckboxVariant, ChevronDownIcon, ChevronLeftIcon, ClockIcon, CommentCard, type CommentCardProps, Counter, type CounterProps, DatePicker, type DatePickerProps, type DatePickerRangeProps, type DatePickerSingleProps, type DateRange, FacebookIcon, GlobeIcon, type GreyStep, HeartIcon, HelpCircleIcon, HomeIcon, Icon, type IconByNameProps, type IconComponent, type IconGroup, type IconName, type IconProps, Input, type InputProps, type InputSize, InstagramIcon, KeyIcon, type LanguageOption, LanguageSwitcher, type LanguageSwitcherProps, LayoutGridIcon, LinkedInIcon, LogOutIcon, MailIcon, MenuItem, type MenuItemProps, MinusIcon, NavigateIcon, PhoneIcon, PlusIcon, RatingInput, type RatingInputProps, SearchIcon, SegmentedToggle, type SegmentedToggleOption, type SegmentedToggleProps, Select, type SelectMultipleProps, type SelectOption, type SelectProps, type SelectSingleProps, SettingsIcon, ShowIcon, SidebarIcon, StarFilledIcon, StarIcon, type StarIconProps, StatCard, type StatCardProps, Textarea, type TextareaProps, Toggle, type ToggleProps, UserIcon, UsersAltIcon, VideoIcon, avatarTypography, badgeTypography, buttonTypography, colors, commentCardTypography, counterTypography, datePickerTypography, defaultLanguageOptions, fonts, getIconsByGroup, grey, iconGroupNames, iconGroups, iconNames, icons, inputTypography, languageSwitcherTypography, ratingTypography, segmentedToggleTypography, selectTypography, statCardTypography, textareaTypography };
874
+ export { ArrowRightIcon, Avatar, type AvatarMenuItem, type AvatarProps, BRAND_LOGO_COLORS, BRAND_LOGO_DEFAULT_HEIGHT, BRAND_LOGO_DEFAULT_WIDTH, Badge, type BadgeProps, type BadgeVariant, BagIcon, BellIcon, BrandLogo, type BrandLogoProps, type BrandLogoVariant, BuildingIcon, Button, type ButtonProps, type ButtonSize, type ButtonVariant, CalendarIcon, CalendarOutlineIcon, CameraIcon, CheckBadgeIcon, CheckIcon, Checkbox, type CheckboxProps, type CheckboxVariant, ChevronDownIcon, ChevronLeftIcon, ClockIcon, CommentCard, type CommentCardProps, Counter, type CounterProps, DatePicker, type DatePickerProps, type DatePickerRangeProps, type DatePickerSingleProps, type DateRange, FacebookIcon, GlobeIcon, type GreyStep, HeartIcon, HelpCircleIcon, HomeIcon, Icon, type IconByNameProps, type IconComponent, type IconGroup, type IconName, type IconProps, Input, type InputProps, type InputSize, InstagramIcon, KeyIcon, type LanguageOption, LanguageSwitcher, type LanguageSwitcherProps, LayoutGridIcon, LinkedInIcon, LogOutIcon, MailIcon, MenuIcon, type MenuIconProps, MenuItem, type MenuItemProps, MinusIcon, NavigateIcon, PhoneIcon, PlusIcon, RatingInput, type RatingInputProps, SearchIcon, SegmentedToggle, type SegmentedToggleOption, type SegmentedToggleProps, Select, type SelectMultipleProps, type SelectOption, type SelectProps, type SelectSingleProps, SettingsIcon, ShowIcon, SidebarIcon, StarFilledIcon, StarIcon, type StarIconProps, StatCard, type StatCardProps, Textarea, type TextareaProps, Toggle, type ToggleProps, UserIcon, UsersAltIcon, VideoIcon, avatarTypography, badgeTypography, buttonTypography, colors, commentCardTypography, counterTypography, datePickerTypography, defaultLanguageOptions, fonts, getIconsByGroup, grey, iconGroupNames, iconGroups, iconNames, icons, inputTypography, languageSwitcherTypography, ratingTypography, segmentedToggleTypography, selectTypography, statCardTypography, textareaTypography };
package/dist/index.js CHANGED
@@ -615,6 +615,28 @@ function MailIcon({ size = 20, color = colors.primary, strokeWidth = 2 }) {
615
615
  ) });
616
616
  }
617
617
 
618
+ // src/icons/Menu/menuPath.ts
619
+ var MENU_PATH = "M8 12.6667H17.3333M1 6.83332H17.3333M8 0.999985H17.3333";
620
+ var MENU_CLOSE_PATH = "M15 1L1 15M1 1L15 15";
621
+ function MenuIcon({
622
+ size = 19,
623
+ color = colors.white,
624
+ strokeWidth = 2,
625
+ open = false
626
+ }) {
627
+ return /* @__PURE__ */ jsx(Svg, { width: size, height: size, viewBox: "0 0 19 19", fill: "none", children: /* @__PURE__ */ jsx(
628
+ Path,
629
+ {
630
+ d: open ? MENU_CLOSE_PATH : MENU_PATH,
631
+ stroke: color,
632
+ strokeWidth,
633
+ strokeLinecap: "round",
634
+ strokeLinejoin: "round",
635
+ transform: open ? "translate(1.5 1.5)" : "translate(0 2.5)"
636
+ }
637
+ ) });
638
+ }
639
+
618
640
  // src/icons/Minus/minusPath.ts
619
641
  var MINUS_PATH = "M3.33337 8H12.6667";
620
642
  function MinusIcon({ size = 16, color = colors.white, strokeWidth = 2 }) {
@@ -871,6 +893,7 @@ var icons = {
871
893
  linkedin: LinkedInIcon,
872
894
  logOut: LogOutIcon,
873
895
  mail: MailIcon,
896
+ menu: MenuIcon,
874
897
  minus: MinusIcon,
875
898
  navigate: NavigateIcon,
876
899
  phone: PhoneIcon,
@@ -887,7 +910,7 @@ var icons = {
887
910
  };
888
911
  var iconNames = Object.keys(icons);
889
912
  var iconGroups = {
890
- navigation: ["arrowRight", "chevronDown", "chevronLeft", "home", "navigate"],
913
+ navigation: ["arrowRight", "chevronDown", "chevronLeft", "home", "menu", "navigate"],
891
914
  actions: [
892
915
  "show",
893
916
  "bell",
@@ -2036,6 +2059,7 @@ var Button = forwardRef(
2036
2059
  paddingRight: hasIcon ? metrics.paddingRightWithIcon : metrics.paddingRight,
2037
2060
  gap: hasIcon ? metrics.gap : 0
2038
2061
  },
2062
+ hasIcon ? styles8.contentWithIcon : styles8.contentWithoutIcon,
2039
2063
  disabled && styles8.disabled,
2040
2064
  style
2041
2065
  ];
@@ -2091,6 +2115,12 @@ var styles8 = StyleSheet.create({
2091
2115
  disabled: {
2092
2116
  opacity: 0.6
2093
2117
  },
2118
+ contentWithIcon: {
2119
+ justifyContent: "space-between"
2120
+ },
2121
+ contentWithoutIcon: {
2122
+ justifyContent: "center"
2123
+ },
2094
2124
  label: {},
2095
2125
  labelAndroid: {
2096
2126
  includeFontPadding: false
@@ -2297,6 +2327,7 @@ var DatePicker = forwardRef(
2297
2327
  weekdayLabels = DEFAULT_WEEKDAY_LABELS,
2298
2328
  formatValue = formatDate,
2299
2329
  weekStartsOn = 1,
2330
+ calendarStyle,
2300
2331
  style,
2301
2332
  className,
2302
2333
  accessibilityLabel,
@@ -2451,7 +2482,7 @@ var DatePicker = forwardRef(
2451
2482
  ]
2452
2483
  }
2453
2484
  ),
2454
- isOpen ? /* @__PURE__ */ jsxs(View, { style: styles10.menu, children: [
2485
+ isOpen ? /* @__PURE__ */ jsxs(View, { style: [styles10.menu, calendarStyle], children: [
2455
2486
  /* @__PURE__ */ jsxs(View, { style: styles10.calendarHeader, children: [
2456
2487
  /* @__PURE__ */ jsx(
2457
2488
  Pressable,
@@ -2631,7 +2662,7 @@ var styles10 = StyleSheet.create({
2631
2662
  position: "absolute",
2632
2663
  top: "100%",
2633
2664
  left: 0,
2634
- right: 0,
2665
+ width: DEFAULT_WIDTH,
2635
2666
  marginTop: 8,
2636
2667
  zIndex: 10,
2637
2668
  borderRadius: MENU_RADIUS2,
@@ -4141,6 +4172,6 @@ var styles16 = StyleSheet.create({
4141
4172
  }
4142
4173
  });
4143
4174
 
4144
- export { ArrowRightIcon, Avatar, BRAND_LOGO_COLORS, BRAND_LOGO_DEFAULT_HEIGHT, BRAND_LOGO_DEFAULT_WIDTH, Badge, BagIcon, BellIcon, BrandLogo, BuildingIcon, Button, CalendarIcon, CalendarOutlineIcon, CameraIcon, CheckBadgeIcon, CheckIcon, Checkbox, ChevronDownIcon, ChevronLeftIcon, ClockIcon, CommentCard, Counter, DatePicker, FacebookIcon, GlobeIcon, HeartIcon, HelpCircleIcon, HomeIcon, Icon, Input, InstagramIcon, KeyIcon, LanguageSwitcher, LayoutGridIcon, LinkedInIcon, LogOutIcon, MailIcon, MenuItem, MinusIcon, NavigateIcon, PhoneIcon, PlusIcon, RatingInput, SearchIcon, SegmentedToggle, Select, SettingsIcon, ShowIcon, SidebarIcon, StarFilledIcon, StarIcon, StatCard, Textarea, Toggle, UserIcon, UsersAltIcon, VideoIcon, avatarTypography, badgeTypography, buttonTypography, colors, commentCardTypography, counterTypography, datePickerTypography, defaultLanguageOptions, fonts, getIconsByGroup, grey, iconGroupNames, iconGroups, iconNames, icons, inputTypography, languageSwitcherTypography, ratingTypography, segmentedToggleTypography, selectTypography, statCardTypography, textareaTypography };
4175
+ export { ArrowRightIcon, Avatar, BRAND_LOGO_COLORS, BRAND_LOGO_DEFAULT_HEIGHT, BRAND_LOGO_DEFAULT_WIDTH, Badge, BagIcon, BellIcon, BrandLogo, BuildingIcon, Button, CalendarIcon, CalendarOutlineIcon, CameraIcon, CheckBadgeIcon, CheckIcon, Checkbox, ChevronDownIcon, ChevronLeftIcon, ClockIcon, CommentCard, Counter, DatePicker, FacebookIcon, GlobeIcon, HeartIcon, HelpCircleIcon, HomeIcon, Icon, Input, InstagramIcon, KeyIcon, LanguageSwitcher, LayoutGridIcon, LinkedInIcon, LogOutIcon, MailIcon, MenuIcon, MenuItem, MinusIcon, NavigateIcon, PhoneIcon, PlusIcon, RatingInput, SearchIcon, SegmentedToggle, Select, SettingsIcon, ShowIcon, SidebarIcon, StarFilledIcon, StarIcon, StatCard, Textarea, Toggle, UserIcon, UsersAltIcon, VideoIcon, avatarTypography, badgeTypography, buttonTypography, colors, commentCardTypography, counterTypography, datePickerTypography, defaultLanguageOptions, fonts, getIconsByGroup, grey, iconGroupNames, iconGroups, iconNames, icons, inputTypography, languageSwitcherTypography, ratingTypography, segmentedToggleTypography, selectTypography, statCardTypography, textareaTypography };
4145
4176
  //# sourceMappingURL=index.js.map
4146
4177
  //# sourceMappingURL=index.js.map