@plexui/ui 0.8.0 → 0.9.0
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/es/components/Separator/Separator.js +10 -0
- package/dist/es/components/Separator/Separator.js.map +1 -0
- package/dist/es/components/Separator/Separator.module.css +16 -0
- package/dist/es/components/Separator/index.js +2 -0
- package/dist/es/components/Separator/index.js.map +1 -0
- package/dist/es/styles/variables-components.css +6 -0
- package/dist/types/components/Separator/Separator.d.ts +18 -0
- package/dist/types/components/Separator/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
+
import clsx from "clsx";
|
|
4
|
+
import {} from "react";
|
|
5
|
+
import { Separator as RadixSeparator } from "radix-ui";
|
|
6
|
+
import s from "./Separator.module.css";
|
|
7
|
+
export const Separator = ({ orientation = "horizontal", decorative = true, className, ...restProps }) => {
|
|
8
|
+
return (_jsx(RadixSeparator.Root, { orientation: orientation, decorative: decorative, className: clsx(s.Separator, className), ...restProps }));
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=Separator.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Separator.js","sourceRoot":"","sources":["../../../../src/components/Separator/Separator.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAA;;AAEZ,OAAO,IAAI,MAAM,MAAM,CAAA;AACvB,OAAO,EAAuB,MAAM,OAAO,CAAA;AAC3C,OAAO,EAAE,SAAS,IAAI,cAAc,EAAE,MAAM,UAAU,CAAA;AACtD,OAAO,CAAC,MAAM,wBAAwB,CAAA;AAqBtC,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,EACxB,WAAW,GAAG,YAAY,EAC1B,UAAU,GAAG,IAAI,EACjB,SAAS,EACT,GAAG,SAAS,EACG,EAAE,EAAE;IACnB,OAAO,CACL,KAAC,cAAc,CAAC,IAAI,IAClB,WAAW,EAAE,WAAW,EACxB,UAAU,EAAE,UAAU,EACtB,SAAS,EAAE,IAAI,CAAC,CAAC,CAAC,SAAS,EAAE,SAAS,CAAC,KACnC,SAAS,GACb,CACH,CAAA;AACH,CAAC,CAAA","sourcesContent":["\"use client\"\n\nimport clsx from \"clsx\"\nimport { type ComponentProps } from \"react\"\nimport { Separator as RadixSeparator } from \"radix-ui\"\nimport s from \"./Separator.module.css\"\n\nexport type SeparatorProps = Omit<\n ComponentProps<typeof RadixSeparator.Root>,\n \"children\"\n> & {\n /**\n * Direction of the separator.\n * @default horizontal\n */\n orientation?: \"horizontal\" | \"vertical\"\n /**\n * When `true`, the separator is ignored by assistive technologies.\n * Leave `true` for purely visual dividers; set `false` when the separator\n * conveys meaningful grouping (it will render with `role=\"separator\"`).\n * @default true\n */\n decorative?: boolean\n className?: string\n}\n\nexport const Separator = ({\n orientation = \"horizontal\",\n decorative = true,\n className,\n ...restProps\n}: SeparatorProps) => {\n return (\n <RadixSeparator.Root\n orientation={orientation}\n decorative={decorative}\n className={clsx(s.Separator, className)}\n {...restProps}\n />\n )\n}\n"]}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
@layer components {.Separator {
|
|
2
|
+
flex-shrink: 0;
|
|
3
|
+
background: var(--separator-color);
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
.Separator[data-orientation="horizontal"] {
|
|
7
|
+
width: 100%;
|
|
8
|
+
height: var(--separator-thickness);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.Separator[data-orientation="vertical"] {
|
|
12
|
+
width: var(--separator-thickness);
|
|
13
|
+
height: 100%;
|
|
14
|
+
min-height: 1em;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/components/Separator/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAuB,MAAM,aAAa,CAAA","sourcesContent":["export { Separator, type SeparatorProps } from \"./Separator\"\n"]}
|
|
@@ -102,6 +102,12 @@
|
|
|
102
102
|
--card-description-color: var(--color-text-tertiary);
|
|
103
103
|
--card-description-font-size: var(--font-text-sm-size);
|
|
104
104
|
|
|
105
|
+
/* =============================================
|
|
106
|
+
Separator
|
|
107
|
+
============================================= */
|
|
108
|
+
--separator-color: var(--color-border);
|
|
109
|
+
--separator-thickness: 1px;
|
|
110
|
+
|
|
105
111
|
/* =============================================
|
|
106
112
|
Checkbox
|
|
107
113
|
============================================= */
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { type ComponentProps } from "react";
|
|
2
|
+
import { Separator as RadixSeparator } from "radix-ui";
|
|
3
|
+
export type SeparatorProps = Omit<ComponentProps<typeof RadixSeparator.Root>, "children"> & {
|
|
4
|
+
/**
|
|
5
|
+
* Direction of the separator.
|
|
6
|
+
* @default horizontal
|
|
7
|
+
*/
|
|
8
|
+
orientation?: "horizontal" | "vertical";
|
|
9
|
+
/**
|
|
10
|
+
* When `true`, the separator is ignored by assistive technologies.
|
|
11
|
+
* Leave `true` for purely visual dividers; set `false` when the separator
|
|
12
|
+
* conveys meaningful grouping (it will render with `role="separator"`).
|
|
13
|
+
* @default true
|
|
14
|
+
*/
|
|
15
|
+
decorative?: boolean;
|
|
16
|
+
className?: string;
|
|
17
|
+
};
|
|
18
|
+
export declare const Separator: ({ orientation, decorative, className, ...restProps }: SeparatorProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Separator, type SeparatorProps } from "./Separator";
|