mirror of
https://github.com/anotherhadi/ilovetui.git
synced 2026-10-05 10:58:26 +02:00
Vendored
+23
@@ -0,0 +1,23 @@
|
||||
// @bun
|
||||
import {
|
||||
theme
|
||||
} from "./chunk-57mam43k.js";
|
||||
|
||||
// src/components/Box.tsx
|
||||
import { spread as _$spread } from "@opentui/solid";
|
||||
import { mergeProps as _$mergeProps } from "@opentui/solid";
|
||||
import { memo as _$memo } from "@opentui/solid";
|
||||
import { createElement as _$createElement } from "@opentui/solid";
|
||||
function Box(props) {
|
||||
return (() => {
|
||||
var _el$ = _$createElement("box");
|
||||
_$spread(_el$, _$mergeProps(props, {
|
||||
get borderStyle() {
|
||||
return props.borderStyle ?? theme.borderStyle;
|
||||
}
|
||||
}), false);
|
||||
return _el$;
|
||||
})();
|
||||
}
|
||||
|
||||
export { Box };
|
||||
Vendored
+11
@@ -0,0 +1,11 @@
|
||||
// @bun
|
||||
import {
|
||||
Box
|
||||
} from "../chunk-n96bgmbh.js";
|
||||
import"../chunk-57mam43k.js";
|
||||
import"../chunk-ergc99dh.js";
|
||||
import"../chunk-7f8jagy5.js";
|
||||
import"../chunk-hcq62p48.js";
|
||||
export {
|
||||
Box
|
||||
};
|
||||
Vendored
+10
-6
@@ -1,11 +1,7 @@
|
||||
// @bun
|
||||
import {
|
||||
Tabs,
|
||||
stepTabValue
|
||||
} from "../chunk-jb965p47.js";
|
||||
import {
|
||||
SignalBars
|
||||
} from "../chunk-xab9ag99.js";
|
||||
Box
|
||||
} from "../chunk-n96bgmbh.js";
|
||||
import {
|
||||
NotificationHost
|
||||
} from "../chunk-g7p0f33m.js";
|
||||
@@ -18,6 +14,10 @@ import {
|
||||
import {
|
||||
Sidebar
|
||||
} from "../chunk-vve1k0ax.js";
|
||||
import {
|
||||
Tabs,
|
||||
stepTabValue
|
||||
} from "../chunk-jb965p47.js";
|
||||
import {
|
||||
Modal
|
||||
} from "../chunk-4j2gzwtd.js";
|
||||
@@ -27,6 +27,9 @@ import {
|
||||
import {
|
||||
ProgressBar
|
||||
} from "../chunk-ae0jkf2z.js";
|
||||
import {
|
||||
SignalBars
|
||||
} from "../chunk-xab9ag99.js";
|
||||
import"../chunk-57mam43k.js";
|
||||
import"../chunk-ergc99dh.js";
|
||||
import"../chunk-7f8jagy5.js";
|
||||
@@ -42,5 +45,6 @@ export {
|
||||
NotificationHost,
|
||||
Modal,
|
||||
MinSizeGuard,
|
||||
Box,
|
||||
Badge
|
||||
};
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
import type { BoxProps as OpenTUIBoxProps } from "@opentui/solid";
|
||||
import { theme } from "../index.ts";
|
||||
|
||||
export interface BoxProps extends OpenTUIBoxProps {}
|
||||
|
||||
// The raw <box> intrinsic has no idea ilovetui's theme exists — its own
|
||||
// borderStyle default ("single") is hardcoded in @opentui/core. Use <Box>
|
||||
// instead of <box> wherever you want theme.borderStyle applied by default,
|
||||
// same as Sidebar/Modal/Tabs already do internally.
|
||||
export function Box(props: BoxProps) {
|
||||
return <box {...props} borderStyle={props.borderStyle ?? theme.borderStyle} />;
|
||||
}
|
||||
@@ -1,4 +1,5 @@
|
||||
export { Badge, type BadgeProps } from "./Badge.tsx";
|
||||
export { Box, type BoxProps } from "./Box.tsx";
|
||||
export { MinSizeGuard, type MinSizeGuardProps } from "./MinSizeGuard.tsx";
|
||||
export { Modal, type ModalProps } from "./Modal.tsx";
|
||||
export { NotificationHost, type NotificationHostProps } from "./NotificationHost.tsx";
|
||||
|
||||
Reference in New Issue
Block a user