@monolith-forensics/monolith-ui 1.1.31 → 1.1.32
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/Flyout/Flyout.js
CHANGED
|
@@ -2,6 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
2
2
|
import { FloatingFocusManager, FloatingOverlay, FloatingPortal, useFloating, } from "@floating-ui/react";
|
|
3
3
|
import { XIcon } from "lucide-react";
|
|
4
4
|
import styled from "styled-components";
|
|
5
|
+
import { Themes } from "../theme";
|
|
5
6
|
const ANIMATION_TIME = 300;
|
|
6
7
|
const StyledOverlay = styled(FloatingOverlay) `
|
|
7
8
|
background-color: rgba(0, 0, 0, 0.3);
|
|
@@ -39,7 +40,7 @@ const StyledButton = styled.button `
|
|
|
39
40
|
}
|
|
40
41
|
`;
|
|
41
42
|
const StyledContent = styled.div `
|
|
42
|
-
background-color: ${({ theme }) => theme.name ===
|
|
43
|
+
background-color: ${({ theme }) => theme.name === Themes.DARK
|
|
43
44
|
? theme.palette.background.alt
|
|
44
45
|
: theme.palette.background.default};
|
|
45
46
|
border-radius: 6px;
|
package/dist/Modal/Modal.js
CHANGED
|
@@ -2,6 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
2
2
|
import styled from "styled-components";
|
|
3
3
|
import { X } from "lucide-react";
|
|
4
4
|
import { FloatingFocusManager, FloatingOverlay, FloatingPortal, useFloating, } from "@floating-ui/react";
|
|
5
|
+
import { Themes } from "../theme";
|
|
5
6
|
const StyledOverlay = styled(FloatingOverlay) `
|
|
6
7
|
background-color: rgba(0, 0, 0, 0.3);
|
|
7
8
|
position: fixed;
|
|
@@ -18,7 +19,7 @@ const StyledOverlay = styled(FloatingOverlay) `
|
|
|
18
19
|
}
|
|
19
20
|
`;
|
|
20
21
|
const StyledContent = styled.div `
|
|
21
|
-
background-color: ${({ theme }) => theme.name ===
|
|
22
|
+
background-color: ${({ theme }) => theme.name === Themes.DARK
|
|
22
23
|
? theme.palette.background.default
|
|
23
24
|
: theme.palette.background.default};
|
|
24
25
|
border-radius: 6px;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import merge from "deepmerge";
|
|
3
3
|
import { ThemeProvider } from "styled-components";
|
|
4
|
-
import getTheme from "../theme";
|
|
4
|
+
import getTheme, { Themes } from "../theme";
|
|
5
5
|
import { createContext, useState } from "react";
|
|
6
6
|
import GlobalStyle from "./GlobalStyle";
|
|
7
7
|
export const MonolithUIContext = createContext(undefined);
|
|
@@ -15,6 +15,7 @@ const MonolithUIProvider = ({ children, theme = {}, defaultColorScheme = "dark",
|
|
|
15
15
|
const _theme = merge(defaultTheme, theme);
|
|
16
16
|
return (_jsx(MonolithUIContext.Provider, { value: {
|
|
17
17
|
theme: _theme,
|
|
18
|
+
Themes,
|
|
18
19
|
colorScheme,
|
|
19
20
|
toggleColorScheme,
|
|
20
21
|
setColorScheme,
|
package/dist/Switch/Switch.js
CHANGED
|
@@ -13,6 +13,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
13
13
|
import styled from "styled-components";
|
|
14
14
|
import * as RadixSwitch from "@radix-ui/react-switch";
|
|
15
15
|
import { FieldLabel } from "..";
|
|
16
|
+
import { Themes } from "../theme";
|
|
16
17
|
const StyledRoot = styled(RadixSwitch.Root) `
|
|
17
18
|
all: unset;
|
|
18
19
|
cursor: pointer;
|
|
@@ -41,11 +42,11 @@ const StyledRoot = styled(RadixSwitch.Root) `
|
|
|
41
42
|
? "70px"
|
|
42
43
|
: "26px"};
|
|
43
44
|
|
|
44
|
-
background-color: ${({ theme }) => theme.name ===
|
|
45
|
+
background-color: ${({ theme }) => theme.name === Themes.DARK ? "#383838" : "#e3e3e3"};
|
|
45
46
|
transition: background-color 100ms;
|
|
46
47
|
border-radius: 9999px;
|
|
47
48
|
border: 1px solid
|
|
48
|
-
${({ theme }) => theme.name ===
|
|
49
|
+
${({ theme }) => theme.name === Themes.DARK ? theme.palette.input.border : "#e3e3e3"};
|
|
49
50
|
position: relative;
|
|
50
51
|
padding: ${({ size }) => size === "xs"
|
|
51
52
|
? "2px"
|
package/dist/Table/Table.js
CHANGED
|
@@ -22,7 +22,7 @@ import { ArrowUpIcon, ArrowDownIcon } from "lucide-react";
|
|
|
22
22
|
import moment from "moment";
|
|
23
23
|
import { CheckBox } from "..";
|
|
24
24
|
const MIN_COLUMN_WIDTH = 125;
|
|
25
|
-
export const Column = ({ dataField, caption, columnId = shortUUID.generate(), sorting, format,
|
|
25
|
+
export const Column = ({ dataField, caption, columnId = shortUUID.generate(), sorting, format, }) => {
|
|
26
26
|
return null;
|
|
27
27
|
};
|
|
28
28
|
Column.displayName = "Column";
|
|
@@ -157,7 +157,7 @@ const StyledTh = styled.th `
|
|
|
157
157
|
}
|
|
158
158
|
|
|
159
159
|
&:hover {
|
|
160
|
-
background-color: ${({ theme }) => theme.name === "
|
|
160
|
+
background-color: ${({ theme }) => theme.name === "dark" ? "#2e2e2e" : "#f5f5f5"};
|
|
161
161
|
cursor: pointer;
|
|
162
162
|
}
|
|
163
163
|
&.dragging:active {
|
|
@@ -436,7 +436,7 @@ const Table = styled(({ className, children, data, rowHeight, headerHeight, tabl
|
|
|
436
436
|
}, [children]);
|
|
437
437
|
let columns = useMemo(() => {
|
|
438
438
|
var _a, _b;
|
|
439
|
-
return (_b = (_a = children === null || children === void 0 ? void 0 : children.filter) === null || _a === void 0 ? void 0 : _a.call(children, (child) => child.
|
|
439
|
+
return (_b = (_a = children === null || children === void 0 ? void 0 : children.filter) === null || _a === void 0 ? void 0 : _a.call(children, (child) => { var _a; return ((_a = child.type) === null || _a === void 0 ? void 0 : _a.displayName) === "Column"; })) === null || _b === void 0 ? void 0 : _b.map((column) => {
|
|
440
440
|
return cloneElement(column, {
|
|
441
441
|
columnId: shortUUID.generate(),
|
|
442
442
|
allowResize: allowColumnResize !== undefined
|
package/dist/theme/index.js
CHANGED