@nattstack/ui 0.0.3 → 0.0.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/dist/components/{button.module-EYMY7VLZ.module.css → button.module-7VWY2WUV.module.css} +1 -1
- package/dist/components/index.d.ts +3 -2
- package/dist/components/index.js +7 -8
- package/dist/components/{label.module-HUBUIUFV.module.css → label.module-NYFSR6AT.module.css} +2 -2
- package/dist/components/tooltip-content.module-QGRFS5NN.module.css +18 -0
- package/package.json +1 -1
- package/dist/components/tooltip-content.module-5MWTMSBY.module.css +0 -13
|
@@ -244,11 +244,12 @@ declare const TEXTAREA_CLASS_NAME: {
|
|
|
244
244
|
};
|
|
245
245
|
};
|
|
246
246
|
|
|
247
|
-
interface TooltipProps extends Tooltip$1.Root.Props {
|
|
247
|
+
interface TooltipProps extends Omit<Tooltip$1.Root.Props, "disabled"> {
|
|
248
|
+
isDisabled?: Tooltip$1.Root.Props["disabled"];
|
|
248
249
|
}
|
|
249
250
|
declare function Tooltip(props: TooltipProps): JSX.Element;
|
|
250
251
|
|
|
251
|
-
interface TooltipContentProps extends Pick<Tooltip$1.Positioner.Props, "side">, Tooltip$1.Popup.Props {
|
|
252
|
+
interface TooltipContentProps extends Pick<Tooltip$1.Positioner.Props, "side" | "sideOffset">, Tooltip$1.Popup.Props {
|
|
252
253
|
}
|
|
253
254
|
declare function TooltipContent(props: TooltipContentProps): JSX.Element;
|
|
254
255
|
declare const TOOLTIP_CONTENT_CLASS_NAME: {
|
package/dist/components/index.js
CHANGED
|
@@ -15,7 +15,7 @@ function normalizeWhitespace(value) {
|
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
// src/components/button/button.tsx
|
|
18
|
-
import styles2 from "./button.module-
|
|
18
|
+
import styles2 from "./button.module-7VWY2WUV.module.css";
|
|
19
19
|
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
20
20
|
function Button(props) {
|
|
21
21
|
const {
|
|
@@ -354,7 +354,7 @@ var INPUT_CLASS_NAME = {
|
|
|
354
354
|
};
|
|
355
355
|
|
|
356
356
|
// src/components/label/label.tsx
|
|
357
|
-
import styles10 from "./label.module-
|
|
357
|
+
import styles10 from "./label.module-NYFSR6AT.module.css";
|
|
358
358
|
import { jsx as jsx11 } from "react/jsx-runtime";
|
|
359
359
|
function Label(props) {
|
|
360
360
|
const { className: customClassName = "", htmlFor = void 0, children = "", ...rest } = props;
|
|
@@ -767,17 +767,16 @@ var TEXTAREA_CLASS_NAME = {
|
|
|
767
767
|
import { Tooltip as BaseTooltip } from "@base-ui/react";
|
|
768
768
|
import { jsx as jsx26 } from "react/jsx-runtime";
|
|
769
769
|
function Tooltip(props) {
|
|
770
|
-
const { ...rest } = props;
|
|
771
|
-
return /* @__PURE__ */ jsx26(BaseTooltip.Root, { "data-slot": "tooltip", disableHoverablePopup: true, ...rest });
|
|
770
|
+
const { isDisabled = false, ...rest } = props;
|
|
771
|
+
return /* @__PURE__ */ jsx26(BaseTooltip.Root, { "data-slot": "tooltip", disabled: isDisabled, disableHoverablePopup: true, ...rest });
|
|
772
772
|
}
|
|
773
773
|
|
|
774
774
|
// src/components/tooltip/tooltip-content.tsx
|
|
775
775
|
import { Tooltip as BaseTooltip2 } from "@base-ui/react";
|
|
776
|
-
import styles26 from "./tooltip-content.module-
|
|
776
|
+
import styles26 from "./tooltip-content.module-QGRFS5NN.module.css";
|
|
777
777
|
import { jsx as jsx27, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
778
778
|
function TooltipContent(props) {
|
|
779
|
-
const { children, className: customClassName = "", side = "top", ...rest } = props;
|
|
780
|
-
const SIDE_OFFSET = 4;
|
|
779
|
+
const { children, className: customClassName = "", side = "top", sideOffset = 4, ...rest } = props;
|
|
781
780
|
const combinedClassName = normalizeWhitespace(`
|
|
782
781
|
${TOOLTIP_CONTENT_CLASS_NAME.BASE}
|
|
783
782
|
${customClassName}
|
|
@@ -787,7 +786,7 @@ function TooltipContent(props) {
|
|
|
787
786
|
{
|
|
788
787
|
className: styles26.tooltip_content_positioner,
|
|
789
788
|
side,
|
|
790
|
-
sideOffset
|
|
789
|
+
sideOffset,
|
|
791
790
|
children: [
|
|
792
791
|
/* @__PURE__ */ jsx27(BaseTooltip2.Popup, { className: combinedClassName, "data-slot": "tooltip-content", ...rest, children }),
|
|
793
792
|
/* @__PURE__ */ jsx27(BaseTooltip2.Arrow, {})
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
.tooltip_content {
|
|
2
|
+
background-color: var(--color-gray-dark-1);
|
|
3
|
+
border-radius: 8px;
|
|
4
|
+
color: var(--color-gray-dark-12);
|
|
5
|
+
font-size: 13px;
|
|
6
|
+
font-weight: 500;
|
|
7
|
+
padding: 4px 8px;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.tooltip_content_positioner {
|
|
11
|
+
isolation: isolate;
|
|
12
|
+
z-index: 50;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
:global(.dark) .tooltip_content {
|
|
16
|
+
background-color: var(--color-gray-light-1);
|
|
17
|
+
color: var(--color-gray-light-12);
|
|
18
|
+
}
|
package/package.json
CHANGED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
.tooltip_content {
|
|
2
|
-
background-color: var(--color-gray-1);
|
|
3
|
-
border-radius: 8px;
|
|
4
|
-
border: 1px solid var(--color-gray-4);
|
|
5
|
-
color: var(--color-gray-12);
|
|
6
|
-
font-size: 14px;
|
|
7
|
-
padding: 4px 8px;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
.tooltip_content_positioner {
|
|
11
|
-
isolation: isolate;
|
|
12
|
-
z-index: 50;
|
|
13
|
-
}
|