@wavv/ui 2.4.8-alpha.2 → 2.4.8-alpha.4

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.
@@ -427,7 +427,7 @@ declare const Accordion: {
427
427
  className?: import("react-aria-components").DisclosurePanelProps["className"];
428
428
  style?: import("react-aria-components").DisclosurePanelProps["style"];
429
429
  background?: string;
430
- } & MaxHeight & import("react-aria-components").DisclosurePanelProps): import("react/jsx-runtime").JSX.Element;
430
+ } & MaxHeight & import("../types").Padding & import("react-aria-components").DisclosurePanelProps): import("react/jsx-runtime").JSX.Element;
431
431
  displayName: string;
432
432
  };
433
433
  };
@@ -1,11 +1,11 @@
1
1
  import { type DisclosurePanelProps } from 'react-aria-components';
2
- import type { MaxHeight } from '../types';
2
+ import type { MaxHeight, Padding } from '../types';
3
3
  type PanelProps = {
4
4
  children: DisclosurePanelProps['children'];
5
5
  className?: DisclosurePanelProps['className'];
6
6
  style?: DisclosurePanelProps['style'];
7
7
  background?: string;
8
- } & MaxHeight & DisclosurePanelProps;
8
+ } & MaxHeight & Padding & DisclosurePanelProps;
9
9
  declare const Panel: {
10
10
  ({ children, maxHeight, ...props }: PanelProps): import("react/jsx-runtime").JSX.Element;
11
11
  displayName: string;
@@ -4,6 +4,7 @@ import { useRef, useState } from "react";
4
4
  import { DisclosurePanel } from "react-aria-components";
5
5
  import { useElementObserver } from "../../hooks/index.js";
6
6
  import isPropAllowed from "../helpers/isPropAllowed.js";
7
+ import { paddingProps } from "../helpers/styledProps.js";
7
8
  const Panel = ({ children, maxHeight, ...props })=>{
8
9
  const contentRef = useRef(null);
9
10
  const [calculatedMaxHeight, setCalculatedMaxHeight] = useState();
@@ -42,7 +43,10 @@ const PanelContainer = styled(DisclosurePanel, {
42
43
  'defaultPadding',
43
44
  'maxHeight'
44
45
  ])
45
- })(({ theme, maxHeight, defaultPadding, background })=>({
46
+ })(({ theme, maxHeight, defaultPadding, background, ...props })=>{
47
+ const hasPaddingProps = void 0 !== props.padding || void 0 !== props.paddingTop || void 0 !== props.paddingBottom || void 0 !== props.paddingRight || void 0 !== props.paddingLeft;
48
+ const paddingValue = !hasPaddingProps && defaultPadding ? '8px 16px' : void 0;
49
+ return {
46
50
  backgroundColor: background || theme.scale0,
47
51
  color: theme.scale10,
48
52
  fontSize: theme.font.size.md,
@@ -56,9 +60,13 @@ const PanelContainer = styled(DisclosurePanel, {
56
60
  opacity: 0
57
61
  },
58
62
  '&[aria-hidden="false"]': {
59
- padding: defaultPadding ? '8px 16px' : void 0
63
+ ...paddingProps({
64
+ padding: paddingValue,
65
+ ...props
66
+ })
60
67
  }
61
- }));
68
+ };
69
+ });
62
70
  Panel.displayName = 'Accordion.Panel';
63
71
  const Accordion_Panel = Panel;
64
72
  export { Accordion_Panel as default };
