untitledui 0.1.3 → 0.1.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.
- package/package.json +1 -1
- package/templates/default/src/app/home-screen.tsx +1 -1
- package/templates/default/src/app/layout.tsx +2 -2
- package/templates/default/src/components/foundations/featured-icon/featured-icons.tsx +1 -1
- package/templates/default/src/components/marketing/header-navigation/base-components/nav-menu-item.tsx +1 -1
- package/templates/default/src/components/marketing/header-navigation/components/header.tsx +1 -1
- package/templates/default/src/components/shared/avatar/avatar-label-group.tsx +1 -1
- package/templates/default/src/components/shared/avatar/avatar-profile-photo.tsx +1 -1
- package/templates/default/src/components/shared/avatar/avatar.tsx +1 -1
- package/templates/default/src/components/shared/avatar/base-components/avatar-add-button.tsx +1 -1
- package/templates/default/src/components/shared/avatar/base-components/avatar-company-icon.tsx +1 -1
- package/templates/default/src/components/shared/avatar/base-components/avatar-online-indicator.tsx +1 -1
- package/templates/default/src/components/shared/avatar/base-components/verified-tick.tsx +1 -1
- package/templates/default/src/components/shared/badges/badge-groups.tsx +1 -1
- package/templates/default/src/components/shared/badges/badges.tsx +1 -1
- package/templates/default/src/components/shared/button-group/button-group.tsx +1 -1
- package/templates/default/src/components/shared/buttons/app-store-buttons-outline.tsx +1 -1
- package/templates/default/src/components/shared/buttons/app-store-buttons.tsx +1 -1
- package/templates/default/src/components/shared/buttons/button-utility.tsx +1 -1
- package/templates/default/src/components/shared/buttons/button.tsx +1 -1
- package/templates/default/src/components/shared/buttons/close-button.tsx +1 -1
- package/templates/default/src/components/shared/buttons/social-button.tsx +1 -1
- package/templates/default/src/components/shared/checkbox/checkbox.tsx +1 -1
- package/templates/default/src/components/shared/dropdown/dropdown.tsx +1 -1
- package/templates/default/src/components/shared/input/hint-text.tsx +1 -1
- package/templates/default/src/components/shared/input/index.tsx +1 -1
- package/templates/default/src/components/shared/input/input-payment.tsx +1 -1
- package/templates/default/src/components/shared/input/input-with-button.tsx +1 -1
- package/templates/default/src/components/shared/input/input-with-dropdown.tsx +1 -1
- package/templates/default/src/components/shared/input/input-with-prefix.tsx +1 -1
- package/templates/default/src/components/shared/input/label.tsx +1 -1
- package/templates/default/src/components/shared/progress-indicators/progress-circles.tsx +1 -1
- package/templates/default/src/components/shared/progress-indicators/progress-indicators.tsx +3 -3
- package/templates/default/src/components/shared/radio-buttons/radio-buttons.tsx +1 -1
- package/templates/default/src/components/shared/radio-groups/radio-group-avatar.tsx +1 -1
- package/templates/default/src/components/shared/radio-groups/radio-group-checkbox.tsx +1 -1
- package/templates/default/src/components/shared/radio-groups/radio-group-icon-card.tsx +1 -1
- package/templates/default/src/components/shared/radio-groups/radio-group-icon-simple.tsx +1 -1
- package/templates/default/src/components/shared/radio-groups/radio-group-payment-icon.tsx +1 -1
- package/templates/default/src/components/shared/radio-groups/radio-group-radio-button.tsx +1 -1
- package/templates/default/src/components/shared/select/combobox.tsx +1 -1
- package/templates/default/src/components/shared/select/multi-select.tsx +1 -1
- package/templates/default/src/components/shared/select/popover.tsx +1 -1
- package/templates/default/src/components/shared/select/select-item.tsx +1 -1
- package/templates/default/src/components/shared/select/select.tsx +1 -1
- package/templates/default/src/components/shared/slider/slider.tsx +3 -3
- package/templates/default/src/components/shared/tags/base-components/tag-checkbox.tsx +1 -1
- package/templates/default/src/components/shared/tags/base-components/tag-close-x.tsx +1 -1
- package/templates/default/src/components/shared/tags/tags.tsx +1 -1
- package/templates/default/src/components/shared/textarea/textarea.tsx +1 -1
- package/templates/default/src/components/shared/toggle/toggle.tsx +1 -1
- package/templates/default/src/components/shared/tooltips/tooltips.tsx +1 -1
package/package.json
CHANGED
|
@@ -12,7 +12,7 @@ import { BadgeGroup } from "@/components/shared/badges/badge-groups";
|
|
|
12
12
|
import Button from "@/components/shared/buttons/button";
|
|
13
13
|
import { Form } from "@/components/shared/form/form";
|
|
14
14
|
import { Input } from "@/components/shared/input";
|
|
15
|
-
import { cx } from "@/components/utils";
|
|
15
|
+
import { cx } from "@/components/utils/cx";
|
|
16
16
|
import Spiral from "../../public/marketing/spirals.webp";
|
|
17
17
|
|
|
18
18
|
const Header = dynamic(() => import("@/components/marketing/header-navigation/components/header").then((mod) => mod.Header));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Metadata, Viewport } from "next";
|
|
2
2
|
import { Inter } from "next/font/google";
|
|
3
|
-
import { cx } from "@/components/utils";
|
|
3
|
+
import { cx } from "@/components/utils/cx";
|
|
4
4
|
import { Theme } from "@/providers/theme";
|
|
5
5
|
import "@/styles/globals.css";
|
|
6
6
|
|
|
@@ -26,7 +26,7 @@ export default function RootLayout({
|
|
|
26
26
|
}>) {
|
|
27
27
|
return (
|
|
28
28
|
<html lang="en" suppressHydrationWarning>
|
|
29
|
-
<body className={cx(inter.variable, "light-mode bg-primary antialiased
|
|
29
|
+
<body className={cx(inter.variable, "light-mode dark:dark-mode bg-primary antialiased")}>
|
|
30
30
|
<Theme>{children}</Theme>
|
|
31
31
|
</body>
|
|
32
32
|
</html>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { FC, ReactNode, Ref } from "react";
|
|
2
2
|
import { isValidElement } from "react";
|
|
3
|
-
import { cx, sortCx } from "@/components/utils";
|
|
3
|
+
import { cx, sortCx } from "@/components/utils/cx";
|
|
4
4
|
import { isReactComponent } from "@/components/utils/isReactComponent";
|
|
5
5
|
|
|
6
6
|
const iconsSizes = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
import { type FC, type ReactNode, isValidElement } from "react";
|
|
4
|
-
import { cx } from "@/components/utils";
|
|
4
|
+
import { cx } from "@/components/utils/cx";
|
|
5
5
|
import { isReactComponent } from "@/components/utils/isReactComponent";
|
|
6
6
|
|
|
7
7
|
interface NavMenuItemLinkProps {
|
|
@@ -7,7 +7,7 @@ import { Button as AriaButton, Dialog, DialogTrigger, Popover } from "react-aria
|
|
|
7
7
|
import UntitledLogo from "@/components/foundations/logo/UntitledLogo";
|
|
8
8
|
import UntitledLogoMinimal from "@/components/foundations/logo/UntitledLogoMinimal";
|
|
9
9
|
import Button from "@/components/shared/buttons/button";
|
|
10
|
-
import { cx } from "@/components/utils";
|
|
10
|
+
import { cx } from "@/components/utils/cx";
|
|
11
11
|
import { DropdownMenuSimple } from "../dropdown-header-navigation";
|
|
12
12
|
|
|
13
13
|
type HeaderNavItem = {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { useState } from "react";
|
|
4
4
|
import { User01 } from "@untitledui/icons";
|
|
5
|
-
import { cx } from "@/components/utils";
|
|
5
|
+
import { cx } from "@/components/utils/cx";
|
|
6
6
|
import { type AvatarProps } from "./avatar";
|
|
7
7
|
import { AvatarOnlineIndicator, VerifiedTick } from "./base-components";
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { type FC, type ReactNode, useState } from "react";
|
|
4
4
|
import { User01 } from "@untitledui/icons";
|
|
5
|
-
import { cx } from "@/components/utils";
|
|
5
|
+
import { cx } from "@/components/utils/cx";
|
|
6
6
|
import { AvatarOnlineIndicator, VerifiedTick } from "./base-components";
|
|
7
7
|
|
|
8
8
|
type AvatarSize = "xxs" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl";
|
package/templates/default/src/components/shared/avatar/base-components/avatar-add-button.tsx
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { Plus } from "@untitledui/icons";
|
|
4
4
|
import type { ButtonProps } from "react-aria-components";
|
|
5
|
-
import { cx } from "@/components/utils";
|
|
5
|
+
import { cx } from "@/components/utils/cx";
|
|
6
6
|
import { Tooltip, TooltipTrigger } from "../../tooltips/tooltips";
|
|
7
7
|
|
|
8
8
|
const sizes = {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import type { FC, ReactNode } from "react";
|
|
4
4
|
import { isValidElement } from "react";
|
|
5
5
|
import { ArrowRight } from "@untitledui/icons";
|
|
6
|
-
import { cx, sortCx } from "@/components/utils";
|
|
6
|
+
import { cx, sortCx } from "@/components/utils/cx";
|
|
7
7
|
import { isReactComponent } from "@/components/utils/isReactComponent";
|
|
8
8
|
|
|
9
9
|
type Size = "md" | "lg";
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import type { MouseEventHandler, ReactNode } from "react";
|
|
4
4
|
import { X as CloseX } from "@untitledui/icons";
|
|
5
5
|
import Dot from "@/components/foundations/dot-icon";
|
|
6
|
-
import { cx } from "@/components/utils";
|
|
6
|
+
import { cx } from "@/components/utils/cx";
|
|
7
7
|
import type { BadgeColors, BadgeTypeToColorMap, BadgeTypes, FlagTypes, IconComponentType, Sizes } from "./badge-types";
|
|
8
8
|
import { badgeTypes } from "./badge-types";
|
|
9
9
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { type FC, type PropsWithChildren, type ReactNode, type RefAttributes, createContext, isValidElement, useContext } from "react";
|
|
4
4
|
import { ToggleButton, ToggleButtonGroup, type ToggleButtonGroupProps, type ToggleButtonProps } from "react-aria-components";
|
|
5
|
-
import { cx, sortCx } from "@/components/utils";
|
|
5
|
+
import { cx, sortCx } from "@/components/utils/cx";
|
|
6
6
|
import { isReactComponent } from "@/components/utils/isReactComponent";
|
|
7
7
|
|
|
8
8
|
export const styles = sortCx({
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
import type { AnchorHTMLAttributes } from "react";
|
|
4
|
-
import { cx } from "@/components/utils";
|
|
4
|
+
import { cx } from "@/components/utils/cx";
|
|
5
5
|
|
|
6
6
|
export const GooglePlayButton = ({ size = "md", ...props }: AnchorHTMLAttributes<HTMLAnchorElement> & { size?: "md" | "lg" }) => {
|
|
7
7
|
return (
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
import type { AnchorHTMLAttributes } from "react";
|
|
4
|
-
import { cx } from "@/components/utils";
|
|
4
|
+
import { cx } from "@/components/utils/cx";
|
|
5
5
|
|
|
6
6
|
export const GooglePlayButton = ({ size = "md", ...props }: AnchorHTMLAttributes<HTMLAnchorElement> & { size?: "md" | "lg" }) => {
|
|
7
7
|
return (
|
|
@@ -4,7 +4,7 @@ import type { DetailedHTMLProps, FC, HTMLAttributes, ReactNode } from "react";
|
|
|
4
4
|
import React, { isValidElement } from "react";
|
|
5
5
|
import type { ButtonProps as AriaButtonProps } from "react-aria-components";
|
|
6
6
|
import { Button as AriaButton } from "react-aria-components";
|
|
7
|
-
import { cx, sortCx } from "@/components/utils";
|
|
7
|
+
import { cx, sortCx } from "@/components/utils/cx";
|
|
8
8
|
import { isReactComponent } from "@/components/utils/isReactComponent";
|
|
9
9
|
import { Tooltip } from "../tooltips/tooltips";
|
|
10
10
|
|
|
@@ -5,7 +5,7 @@ import React, { isValidElement } from "react";
|
|
|
5
5
|
import Link from "next/link";
|
|
6
6
|
import type { ButtonProps as AriaButtonProps, PressEvent } from "react-aria-components";
|
|
7
7
|
import { Button as AriaButton } from "react-aria-components";
|
|
8
|
-
import { cx, sortCx } from "@/components/utils";
|
|
8
|
+
import { cx, sortCx } from "@/components/utils/cx";
|
|
9
9
|
import { isReactComponent } from "@/components/utils/isReactComponent";
|
|
10
10
|
|
|
11
11
|
export const styles = sortCx({
|
|
@@ -4,7 +4,7 @@ import type { AnchorHTMLAttributes, ButtonHTMLAttributes, DetailedHTMLProps } fr
|
|
|
4
4
|
import React from "react";
|
|
5
5
|
import type { ButtonProps as AriaButtonProps } from "react-aria-components";
|
|
6
6
|
import { Button as AriaButton } from "react-aria-components";
|
|
7
|
-
import { cx, sortCx } from "@/components/utils";
|
|
7
|
+
import { cx, sortCx } from "@/components/utils/cx";
|
|
8
8
|
import { AppleLogo, DribbleLogo, FacebookLogo, FigmaLogo, FigmaLogoOutlined, GoogleLogo, TwitterLogo } from "./social-logos";
|
|
9
9
|
|
|
10
10
|
export const styles = sortCx({
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import type { ReactNode, Ref } from "react";
|
|
4
4
|
import { Checkbox as AriaCheckbox, type CheckboxProps as AriaCheckboxProps } from "react-aria-components";
|
|
5
|
-
import { cx } from "@/components/utils";
|
|
5
|
+
import { cx } from "@/components/utils/cx";
|
|
6
6
|
|
|
7
7
|
export interface CheckboxBaseProps {
|
|
8
8
|
size?: "sm" | "md";
|
|
@@ -10,7 +10,7 @@ import type {
|
|
|
10
10
|
SeparatorProps,
|
|
11
11
|
} from "react-aria-components";
|
|
12
12
|
import { Button as AriaButton, Header, Menu, MenuItem, MenuSection, MenuTrigger, Popover, Separator } from "react-aria-components";
|
|
13
|
-
import { cx } from "@/components/utils";
|
|
13
|
+
import { cx } from "@/components/utils/cx";
|
|
14
14
|
|
|
15
15
|
interface DropdownItemProps extends MenuItemProps {
|
|
16
16
|
/** The label of the item to be displayed. */
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import type { ReactNode, Ref } from "react";
|
|
4
4
|
import type { TextProps as AriaTextProps } from "react-aria-components";
|
|
5
5
|
import { Text as AriaText } from "react-aria-components";
|
|
6
|
-
import { cx } from "@/components/utils";
|
|
6
|
+
import { cx } from "@/components/utils/cx";
|
|
7
7
|
|
|
8
8
|
interface HintTextProps extends AriaTextProps {
|
|
9
9
|
children: ReactNode;
|
|
@@ -7,7 +7,7 @@ import { Input as AriaInput, TextField as AriaTextField, Group } from "react-ari
|
|
|
7
7
|
import HintText from "@/components/shared/input/hint-text";
|
|
8
8
|
import Label from "@/components/shared/input/label";
|
|
9
9
|
import { Tooltip, TooltipTrigger } from "@/components/shared/tooltips/tooltips";
|
|
10
|
-
import { cx, sortCx } from "@/components/utils";
|
|
10
|
+
import { cx, sortCx } from "@/components/utils/cx";
|
|
11
11
|
|
|
12
12
|
export interface InputBaseProps extends TextFieldProps {
|
|
13
13
|
label?: string;
|
|
@@ -7,7 +7,7 @@ import type { InputBaseProps } from "@/components/shared/input";
|
|
|
7
7
|
import { InputBase } from "@/components/shared/input";
|
|
8
8
|
import HintText from "@/components/shared/input/hint-text";
|
|
9
9
|
import Label from "@/components/shared/input/label";
|
|
10
|
-
import { cx } from "@/components/utils";
|
|
10
|
+
import { cx } from "@/components/utils/cx";
|
|
11
11
|
|
|
12
12
|
const cardTypes = [
|
|
13
13
|
{
|
|
@@ -10,7 +10,7 @@ import type { InputBaseProps } from "@/components/shared/input";
|
|
|
10
10
|
import { InputBase } from "@/components/shared/input";
|
|
11
11
|
import HintText from "@/components/shared/input/hint-text";
|
|
12
12
|
import Label from "@/components/shared/input/label";
|
|
13
|
-
import { cx } from "@/components/utils";
|
|
13
|
+
import { cx } from "@/components/utils/cx";
|
|
14
14
|
|
|
15
15
|
interface InputWithButtonProps extends Omit<InputBaseProps, "icon"> {
|
|
16
16
|
buttonText: string;
|
|
@@ -8,7 +8,7 @@ import type { InputBaseProps } from "@/components/shared/input";
|
|
|
8
8
|
import { InputBase } from "@/components/shared/input";
|
|
9
9
|
import HintText from "@/components/shared/input/hint-text";
|
|
10
10
|
import Label from "@/components/shared/input/label";
|
|
11
|
-
import { cx, sortCx } from "@/components/utils";
|
|
11
|
+
import { cx, sortCx } from "@/components/utils/cx";
|
|
12
12
|
|
|
13
13
|
interface SelectorComponentProps {
|
|
14
14
|
size: "sm" | "md";
|
|
@@ -5,7 +5,7 @@ import type { InputBaseProps } from "@/components/shared/input";
|
|
|
5
5
|
import { InputBase, TextField } from "@/components/shared/input";
|
|
6
6
|
import HintText from "@/components/shared/input/hint-text";
|
|
7
7
|
import Label from "@/components/shared/input/label";
|
|
8
|
-
import { cx } from "@/components/utils";
|
|
8
|
+
import { cx } from "@/components/utils/cx";
|
|
9
9
|
|
|
10
10
|
interface InputPrefixProps extends HTMLAttributes<HTMLDivElement> {
|
|
11
11
|
position?: "leading" | "trailing";
|
|
@@ -5,7 +5,7 @@ import { HelpCircle } from "@untitledui/icons";
|
|
|
5
5
|
import type { LabelProps as AriaLabelProps } from "react-aria-components";
|
|
6
6
|
import { Label as AriaLabel } from "react-aria-components";
|
|
7
7
|
import { Tooltip, TooltipTrigger } from "@/components/shared/tooltips/tooltips";
|
|
8
|
-
import { cx } from "@/components/utils";
|
|
8
|
+
import { cx } from "@/components/utils/cx";
|
|
9
9
|
|
|
10
10
|
interface LabelProps extends AriaLabelProps {
|
|
11
11
|
children: ReactNode;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
|
-
import { cx } from "@/components/utils";
|
|
3
|
+
import { cx } from "@/components/utils/cx";
|
|
4
4
|
|
|
5
5
|
export interface ProgressBarProps {
|
|
6
6
|
value: number;
|
|
@@ -61,7 +61,7 @@ export const ProgressBarTextTopFloating = ({ value, min = 0, max = 100, valueFor
|
|
|
61
61
|
<ProgressBar min={min} max={max} value={value} />
|
|
62
62
|
<div
|
|
63
63
|
style={{ left: `${percentage}%` }}
|
|
64
|
-
className="absolute -top-2 -translate-x-1/2 -translate-y-full rounded-lg bg-primary_alt px-3 py-2
|
|
64
|
+
className="absolute -top-2 -translate-x-1/2 -translate-y-full rounded-lg bg-primary_alt px-3 py-2 shadow-lg ring-1 ring-border-secondary_alt"
|
|
65
65
|
>
|
|
66
66
|
<div className="tt-xs-semi text-secondary tabular-nums">{valueFormatter ? valueFormatter(value, percentage) : `${percentage}%`}</div>
|
|
67
67
|
</div>
|
|
@@ -77,7 +77,7 @@ export const ProgressBarTextBottomFloating = ({ value, min = 0, max = 100, value
|
|
|
77
77
|
<ProgressBar min={min} max={max} value={value} />
|
|
78
78
|
<div
|
|
79
79
|
style={{ left: `${percentage}%` }}
|
|
80
|
-
className="absolute -bottom-2 -translate-x-1/2 translate-y-full rounded-lg bg-primary_alt px-3 py-2
|
|
80
|
+
className="absolute -bottom-2 -translate-x-1/2 translate-y-full rounded-lg bg-primary_alt px-3 py-2 shadow-lg ring-1 ring-border-secondary_alt"
|
|
81
81
|
>
|
|
82
82
|
<div className="tt-xs-semi text-secondary">{valueFormatter ? valueFormatter(value, percentage) : `${percentage}%`}</div>
|
|
83
83
|
</div>
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import { type ReactNode, type Ref, createContext, useContext } from "react";
|
|
4
4
|
import type { RadioGroupProps as AriaRadioGroupProps } from "react-aria-components";
|
|
5
5
|
import { type RadioProps as AriaRadioProps, Radio, RadioGroup } from "react-aria-components";
|
|
6
|
-
import { cx } from "@/components/utils";
|
|
6
|
+
import { cx } from "@/components/utils/cx";
|
|
7
7
|
|
|
8
8
|
export interface RadioButtonGroupContextType {
|
|
9
9
|
size?: "sm" | "md";
|
|
@@ -4,7 +4,7 @@ import type { RadioGroupProps } from "react-aria-components";
|
|
|
4
4
|
import { Label, Radio, RadioGroup, Text } from "react-aria-components";
|
|
5
5
|
import AvatarComponent from "@/components/shared/avatar/avatar";
|
|
6
6
|
import { CheckboxBase } from "@/components/shared/checkbox/checkbox";
|
|
7
|
-
import { cx } from "@/components/utils";
|
|
7
|
+
import { cx } from "@/components/utils/cx";
|
|
8
8
|
|
|
9
9
|
interface AvatarItemType {
|
|
10
10
|
id: string;
|
|
@@ -4,7 +4,7 @@ import type { FC } from "react";
|
|
|
4
4
|
import type { RadioGroupProps } from "react-aria-components";
|
|
5
5
|
import { Label, Radio, RadioGroup, Text } from "react-aria-components";
|
|
6
6
|
import { CheckboxBase } from "@/components/shared/checkbox/checkbox";
|
|
7
|
-
import { cx } from "@/components/utils";
|
|
7
|
+
import { cx } from "@/components/utils/cx";
|
|
8
8
|
|
|
9
9
|
type RadioGroupItemType = {
|
|
10
10
|
value: string;
|
|
@@ -6,7 +6,7 @@ import { Radio, RadioGroup } from "react-aria-components";
|
|
|
6
6
|
import { FeaturedIcon } from "@/components/foundations/featured-icon/featured-icons";
|
|
7
7
|
import { BadgeWithDot } from "@/components/shared/badges/badges";
|
|
8
8
|
import { CheckboxBase } from "@/components/shared/checkbox/checkbox";
|
|
9
|
-
import { cx } from "@/components/utils";
|
|
9
|
+
import { cx } from "@/components/utils/cx";
|
|
10
10
|
|
|
11
11
|
type IconCardItemType = {
|
|
12
12
|
value: string;
|
|
@@ -5,7 +5,7 @@ import type { RadioGroupProps } from "react-aria-components";
|
|
|
5
5
|
import { Label, Radio, RadioGroup, Text } from "react-aria-components";
|
|
6
6
|
import { FeaturedIcon } from "@/components/foundations/featured-icon/featured-icons";
|
|
7
7
|
import { CheckboxBase } from "@/components/shared/checkbox/checkbox";
|
|
8
|
-
import { cx } from "@/components/utils";
|
|
8
|
+
import { cx } from "@/components/utils/cx";
|
|
9
9
|
|
|
10
10
|
type RadioGroupItemType = {
|
|
11
11
|
value: string;
|
|
@@ -5,7 +5,7 @@ import type { RadioGroupProps } from "react-aria-components";
|
|
|
5
5
|
import { Label, Radio, RadioGroup, Text } from "react-aria-components";
|
|
6
6
|
import Button from "@/components/shared/buttons/button";
|
|
7
7
|
import { CheckboxBase } from "@/components/shared/checkbox/checkbox";
|
|
8
|
-
import { cx } from "@/components/utils";
|
|
8
|
+
import { cx } from "@/components/utils/cx";
|
|
9
9
|
|
|
10
10
|
interface PaymentCardItemType {
|
|
11
11
|
value: string;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import type { FC } from "react";
|
|
4
4
|
import type { RadioGroupProps } from "react-aria-components";
|
|
5
5
|
import { Label, Radio, RadioGroup, Text } from "react-aria-components";
|
|
6
|
-
import { cx } from "@/components/utils";
|
|
6
|
+
import { cx } from "@/components/utils/cx";
|
|
7
7
|
|
|
8
8
|
type RadioGroupItemType = {
|
|
9
9
|
value: string;
|
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
ComboBoxStateContext,
|
|
14
14
|
} from "react-aria-components";
|
|
15
15
|
import { useHotkeys } from "react-hotkeys-hook";
|
|
16
|
-
import { cx } from "@/components/utils";
|
|
16
|
+
import { cx } from "@/components/utils/cx";
|
|
17
17
|
import { useResizeObserver } from "@/hooks/use-resize-observer";
|
|
18
18
|
import HintText from "../input/hint-text";
|
|
19
19
|
import Label from "../input/label";
|
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
import { useHotkeys } from "react-hotkeys-hook";
|
|
17
17
|
import type { ListData } from "react-stately";
|
|
18
18
|
import { useListData } from "react-stately";
|
|
19
|
-
import { cx } from "@/components/utils";
|
|
19
|
+
import { cx } from "@/components/utils/cx";
|
|
20
20
|
import { useResizeObserver } from "@/hooks/use-resize-observer";
|
|
21
21
|
import Avatar from "../avatar/avatar";
|
|
22
22
|
import type { IconComponentType } from "../badges/badge-types";
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import type { RefAttributes } from "react";
|
|
4
4
|
import type { PopoverProps as AriaPopoverProps } from "react-aria-components";
|
|
5
5
|
import { Popover as AriaPopover } from "react-aria-components";
|
|
6
|
-
import { cx } from "@/components/utils";
|
|
6
|
+
import { cx } from "@/components/utils/cx";
|
|
7
7
|
|
|
8
8
|
interface PopoverProps extends AriaPopoverProps, RefAttributes<HTMLElement> {
|
|
9
9
|
size: "sm" | "md";
|
|
@@ -5,7 +5,7 @@ import { Check } from "@untitledui/icons";
|
|
|
5
5
|
import type { ListBoxItemProps as AriaListBoxItemProps } from "react-aria-components";
|
|
6
6
|
import { ListBoxItem as AriaListBoxItem, Text } from "react-aria-components";
|
|
7
7
|
import Avatar from "@/components/shared/avatar/avatar";
|
|
8
|
-
import { cx } from "@/components/utils";
|
|
8
|
+
import { cx } from "@/components/utils/cx";
|
|
9
9
|
import type { SelectItemType } from "./select";
|
|
10
10
|
import { SelectContext } from "./select";
|
|
11
11
|
|
|
@@ -9,7 +9,7 @@ import Avatar from "@/components/shared/avatar/avatar";
|
|
|
9
9
|
import type { IconComponentType } from "@/components/shared/badges/badge-types";
|
|
10
10
|
import HintText from "@/components/shared/input/hint-text";
|
|
11
11
|
import Label from "@/components/shared/input/label";
|
|
12
|
-
import { cx } from "@/components/utils";
|
|
12
|
+
import { cx } from "@/components/utils/cx";
|
|
13
13
|
import { ComboBox } from "./combobox";
|
|
14
14
|
import { Popover } from "./popover";
|
|
15
15
|
import Item from "./select-item";
|
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
import type { SliderProps as AriaSliderProps } from "react-aria-components";
|
|
4
4
|
import { Slider as AriaSlider, Label, SliderOutput, SliderThumb, SliderTrack } from "react-aria-components";
|
|
5
|
-
import { cx, sortCx } from "@/components/utils";
|
|
5
|
+
import { cx, sortCx } from "@/components/utils/cx";
|
|
6
6
|
|
|
7
7
|
const styles = sortCx({
|
|
8
8
|
default: "hidden",
|
|
9
9
|
bottom: "absolute top-2 left-1/2 -translate-x-1/2 translate-y-full text-md leading-md font-medium text-primary",
|
|
10
10
|
"top-floating":
|
|
11
|
-
"absolute -top-2 left-1/2 -translate-x-1/2 -translate-y-full rounded-lg bg-primary px-3 py-2 text-xs leading-xs font-semibold text-secondary
|
|
11
|
+
"absolute -top-2 left-1/2 -translate-x-1/2 -translate-y-full rounded-lg bg-primary px-3 py-2 text-xs leading-xs font-semibold text-secondary shadow-lg ring-1 ring-border-secondary_alt",
|
|
12
12
|
});
|
|
13
13
|
|
|
14
14
|
interface SliderProps extends AriaSliderProps {
|
|
@@ -55,7 +55,7 @@ export const Slider = ({
|
|
|
55
55
|
index={index}
|
|
56
56
|
className={({ isFocusVisible, isDragging }) =>
|
|
57
57
|
cx(
|
|
58
|
-
"absolute top-1/2 z-50 box-border size-6 cursor-grab rounded-full bg-slider-handle-bg
|
|
58
|
+
"absolute top-1/2 z-50 box-border size-6 cursor-grab rounded-full bg-slider-handle-bg shadow-md ring-2 ring-slider-handle-border ring-inset",
|
|
59
59
|
isFocusVisible && "outline-2 outline-offset-2 outline-focus-ring",
|
|
60
60
|
isDragging && "cursor-grabbing",
|
|
61
61
|
)
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import type { RefAttributes } from "react";
|
|
4
4
|
import { XClose } from "@untitledui/icons";
|
|
5
5
|
import { Button as AriaButton, type ButtonProps } from "react-aria-components";
|
|
6
|
-
import { cx } from "@/components/utils";
|
|
6
|
+
import { cx } from "@/components/utils/cx";
|
|
7
7
|
|
|
8
8
|
interface TagCloseXProps extends ButtonProps, RefAttributes<HTMLButtonElement> {
|
|
9
9
|
size?: "sm" | "md" | "lg";
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
type TagProps as AriaTagProps,
|
|
10
10
|
} from "react-aria-components";
|
|
11
11
|
import Dot from "@/components/foundations/dot-icon";
|
|
12
|
-
import { cx } from "@/components/utils";
|
|
12
|
+
import { cx } from "@/components/utils/cx";
|
|
13
13
|
import Avatar from "../avatar/avatar";
|
|
14
14
|
import TagCheckbox from "./base-components/tag-checkbox";
|
|
15
15
|
import { TagCloseX } from "./base-components/tag-close-x";
|
|
@@ -6,7 +6,7 @@ import type { TextAreaProps as AriaTextAreaProps, TextFieldProps as AriaTextFiel
|
|
|
6
6
|
import { TextArea as AriaTextArea } from "react-aria-components";
|
|
7
7
|
import HintText from "@/components/shared/input/hint-text";
|
|
8
8
|
import Label from "@/components/shared/input/label";
|
|
9
|
-
import { cx } from "@/components/utils";
|
|
9
|
+
import { cx } from "@/components/utils/cx";
|
|
10
10
|
import { TextField } from "../input";
|
|
11
11
|
|
|
12
12
|
interface TextAreaBaseProps extends AriaTextAreaProps {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import type { ReactNode } from "react";
|
|
4
4
|
import type { SwitchProps } from "react-aria-components";
|
|
5
5
|
import { Switch } from "react-aria-components";
|
|
6
|
-
import { cx } from "@/components/utils";
|
|
6
|
+
import { cx } from "@/components/utils/cx";
|
|
7
7
|
|
|
8
8
|
interface ToggleBaseProps {
|
|
9
9
|
size?: "sm" | "md";
|
|
@@ -7,7 +7,7 @@ import type { FocusableElement } from "@react-types/shared";
|
|
|
7
7
|
import { mergeProps, useFocusable } from "react-aria";
|
|
8
8
|
import { Tooltip as AriaTooltip, TooltipTrigger as AriaTooltipTrigger, Button, OverlayArrow } from "react-aria-components";
|
|
9
9
|
import type { TooltipProps as AriaTooltipProps, ButtonProps, TooltipTriggerComponentProps } from "react-aria-components";
|
|
10
|
-
import { cx } from "@/components/utils";
|
|
10
|
+
import { cx } from "@/components/utils/cx";
|
|
11
11
|
|
|
12
12
|
const padding: Partial<Record<Placement, string>> = {
|
|
13
13
|
"top left": "px-2.5",
|