@inkindcards/semantic-layer 2.1.0 → 2.2.1
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/{chunk-W64RGDXH.cjs → chunk-JLZMOWJ2.cjs} +65 -6
- package/dist/chunk-JLZMOWJ2.cjs.map +1 -0
- package/dist/{chunk-WR4D3UI6.js → chunk-ZYY77QMO.js} +65 -6
- package/dist/chunk-ZYY77QMO.js.map +1 -0
- package/dist/components.cjs +38 -27
- package/dist/components.cjs.map +1 -1
- package/dist/components.d.cts +3 -2
- package/dist/components.d.ts +3 -2
- package/dist/components.js +38 -27
- package/dist/components.js.map +1 -1
- package/dist/index.cjs +3 -3
- package/dist/index.d.cts +10 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.js +1 -1
- package/dist/react.cjs +28 -3
- package/dist/react.cjs.map +1 -1
- package/dist/react.js +27 -2
- package/dist/react.js.map +1 -1
- package/package.json +1 -1
- package/dist/chunk-W64RGDXH.cjs.map +0 -1
- package/dist/chunk-WR4D3UI6.js.map +0 -1
package/dist/components.d.cts
CHANGED
|
@@ -61,8 +61,9 @@ interface InspectableProps {
|
|
|
61
61
|
}
|
|
62
62
|
/**
|
|
63
63
|
* Wraps a data-bound component and registers it with the DataInspector overlay.
|
|
64
|
-
* When no DataInspector
|
|
65
|
-
* with no
|
|
64
|
+
* When inspect mode is off or no DataInspector ancestor exists, renders children
|
|
65
|
+
* with zero layout impact (no wrapper div). Only adds a positioned wrapper
|
|
66
|
+
* with a click-capture overlay when inspect mode is active.
|
|
66
67
|
*/
|
|
67
68
|
declare function Inspectable({ label, currentSource, data, columns, children, }: InspectableProps): react_jsx_runtime.JSX.Element;
|
|
68
69
|
|
package/dist/components.d.ts
CHANGED
|
@@ -61,8 +61,9 @@ interface InspectableProps {
|
|
|
61
61
|
}
|
|
62
62
|
/**
|
|
63
63
|
* Wraps a data-bound component and registers it with the DataInspector overlay.
|
|
64
|
-
* When no DataInspector
|
|
65
|
-
* with no
|
|
64
|
+
* When inspect mode is off or no DataInspector ancestor exists, renders children
|
|
65
|
+
* with zero layout impact (no wrapper div). Only adds a positioned wrapper
|
|
66
|
+
* with a click-capture overlay when inspect mode is active.
|
|
66
67
|
*/
|
|
67
68
|
declare function Inspectable({ label, currentSource, data, columns, children, }: InspectableProps): react_jsx_runtime.JSX.Element;
|
|
68
69
|
|
package/dist/components.js
CHANGED
|
@@ -862,48 +862,59 @@ function Inspectable({
|
|
|
862
862
|
return /* @__PURE__ */ jsx(Fragment, { children });
|
|
863
863
|
}
|
|
864
864
|
const isSelected = registry.selectedId === id;
|
|
865
|
-
const
|
|
865
|
+
const inspecting = registry.inspectActive;
|
|
866
866
|
const handleClick = (e) => {
|
|
867
|
-
if (!registry.inspectActive) return;
|
|
868
867
|
e.stopPropagation();
|
|
868
|
+
e.preventDefault();
|
|
869
869
|
registry.setSelectedId(isSelected ? null : id);
|
|
870
870
|
};
|
|
871
|
+
if (!inspecting) {
|
|
872
|
+
return /* @__PURE__ */ jsx("div", { ref, children });
|
|
873
|
+
}
|
|
871
874
|
return /* @__PURE__ */ jsxs(
|
|
872
875
|
"div",
|
|
873
876
|
{
|
|
874
877
|
ref,
|
|
875
|
-
|
|
876
|
-
style: {
|
|
877
|
-
position: "relative",
|
|
878
|
-
outline: showOutline ? isSelected ? "2px solid #3b82f6" : "2px dashed #93c5fd" : "none",
|
|
879
|
-
outlineOffset: 2,
|
|
880
|
-
borderRadius: 4,
|
|
881
|
-
cursor: showOutline ? "pointer" : "inherit",
|
|
882
|
-
transition: "outline 0.15s ease"
|
|
883
|
-
},
|
|
878
|
+
style: { position: "relative" },
|
|
884
879
|
children: [
|
|
885
|
-
|
|
880
|
+
children,
|
|
881
|
+
/* @__PURE__ */ jsx(
|
|
886
882
|
"div",
|
|
887
883
|
{
|
|
884
|
+
onClick: handleClick,
|
|
888
885
|
style: {
|
|
889
886
|
position: "absolute",
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
borderRadius: 3,
|
|
899
|
-
zIndex: 1e4,
|
|
900
|
-
pointerEvents: "none",
|
|
901
|
-
whiteSpace: "nowrap"
|
|
887
|
+
inset: 0,
|
|
888
|
+
zIndex: 9999,
|
|
889
|
+
cursor: "pointer",
|
|
890
|
+
outline: isSelected ? "2px solid #3b82f6" : "2px dashed #93c5fd",
|
|
891
|
+
outlineOffset: 2,
|
|
892
|
+
borderRadius: 4,
|
|
893
|
+
transition: "outline 0.15s ease",
|
|
894
|
+
background: isSelected ? "rgba(59,130,246,0.05)" : "transparent"
|
|
902
895
|
},
|
|
903
|
-
children:
|
|
896
|
+
children: /* @__PURE__ */ jsx(
|
|
897
|
+
"div",
|
|
898
|
+
{
|
|
899
|
+
style: {
|
|
900
|
+
position: "absolute",
|
|
901
|
+
top: -10,
|
|
902
|
+
left: 4,
|
|
903
|
+
fontSize: 10,
|
|
904
|
+
fontWeight: 600,
|
|
905
|
+
fontFamily: "system-ui, -apple-system, sans-serif",
|
|
906
|
+
color: "#fff",
|
|
907
|
+
backgroundColor: isSelected ? "#3b82f6" : "#93c5fd",
|
|
908
|
+
padding: "1px 6px",
|
|
909
|
+
borderRadius: 3,
|
|
910
|
+
pointerEvents: "none",
|
|
911
|
+
whiteSpace: "nowrap"
|
|
912
|
+
},
|
|
913
|
+
children: label
|
|
914
|
+
}
|
|
915
|
+
)
|
|
904
916
|
}
|
|
905
|
-
)
|
|
906
|
-
children
|
|
917
|
+
)
|
|
907
918
|
]
|
|
908
919
|
}
|
|
909
920
|
);
|