@@ -105,6 +105,7 @@ declare const icons: {
105
105
  readonly paragraph: ComponentType<WrappedIconProps>;
106
106
  readonly pause: ComponentType<WrappedIconProps>;
107
107
  readonly 'pause-circle': ComponentType<WrappedIconProps>;
108
+ readonly percent: ComponentType<WrappedIconProps>;
108
109
  readonly person: ComponentType<WrappedIconProps>;
109
110
  readonly 'person-add': ComponentType<WrappedIconProps>;
110
111
  readonly 'person-check': ComponentType<WrappedIconProps>;
@@ -138,6 +139,7 @@ declare const icons: {
138
139
  readonly stop: ComponentType<WrappedIconProps>;
139
140
  readonly 'stop-circle': ComponentType<WrappedIconProps>;
140
141
  readonly strikethrough: ComponentType<WrappedIconProps>;
142
+ readonly tag: ComponentType<WrappedIconProps>;
141
143
  readonly template: ComponentType<WrappedIconProps>;
142
144
  readonly transfer: ComponentType<WrappedIconProps>;
143
145
  readonly trash: ComponentType<WrappedIconProps>;
@@ -1,4 +1,4 @@
1
- import { ArrowDown, ArrowDownWideNarrow, ArrowLeft, ArrowRight, ArrowRightLeft, ArrowUp, ArrowUpWideNarrow, BadgeCheck, Ban, Bell, BellDot, Bold, Bot, Braces, Bug, CalendarDays, Camera, ChartColumn, Check, ChevronDown, ChevronLeft, ChevronRight, ChevronUp, ChevronsLeft, ChevronsRight, ChevronsUpDown, Circle, CircleAlert, CircleCheck, CirclePause, CirclePlay, CirclePlus, CircleQuestionMark, CircleStop, CircleUserRound, CircleX, Clapperboard, Clock, Copy, CopyCheck, CopyPlus, CreditCard, Download, Ear, EllipsisVertical, ExternalLink, Eye, EyeOff, Facebook, FileText, Flag, FlaskConical, Frown, Funnel, Globe, GripVertical, Hash, Heading, Heading1, Heading2, Heading3, Heading4, Heading5, Heading6, Headset, Heart, Highlighter, Hourglass, House, IdCard, Info, Instagram, Italic, Kanban, Layers2, LayoutDashboard, Lightbulb, Link, Linkedin, List, ListChecks, ListFilter, ListOrdered, ListTodo, Loader, LockKeyhole, LockKeyholeOpen, LogIn, LogOut, MapPin, MapPinned, Maximize2, Meh, Menu, Merge, MessageSquareMore, Mic, MicOff, Minimize2, Minus, MonitorSmartphone, NotebookPen, Paperclip, Pause, Pencil, Pilcrow, Pin, PinOff, Play, Plus, Redo, RefreshCcwDot, RefreshCw, Rocket, RotateCw, Search, Send, Settings, Share, Share2, Shield, ShieldCheck, ShieldOff, ShieldPlus, ShoppingCart, Smartphone, Smile, Sparkles, Square, SquarePen, SquareStack, Star, Strikethrough, TextQuote, Trash2, TriangleAlert, Trophy, Underline, Undo, Upload, UserRound, UserRoundCheck, UserRoundPlus, UserRoundX, Users, Video, Voicemail, Volume2, X, Youtube } from "lucide-react";
1
+ import { ArrowDown, ArrowDownWideNarrow, ArrowLeft, ArrowRight, ArrowRightLeft, ArrowUp, ArrowUpWideNarrow, BadgeCheck, Ban, Bell, BellDot, Bold, Bot, Braces, Bug, CalendarDays, Camera, ChartColumn, Check, ChevronDown, ChevronLeft, ChevronRight, ChevronUp, ChevronsLeft, ChevronsRight, ChevronsUpDown, Circle, CircleAlert, CircleCheck, CirclePause, CirclePlay, CirclePlus, CircleQuestionMark, CircleStop, CircleUserRound, CircleX, Clapperboard, Clock, Copy, CopyCheck, CopyPlus, CreditCard, Download, Ear, EllipsisVertical, ExternalLink, Eye, EyeOff, Facebook, FileText, Flag, FlaskConical, Frown, Funnel, Globe, GripVertical, Hash, Heading, Heading1, Heading2, Heading3, Heading4, Heading5, Heading6, Headset, Heart, Highlighter, Hourglass, House, IdCard, Info, Instagram, Italic, Kanban, Layers2, LayoutDashboard, Lightbulb, Link, Linkedin, List, ListChecks, ListFilter, ListOrdered, ListTodo, Loader, LockKeyhole, LockKeyholeOpen, LogIn, LogOut, MapPin, MapPinned, Maximize2, Meh, Menu, Merge, MessageSquareMore, Mic, MicOff, Minimize2, Minus, MonitorSmartphone, NotebookPen, Paperclip, Pause, Pencil, Percent, Pilcrow, Pin, PinOff, Play, Plus, Redo, RefreshCcwDot, RefreshCw, Rocket, RotateCw, Search, Send, Settings, Share, Share2, Shield, ShieldCheck, ShieldOff, ShieldPlus, ShoppingCart, Smartphone, Smile, Sparkles, Square, SquarePen, SquareStack, Star, Strikethrough, Tag, TextQuote, Trash2, TriangleAlert, Trophy, Underline, Undo, Upload, UserRound, UserRoundCheck, UserRoundPlus, UserRoundX, Users, Video, Voicemail, Volume2, X, Youtube } from "lucide-react";
2
2
  import createWrappedIcon from "./createWrappedIcon.js";
3
3
  const icons = {
4
4
  'activity-history': createWrappedIcon(IdCard),
@@ -105,6 +105,7 @@ const icons = {
105
105
  paragraph: createWrappedIcon(Pilcrow),
106
106
  pause: createWrappedIcon(Pause),
107
107
  'pause-circle': createWrappedIcon(CirclePause),
108
+ percent: createWrappedIcon(Percent),
108
109
  person: createWrappedIcon(UserRound),
109
110
  'person-add': createWrappedIcon(UserRoundPlus),
110
111
  'person-check': createWrappedIcon(UserRoundCheck),
@@ -138,6 +139,7 @@ const icons = {
138
139
  stop: createWrappedIcon(Square),
139
140
  'stop-circle': createWrappedIcon(CircleStop),
140
141
  strikethrough: createWrappedIcon(Strikethrough),
142
+ tag: createWrappedIcon(Tag),
141
143
  template: createWrappedIcon(FileText),
142
144
  transfer: createWrappedIcon(ArrowRightLeft),
143
145
  trash: createWrappedIcon(Trash2),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wavv/ui",
3
- "version": "2.4.8-alpha.2",
3
+ "version": "2.4.8-alpha.4",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {