UNPKG

@suiware/kit

Version:

Opinionated React components and hooks for building Sui dApps.

19 lines (17 loc) 666 B
import { useNetworkType_default } from './chunk-XIMYSCDZ.mjs'; import { Badge } from '@radix-ui/themes'; import { jsx } from 'react/jsx-runtime'; var NetworkType = () => { const { networkType } = useNetworkType_default({ autoSync: true }); let color = "amber"; if (networkType == null) { color = "tomato"; } else if (networkType === "mainnet") { color = "green"; } return /* @__PURE__ */ jsx(Badge, { color, className: "sk-network-badge", children: networkType || "disconnected" }); }; var NetworkType_default = NetworkType; export { NetworkType_default }; //# sourceMappingURL=chunk-OCRJKDUB.mjs.map //# sourceMappingURL=chunk-OCRJKDUB.mjs.map