@uisatin/ui 0.2.0 → 0.4.0
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/CHANGELOG.md +27 -0
- package/README.md +10 -1
- package/{chunk-P4O6TGDR.js → chunk-3VVO5MY5.js} +28 -26
- package/chunk-47DDBME3.js +87 -0
- package/{chunk-SHDFUXYV.js → chunk-5663JVE5.js} +16 -18
- package/chunk-67CBFB6Y.js +99 -0
- package/chunk-6DWLTGRQ.js +130 -0
- package/chunk-6GNMUJQ4.js +45 -0
- package/chunk-6JTSZAGO.js +177 -0
- package/chunk-6RLSRMB5.js +14 -0
- package/chunk-6Y6CY2DP.js +55 -0
- package/{chunk-O7F3CIDV.js → chunk-7NV53EL5.js} +10 -12
- package/{chunk-BNZVTLHV.js → chunk-7SVMERPH.js} +25 -21
- package/chunk-A52HUWVM.js +24 -0
- package/chunk-AKEZCWNW.js +29 -0
- package/{chunk-SH6NG6VN.js → chunk-APRVUOD6.js} +6 -8
- package/{chunk-QUF2IPOZ.js → chunk-C435UD7V.js} +14 -15
- package/{chunk-B2K45IUR.js → chunk-C6WRJ7DG.js} +5 -7
- package/{chunk-PF3YBUKT.js → chunk-CQFAMWZI.js} +16 -15
- package/chunk-DAKVTPYZ.js +86 -0
- package/{chunk-VAGIAREV.js → chunk-DMZW4LGU.js} +29 -26
- package/chunk-EBZHGRM5.js +46 -0
- package/chunk-EHEXE2UV.js +44 -0
- package/{chunk-72OCFAPT.js → chunk-EQAFDIPE.js} +26 -23
- package/{chunk-LLHTVIM3.js → chunk-EXKSKYG3.js} +7 -9
- package/chunk-FB6DG3LR.js +35 -0
- package/chunk-GH2DEOGO.js +67 -0
- package/{chunk-YG7JOOLJ.js → chunk-GKDMCY2S.js} +5 -7
- package/chunk-GTFUAA6H.js +42 -0
- package/{chunk-TX3H3QMA.js → chunk-HI6QIG55.js} +71 -70
- package/{chunk-6QMSWITQ.js → chunk-HZV7EXGU.js} +24 -26
- package/{chunk-A5XEM3GF.js → chunk-IKJIR6VL.js} +34 -36
- package/{chunk-DO3TBNSC.js → chunk-INJWE2LD.js} +15 -17
- package/chunk-J5UQPROI.js +56 -0
- package/{chunk-6YXUBP27.js → chunk-JCR5TWTF.js} +72 -67
- package/chunk-JKOBDLP3.js +25 -0
- package/chunk-JR3VVDV6.js +37 -0
- package/chunk-JYGCZWET.js +112 -0
- package/{chunk-UGRSWP6U.js → chunk-K5G5OEV5.js} +10 -12
- package/{chunk-B6V4VSGH.js → chunk-KDU7AT2T.js} +14 -15
- package/chunk-KITXKIYW.js +104 -0
- package/{chunk-NN6PKJWS.js → chunk-KQNA22D3.js} +7 -9
- package/{chunk-YPNKBE5X.js → chunk-L5PPN42A.js} +14 -9
- package/chunk-LAOE6Y57.js +95 -0
- package/chunk-LI5VYDLN.js +195 -0
- package/{chunk-7TXHCRAG.js → chunk-LKSFTNPF.js} +8 -10
- package/chunk-LLW3X4ZJ.js +39 -0
- package/{chunk-RTJ76X5U.js → chunk-LWRB4DED.js} +2 -4
- package/{chunk-NSRTTYQ4.js → chunk-M7RILZVW.js} +42 -35
- package/{chunk-LW3TRU5W.js → chunk-MOGWOUCN.js} +28 -16
- package/chunk-NCIRJ5V2.js +108 -0
- package/chunk-NQL6SIIB.js +168 -0
- package/chunk-NTSU44FY.js +81 -0
- package/{chunk-3DINAQLL.js → chunk-P36KBUYD.js} +33 -29
- package/chunk-P6RHT2VM.js +147 -0
- package/{chunk-CL2II6BX.js → chunk-PD2KD5OR.js} +11 -13
- package/{chunk-XL75JRUA.js → chunk-PP46SY7M.js} +42 -22
- package/{chunk-L6NCCSIP.js → chunk-PTK4QAOQ.js} +36 -29
- package/{chunk-HL42K2NH.js → chunk-Q7KVC5B4.js} +17 -17
- package/{chunk-H4NU7NPO.js → chunk-R3DTMBDT.js} +62 -61
- package/{chunk-KNUWZNFV.js → chunk-R4KPFBMK.js} +4 -6
- package/chunk-R5TQ3HNB.js +71 -0
- package/chunk-RFSPJECL.js +84 -0
- package/chunk-RPL6FRVX.js +88 -0
- package/{chunk-AN2RNJLR.js → chunk-STYOBAC7.js} +16 -16
- package/{chunk-X3PQANZO.js → chunk-SVUWR3HD.js} +47 -46
- package/chunk-T7P3OEBP.js +128 -0
- package/{chunk-QS4N4MNP.js → chunk-TB3ZRV3Y.js} +18 -20
- package/{chunk-MYEZXZZC.js → chunk-TOY6YPTG.js} +23 -25
- package/{chunk-XILQ7GXE.js → chunk-U6X6ODDJ.js} +11 -13
- package/{chunk-XZNHT6MO.js → chunk-UAJ6M34K.js} +115 -61
- package/chunk-W2EH6RY5.js +42 -0
- package/{chunk-FDKIX4DC.js → chunk-W2QQQWNE.js} +7 -9
- package/{chunk-LZMKSFCF.js → chunk-WALANB3V.js} +10 -12
- package/chunk-WCUR44O6.js +88 -0
- package/{chunk-BNTPPZCK.js → chunk-WJYJMX5S.js} +37 -39
- package/chunk-WZSLDYUU.js +131 -0
- package/{chunk-J3NSDRVH.js → chunk-XETMIETJ.js} +0 -2
- package/chunk-XU6JJDMZ.js +117 -0
- package/{chunk-BKZBWPUH.js → chunk-XWPH7C2W.js} +9 -11
- package/{chunk-GICKPMJU.js → chunk-YXWXSRXG.js} +31 -31
- package/{chunk-2HKBZFIK.js → chunk-YY236ZSJ.js} +31 -31
- package/{chunk-YX5VNRJX.js → chunk-YYFAZQ25.js} +0 -2
- package/{chunk-Y5AYU7PK.js → chunk-ZHFIWDGF.js} +0 -2
- package/components/accordion.js +2 -4
- package/components/action-button.d.ts +37 -0
- package/components/action-button.js +5 -0
- package/components/agent-loading.d.ts +2 -0
- package/components/agent-loading.js +2 -4
- package/components/agent-picker.js +5 -5
- package/components/agent-suggestion.js +5 -6
- package/components/alert.d.ts +37 -0
- package/components/alert.js +5 -0
- package/components/announcement-bar.js +7 -7
- package/components/attachment.js +5 -5
- package/components/avatar.js +4 -6
- package/components/badge.js +2 -4
- package/components/banner-mesh.js +1 -3
- package/components/banner.js +6 -6
- package/components/bar-chart.js +10 -11
- package/components/breadcrumb.js +5 -6
- package/components/button-group.d.ts +26 -0
- package/components/button-group.js +5 -0
- package/components/button.d.ts +13 -1
- package/components/button.js +4 -4
- package/components/card.js +5 -5
- package/components/channel-chart.js +10 -11
- package/components/chart.js +9 -10
- package/components/checkbox.js +2 -4
- package/components/chip.js +2 -4
- package/components/citations.d.ts +6 -4
- package/components/citations.js +4 -5
- package/components/code-block.js +5 -5
- package/components/combobox.d.ts +12 -3
- package/components/combobox.js +10 -10
- package/components/command-menu.d.ts +6 -2
- package/components/command-menu.js +5 -6
- package/components/context-menu.d.ts +12 -5
- package/components/context-menu.js +5 -6
- package/components/cookie-consent.js +5 -5
- package/components/date-picker.d.ts +26 -14
- package/components/date-picker.js +9 -9
- package/components/decision-card.js +7 -7
- package/components/dialog.d.ts +6 -8
- package/components/dialog.js +6 -5
- package/components/donut-chart.js +10 -11
- package/components/dot.js +2 -4
- package/components/dropdown.d.ts +6 -1
- package/components/dropdown.js +4 -5
- package/components/empty-state.js +2 -4
- package/components/field-group.d.ts +27 -0
- package/components/field-group.js +3 -0
- package/components/file-upload.js +7 -7
- package/components/floating.js +1 -3
- package/components/form-field.d.ts +38 -1
- package/components/form-field.js +2 -4
- package/components/form.d.ts +47 -0
- package/components/form.js +3 -0
- package/components/hover-card.d.ts +5 -2
- package/components/hover-card.js +2 -4
- package/components/input-group.d.ts +21 -0
- package/components/input-group.js +6 -0
- package/components/input-otp.d.ts +4 -2
- package/components/input-otp.js +7 -8
- package/components/input.d.ts +5 -1
- package/components/input.js +3 -5
- package/components/kbd.js +2 -4
- package/components/labels.d.ts +86 -0
- package/components/labels.js +1 -0
- package/components/line-chart.js +11 -12
- package/components/link.d.ts +20 -0
- package/components/link.js +3 -0
- package/components/list.d.ts +46 -0
- package/components/list.js +2 -0
- package/components/message-actions.js +5 -5
- package/components/message.js +8 -8
- package/components/number-input.d.ts +4 -2
- package/components/number-input.js +7 -8
- package/components/pagination.js +6 -6
- package/components/password-input.d.ts +16 -0
- package/components/password-input.js +7 -0
- package/components/popover.d.ts +11 -5
- package/components/popover.js +3 -4
- package/components/progress.js +2 -4
- package/components/prompt-bar.js +6 -6
- package/components/radio.js +2 -4
- package/components/search-bar.js +3 -5
- package/components/segmented-control.d.ts +4 -2
- package/components/segmented-control.js +3 -5
- package/components/select.d.ts +11 -2
- package/components/select.js +6 -7
- package/components/selectable-card.d.ts +37 -0
- package/components/selectable-card.js +2 -0
- package/components/selectable-checkbox.d.ts +14 -0
- package/components/selectable-checkbox.js +4 -0
- package/components/selectable-radio.d.ts +16 -0
- package/components/selectable-radio.js +3 -0
- package/components/separator.d.ts +18 -0
- package/components/separator.js +2 -0
- package/components/sheet.d.ts +4 -2
- package/components/sheet.js +7 -6
- package/components/sidebar.js +2 -4
- package/components/skeleton.js +2 -4
- package/components/slider.d.ts +6 -2
- package/components/slider.js +7 -8
- package/components/sliding-indicator.js +1 -3
- package/components/spinner.d.ts +18 -0
- package/components/spinner.js +3 -0
- package/components/split-button.d.ts +24 -0
- package/components/split-button.js +8 -0
- package/components/streaming-text.js +2 -4
- package/components/switch.js +2 -4
- package/components/table.d.ts +16 -5
- package/components/table.js +4 -5
- package/components/tabs.d.ts +4 -2
- package/components/tabs.js +3 -5
- package/components/textarea.js +3 -5
- package/components/thinking.js +3 -5
- package/components/toast.js +5 -5
- package/components/toggle.js +2 -4
- package/components/tooltip.d.ts +5 -2
- package/components/tooltip.js +3 -5
- package/index.d.ts +17 -2
- package/index.js +82 -231
- package/lib/utils.d.ts +8 -1
- package/lib/utils.js +1 -3
- package/package.json +11 -1
- package/styles.css +1 -1
- package/theme/create-theme.d.ts +6 -2
- package/theme/index.js +1 -0
- package/chunk-2HKBZFIK.js.map +0 -1
- package/chunk-3DINAQLL.js.map +0 -1
- package/chunk-3ERGAHKA.js +0 -179
- package/chunk-3ERGAHKA.js.map +0 -1
- package/chunk-6C7CGJX2.js +0 -86
- package/chunk-6C7CGJX2.js.map +0 -1
- package/chunk-6QMSWITQ.js.map +0 -1
- package/chunk-6YXUBP27.js.map +0 -1
- package/chunk-72OCFAPT.js.map +0 -1
- package/chunk-7TXHCRAG.js.map +0 -1
- package/chunk-A5XEM3GF.js.map +0 -1
- package/chunk-AN2RNJLR.js.map +0 -1
- package/chunk-B2K45IUR.js.map +0 -1
- package/chunk-B6V4VSGH.js.map +0 -1
- package/chunk-BKZBWPUH.js.map +0 -1
- package/chunk-BNTPPZCK.js.map +0 -1
- package/chunk-BNZVTLHV.js.map +0 -1
- package/chunk-CL2II6BX.js.map +0 -1
- package/chunk-D7RZNTFC.js +0 -95
- package/chunk-D7RZNTFC.js.map +0 -1
- package/chunk-DETGJAIC.js +0 -147
- package/chunk-DETGJAIC.js.map +0 -1
- package/chunk-DO3TBNSC.js.map +0 -1
- package/chunk-ESC5JCVQ.js +0 -90
- package/chunk-ESC5JCVQ.js.map +0 -1
- package/chunk-FDKIX4DC.js.map +0 -1
- package/chunk-GICKPMJU.js.map +0 -1
- package/chunk-GQA24FYG.js +0 -57
- package/chunk-GQA24FYG.js.map +0 -1
- package/chunk-H4NU7NPO.js.map +0 -1
- package/chunk-H63FYCMY.js +0 -11
- package/chunk-H63FYCMY.js.map +0 -1
- package/chunk-HL42K2NH.js.map +0 -1
- package/chunk-HNQUX43Z.js +0 -109
- package/chunk-HNQUX43Z.js.map +0 -1
- package/chunk-HRKPV66B.js +0 -32
- package/chunk-HRKPV66B.js.map +0 -1
- package/chunk-J3NSDRVH.js.map +0 -1
- package/chunk-JPNWHWAQ.js +0 -151
- package/chunk-JPNWHWAQ.js.map +0 -1
- package/chunk-KNUWZNFV.js.map +0 -1
- package/chunk-L6NCCSIP.js.map +0 -1
- package/chunk-LLHTVIM3.js.map +0 -1
- package/chunk-LW3TRU5W.js.map +0 -1
- package/chunk-LZMKSFCF.js.map +0 -1
- package/chunk-MR3JDI7E.js +0 -122
- package/chunk-MR3JDI7E.js.map +0 -1
- package/chunk-MYEZXZZC.js.map +0 -1
- package/chunk-NN6PKJWS.js.map +0 -1
- package/chunk-NSRTTYQ4.js.map +0 -1
- package/chunk-O7F3CIDV.js.map +0 -1
- package/chunk-P4O6TGDR.js.map +0 -1
- package/chunk-PF3YBUKT.js.map +0 -1
- package/chunk-PVOLDO4G.js +0 -47
- package/chunk-PVOLDO4G.js.map +0 -1
- package/chunk-QS4N4MNP.js.map +0 -1
- package/chunk-QUF2IPOZ.js.map +0 -1
- package/chunk-RTJ76X5U.js.map +0 -1
- package/chunk-SH6NG6VN.js.map +0 -1
- package/chunk-SHDFUXYV.js.map +0 -1
- package/chunk-TKO44NDI.js +0 -84
- package/chunk-TKO44NDI.js.map +0 -1
- package/chunk-TX3H3QMA.js.map +0 -1
- package/chunk-UBNHSZSE.js +0 -88
- package/chunk-UBNHSZSE.js.map +0 -1
- package/chunk-UC3ZJWOD.js +0 -73
- package/chunk-UC3ZJWOD.js.map +0 -1
- package/chunk-UGRSWP6U.js.map +0 -1
- package/chunk-VAGIAREV.js.map +0 -1
- package/chunk-WTMZT3IT.js +0 -105
- package/chunk-WTMZT3IT.js.map +0 -1
- package/chunk-WX6BP5ZP.js +0 -39
- package/chunk-WX6BP5ZP.js.map +0 -1
- package/chunk-X3PQANZO.js.map +0 -1
- package/chunk-XILQ7GXE.js.map +0 -1
- package/chunk-XL75JRUA.js.map +0 -1
- package/chunk-XZNHT6MO.js.map +0 -1
- package/chunk-Y5AYU7PK.js.map +0 -1
- package/chunk-YG7JOOLJ.js.map +0 -1
- package/chunk-YPJYW624.js +0 -195
- package/chunk-YPJYW624.js.map +0 -1
- package/chunk-YPNKBE5X.js.map +0 -1
- package/chunk-YX5VNRJX.js.map +0 -1
- package/components/accordion.js.map +0 -1
- package/components/agent-loading.js.map +0 -1
- package/components/agent-picker.js.map +0 -1
- package/components/agent-suggestion.js.map +0 -1
- package/components/announcement-bar.js.map +0 -1
- package/components/attachment.js.map +0 -1
- package/components/avatar.js.map +0 -1
- package/components/badge.js.map +0 -1
- package/components/banner-mesh.js.map +0 -1
- package/components/banner.js.map +0 -1
- package/components/bar-chart.js.map +0 -1
- package/components/breadcrumb.js.map +0 -1
- package/components/button.js.map +0 -1
- package/components/card.js.map +0 -1
- package/components/channel-chart.js.map +0 -1
- package/components/chart.js.map +0 -1
- package/components/checkbox.js.map +0 -1
- package/components/chip.js.map +0 -1
- package/components/citations.js.map +0 -1
- package/components/code-block.js.map +0 -1
- package/components/combobox.js.map +0 -1
- package/components/command-menu.js.map +0 -1
- package/components/context-menu.js.map +0 -1
- package/components/cookie-consent.js.map +0 -1
- package/components/date-picker.js.map +0 -1
- package/components/decision-card.js.map +0 -1
- package/components/dialog.js.map +0 -1
- package/components/donut-chart.js.map +0 -1
- package/components/dot.js.map +0 -1
- package/components/dropdown.js.map +0 -1
- package/components/empty-state.js.map +0 -1
- package/components/file-upload.js.map +0 -1
- package/components/floating.js.map +0 -1
- package/components/form-field.js.map +0 -1
- package/components/hover-card.js.map +0 -1
- package/components/input-otp.js.map +0 -1
- package/components/input.js.map +0 -1
- package/components/kbd.js.map +0 -1
- package/components/line-chart.js.map +0 -1
- package/components/message-actions.js.map +0 -1
- package/components/message.js.map +0 -1
- package/components/number-input.js.map +0 -1
- package/components/pagination.js.map +0 -1
- package/components/popover.js.map +0 -1
- package/components/progress.js.map +0 -1
- package/components/prompt-bar.js.map +0 -1
- package/components/radio.js.map +0 -1
- package/components/search-bar.js.map +0 -1
- package/components/segmented-control.js.map +0 -1
- package/components/select.js.map +0 -1
- package/components/sheet.js.map +0 -1
- package/components/sidebar.js.map +0 -1
- package/components/skeleton.js.map +0 -1
- package/components/slider.js.map +0 -1
- package/components/sliding-indicator.js.map +0 -1
- package/components/streaming-text.js.map +0 -1
- package/components/switch.js.map +0 -1
- package/components/table.js.map +0 -1
- package/components/tabs.js.map +0 -1
- package/components/textarea.js.map +0 -1
- package/components/thinking.js.map +0 -1
- package/components/toast.js.map +0 -1
- package/components/toggle.js.map +0 -1
- package/components/tooltip.js.map +0 -1
- package/index.js.map +0 -1
- package/lib/utils.js.map +0 -1
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { Button } from './chunk-
|
|
2
|
-
import { cn } from './chunk-
|
|
1
|
+
import { Button } from './chunk-6DWLTGRQ.js';
|
|
2
|
+
import { cn } from './chunk-EHEXE2UV.js';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { Check, Copy } from 'iconoir-react';
|
|
5
5
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
6
6
|
|
|
7
7
|
var tokenClass = {
|
|
8
|
-
plain: "text-[var(--code-plain,#18181b)] dark:text-[var(--code-plain,#fafafa)]",
|
|
9
|
-
keyword: "text-[var(--code-keyword,#dc2626)] dark:text-[var(--code-keyword,#f87171)]",
|
|
10
|
-
string: "text-[var(--code-string,#0369a1)] dark:text-[var(--code-string,#7dd3fc)]",
|
|
11
|
-
function: "text-[var(--code-function,#8b5cf6)] dark:text-[var(--code-function,#a78bfa)]",
|
|
12
|
-
parameter: "text-[var(--code-parameter,#b45309)] dark:text-[var(--code-parameter,#fcd34d)]",
|
|
13
|
-
variable: "text-[var(--code-variable,#0284c7)] dark:text-[var(--code-variable,#38bdf8)]",
|
|
8
|
+
plain: "sa:text-[var(--code-plain,#18181b)] sa:dark:text-[var(--code-plain,#fafafa)]",
|
|
9
|
+
keyword: "sa:text-[var(--code-keyword,#dc2626)] sa:dark:text-[var(--code-keyword,#f87171)]",
|
|
10
|
+
string: "sa:text-[var(--code-string,#0369a1)] sa:dark:text-[var(--code-string,#7dd3fc)]",
|
|
11
|
+
function: "sa:text-[var(--code-function,#8b5cf6)] sa:dark:text-[var(--code-function,#a78bfa)]",
|
|
12
|
+
parameter: "sa:text-[var(--code-parameter,#b45309)] sa:dark:text-[var(--code-parameter,#fcd34d)]",
|
|
13
|
+
variable: "sa:text-[var(--code-variable,#0284c7)] sa:dark:text-[var(--code-variable,#38bdf8)]",
|
|
14
14
|
// No comment colour in Figma: comments take the line-number grey.
|
|
15
|
-
comment: "text-[var(--code-line-number,#a1a1aa)] dark:text-[var(--code-line-number,#71717a)]"
|
|
15
|
+
comment: "sa:text-[var(--code-line-number,#a1a1aa)] sa:dark:text-[var(--code-line-number,#71717a)]"
|
|
16
16
|
};
|
|
17
|
-
var lineNumberClass = "text-[var(--code-line-number,#a1a1aa)] dark:text-[var(--code-line-number,#71717a)]";
|
|
18
|
-
var highlightClass = "bg-[var(--code-line-highlight,rgba(0,0,0,0.05))] dark:bg-[var(--code-line-highlight,rgba(255,255,255,0.06))]";
|
|
17
|
+
var lineNumberClass = "sa:text-[var(--code-line-number,#a1a1aa)] sa:dark:text-[var(--code-line-number,#71717a)]";
|
|
18
|
+
var highlightClass = "sa:bg-[var(--code-line-highlight,rgba(0,0,0,0.05))] sa:dark:bg-[var(--code-line-highlight,rgba(255,255,255,0.06))]";
|
|
19
19
|
var KEYWORDS = /* @__PURE__ */ new Set([
|
|
20
20
|
"import",
|
|
21
21
|
"from",
|
|
@@ -124,7 +124,7 @@ function parse(code, view, highlightLines) {
|
|
|
124
124
|
});
|
|
125
125
|
}
|
|
126
126
|
function FileCodeIcon() {
|
|
127
|
-
return /* @__PURE__ */ jsx("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": true, className: "shrink-0 text-text-muted", children: /* @__PURE__ */ jsx(
|
|
127
|
+
return /* @__PURE__ */ jsx("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": true, className: "sa:shrink-0 sa:text-text-muted", children: /* @__PURE__ */ jsx(
|
|
128
128
|
"path",
|
|
129
129
|
{
|
|
130
130
|
d: "M13.333 5.333L9.333 1.333H4C3.264 1.333 2.667 1.93 2.667 2.667V13.333C2.667 14.07 3.264 14.667 4 14.667H12C12.736 14.667 13.333 14.07 13.333 13.333V5.333ZM9.333 1.333V5.333H13.333M6.667 8.333L5.333 9.667L6.667 11M9.333 8.333L10.667 9.667L9.333 11",
|
|
@@ -170,25 +170,25 @@ function CodeBlock({
|
|
|
170
170
|
"data-slot": "code-block",
|
|
171
171
|
"data-view": view,
|
|
172
172
|
className: cn(
|
|
173
|
-
"flex flex-col overflow-hidden rounded-2xl border border-border-default bg-bg-card pb-3",
|
|
173
|
+
"sa:flex sa:flex-col sa:overflow-hidden sa:rounded-2xl sa:border sa:border-border-default sa:bg-bg-card sa:pb-3",
|
|
174
174
|
className
|
|
175
175
|
),
|
|
176
176
|
...props,
|
|
177
177
|
children: [
|
|
178
|
-
showHeader && /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 pt-2 pr-2 pb-1 pl-4", children: [
|
|
178
|
+
showHeader && /* @__PURE__ */ jsxs("div", { className: "sa:flex sa:items-center sa:gap-2 sa:pt-2 sa:pr-2 sa:pb-1 sa:pl-4", children: [
|
|
179
179
|
/* @__PURE__ */ jsx(FileCodeIcon, {}),
|
|
180
|
-
/* @__PURE__ */ jsx("span", { className: "min-w-0 flex-1 truncate text-sm leading-[18px] font-medium text-text-default", children: filename }),
|
|
181
|
-
diff && /* @__PURE__ */ jsxs("span", { className: "flex shrink-0 items-center gap-1.5 font-mono text-sm leading-(--text-sm--line-height) tracking-normal", children: [
|
|
182
|
-
/* @__PURE__ */ jsxs("span", { className: "text-status-green-fg", children: [
|
|
180
|
+
/* @__PURE__ */ jsx("span", { className: "sa:min-w-0 sa:flex-1 sa:truncate sa:text-sm sa:leading-[18px] sa:font-medium sa:text-text-default", children: filename }),
|
|
181
|
+
diff && /* @__PURE__ */ jsxs("span", { className: "sa:flex sa:shrink-0 sa:items-center sa:gap-1.5 sa:font-mono sa:text-sm sa:leading-(--sa-text-sm--line-height) sa:tracking-normal", children: [
|
|
182
|
+
/* @__PURE__ */ jsxs("span", { className: "sa:text-status-green-fg", children: [
|
|
183
183
|
"+",
|
|
184
184
|
added
|
|
185
185
|
] }),
|
|
186
|
-
/* @__PURE__ */ jsxs("span", { className: "text-status-red-fg", children: [
|
|
186
|
+
/* @__PURE__ */ jsxs("span", { className: "sa:text-status-red-fg", children: [
|
|
187
187
|
"\u2212",
|
|
188
188
|
removed
|
|
189
189
|
] })
|
|
190
190
|
] }),
|
|
191
|
-
showActions && /* @__PURE__ */ jsxs(Button, { variant: "tertiary", size: "xs", onClick: copy, className: "text-text-default", children: [
|
|
191
|
+
showActions && /* @__PURE__ */ jsxs(Button, { variant: "tertiary", size: "xs", onClick: copy, className: "sa:text-text-default", children: [
|
|
192
192
|
copied ? /* @__PURE__ */ jsx(Check, {}) : /* @__PURE__ */ jsx(Copy, {}),
|
|
193
193
|
/* @__PURE__ */ jsx("span", { "aria-live": "polite", children: copied ? "Copied" : "Copy" })
|
|
194
194
|
] })
|
|
@@ -200,22 +200,22 @@ function CodeBlock({
|
|
|
200
200
|
role: "region",
|
|
201
201
|
"aria-label": filename ? `${filename} code` : "Code",
|
|
202
202
|
className: cn(
|
|
203
|
-
"outline-none focus-visible:[box-shadow:inset_0_0_0_2px_var(--action-focus-ring)]",
|
|
204
|
-
"overflow-x-auto font-mono text-sm leading-(--text-sm--line-height) font-normal tracking-normal",
|
|
203
|
+
"sa:outline-none sa:focus-visible:[box-shadow:inset_0_0_0_2px_var(--action-focus-ring)]",
|
|
204
|
+
"sa:overflow-x-auto sa:font-mono sa:text-sm sa:leading-(--sa-text-sm--line-height) sa:font-normal sa:tracking-normal",
|
|
205
205
|
// Without the header the code sits in the middle: 12px above, as below.
|
|
206
|
-
showHeader ? "pt-1" : "pt-3",
|
|
206
|
+
showHeader ? "sa:pt-1" : "sa:pt-3",
|
|
207
207
|
tokenClass.plain
|
|
208
208
|
),
|
|
209
|
-
children: /* @__PURE__ */ jsx("code", { className: "block w-max min-w-full", children: lines.map((line, i) => /* @__PURE__ */ jsxs(
|
|
209
|
+
children: /* @__PURE__ */ jsx("code", { className: "sa:block sa:w-max sa:min-w-full", children: lines.map((line, i) => /* @__PURE__ */ jsxs(
|
|
210
210
|
"span",
|
|
211
211
|
{
|
|
212
212
|
"data-line": line.kind,
|
|
213
213
|
className: cn(
|
|
214
|
-
"flex h-6 items-center px-4",
|
|
215
|
-
diff ? "gap-2" : "gap-4",
|
|
214
|
+
"sa:flex sa:h-6 sa:items-center sa:px-4",
|
|
215
|
+
diff ? "sa:gap-2" : "sa:gap-4",
|
|
216
216
|
line.kind === "highlighted" && highlightClass,
|
|
217
|
-
line.kind === "added" && "bg-status-green-bg",
|
|
218
|
-
line.kind === "removed" && "bg-status-red-bg"
|
|
217
|
+
line.kind === "added" && "sa:bg-status-green-bg",
|
|
218
|
+
line.kind === "removed" && "sa:bg-status-red-bg"
|
|
219
219
|
),
|
|
220
220
|
children: [
|
|
221
221
|
/* @__PURE__ */ jsx(
|
|
@@ -223,8 +223,8 @@ function CodeBlock({
|
|
|
223
223
|
{
|
|
224
224
|
"aria-hidden": true,
|
|
225
225
|
className: cn(
|
|
226
|
-
"w-5 shrink-0 text-right select-none",
|
|
227
|
-
line.kind === "added" ? "text-status-green-fg" : line.kind === "removed" ? "text-status-red-fg" : lineNumberClass
|
|
226
|
+
"sa:w-5 sa:shrink-0 sa:text-right sa:select-none",
|
|
227
|
+
line.kind === "added" ? "sa:text-status-green-fg" : line.kind === "removed" ? "sa:text-status-red-fg" : lineNumberClass
|
|
228
228
|
),
|
|
229
229
|
children: line.number
|
|
230
230
|
}
|
|
@@ -233,17 +233,17 @@ function CodeBlock({
|
|
|
233
233
|
"span",
|
|
234
234
|
{
|
|
235
235
|
className: cn(
|
|
236
|
-
"w-2 shrink-0 text-center select-none",
|
|
237
|
-
line.kind === "added" ? "text-status-green-fg" : line.kind === "removed" ? "text-status-red-fg" : lineNumberClass
|
|
236
|
+
"sa:w-2 sa:shrink-0 sa:text-center sa:select-none",
|
|
237
|
+
line.kind === "added" ? "sa:text-status-green-fg" : line.kind === "removed" ? "sa:text-status-red-fg" : lineNumberClass
|
|
238
238
|
),
|
|
239
239
|
children: [
|
|
240
240
|
line.kind === "added" ? "+" : line.kind === "removed" ? "\u2212" : " ",
|
|
241
|
-
line.kind === "added" && /* @__PURE__ */ jsx("span", { className: "sr-only", children: " added" }),
|
|
242
|
-
line.kind === "removed" && /* @__PURE__ */ jsx("span", { className: "sr-only", children: " removed" })
|
|
241
|
+
line.kind === "added" && /* @__PURE__ */ jsx("span", { className: "sa:sr-only", children: " added" }),
|
|
242
|
+
line.kind === "removed" && /* @__PURE__ */ jsx("span", { className: "sa:sr-only", children: " removed" })
|
|
243
243
|
]
|
|
244
244
|
}
|
|
245
245
|
),
|
|
246
|
-
/* @__PURE__ */ jsx("span", { className: "whitespace-pre", children: line.text === "" ? "\u200B" : highlight ? tokenize(line.text).map((t, j) => /* @__PURE__ */ jsx("span", { className: t.kind === "plain" ? void 0 : tokenClass[t.kind], children: t.text }, j)) : line.text })
|
|
246
|
+
/* @__PURE__ */ jsx("span", { className: "sa:whitespace-pre", children: line.text === "" ? "\u200B" : highlight ? tokenize(line.text).map((t, j) => /* @__PURE__ */ jsx("span", { className: t.kind === "plain" ? void 0 : tokenClass[t.kind], children: t.text }, j)) : line.text })
|
|
247
247
|
]
|
|
248
248
|
},
|
|
249
249
|
i
|
|
@@ -256,5 +256,3 @@ function CodeBlock({
|
|
|
256
256
|
}
|
|
257
257
|
|
|
258
258
|
export { CodeBlock };
|
|
259
|
-
//# sourceMappingURL=chunk-A5XEM3GF.js.map
|
|
260
|
-
//# sourceMappingURL=chunk-A5XEM3GF.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ChartCard, defaultFormat, ChartTooltip, ChartLegendRow } from './chunk-
|
|
2
|
-
import { cn } from './chunk-
|
|
1
|
+
import { ChartCard, defaultFormat, ChartTooltip, ChartLegendRow } from './chunk-LI5VYDLN.js';
|
|
2
|
+
import { cn } from './chunk-EHEXE2UV.js';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
5
5
|
|
|
@@ -32,12 +32,12 @@ function BarCard({
|
|
|
32
32
|
const ticks = [4, 3, 2, 1, 0].map((i) => max / 4 * i);
|
|
33
33
|
const sum = data.reduce((n, d) => n + d.value, 0);
|
|
34
34
|
return /* @__PURE__ */ jsxs(ChartCard, { total: total ?? defaultFormat(sum), ...props, children: [
|
|
35
|
-
/* @__PURE__ */ jsx("div", { className: "pt-2", children: /* @__PURE__ */ jsxs("div", { className: "relative flex h-[206px] items-end gap-2 pl-8", onPointerLeave: () => setHovered(null), children: [
|
|
35
|
+
/* @__PURE__ */ jsx("div", { className: "sa:pt-2", children: /* @__PURE__ */ jsxs("div", { className: "sa:relative sa:flex sa:h-[206px] sa:items-end sa:gap-2 sa:pl-8", onPointerLeave: () => setHovered(null), children: [
|
|
36
36
|
ticks.slice(0, 4).map((_, i) => /* @__PURE__ */ jsx(
|
|
37
37
|
"span",
|
|
38
38
|
{
|
|
39
39
|
"aria-hidden": true,
|
|
40
|
-
className: "absolute right-0 left-8 h-px border-t border-dashed border-border-subtle",
|
|
40
|
+
className: "sa:absolute sa:right-0 sa:left-8 sa:h-px sa:border-t sa:border-dashed sa:border-border-subtle",
|
|
41
41
|
style: { top: TRACK / 4 * i }
|
|
42
42
|
},
|
|
43
43
|
i
|
|
@@ -47,7 +47,7 @@ function BarCard({
|
|
|
47
47
|
{
|
|
48
48
|
"aria-hidden": true,
|
|
49
49
|
className: cn(
|
|
50
|
-
"absolute left-6 w-6
|
|
50
|
+
"sa:absolute sa:left-6 sa:w-6 sa:-translate-x-full sa:text-right sa:text-xs sa:leading-[18px] sa:text-text-muted",
|
|
51
51
|
regrow && "satin-bar-fade"
|
|
52
52
|
),
|
|
53
53
|
style: { top: TRACK / 4 * i - 9 },
|
|
@@ -55,7 +55,7 @@ function BarCard({
|
|
|
55
55
|
},
|
|
56
56
|
`${redraw.n}-${i}`
|
|
57
57
|
)),
|
|
58
|
-
/* @__PURE__ */ jsx("ul", { className: "contents", "aria-label": props.title, children: data.map((d, i) => {
|
|
58
|
+
/* @__PURE__ */ jsx("ul", { className: "sa:contents", "aria-label": props.title, children: data.map((d, i) => {
|
|
59
59
|
const isActive = active === i;
|
|
60
60
|
const dimmed = active !== null && !isActive;
|
|
61
61
|
const height = d.value / max * TRACK;
|
|
@@ -67,9 +67,9 @@ function BarCard({
|
|
|
67
67
|
onPointerEnter: () => setHovered(i),
|
|
68
68
|
onFocus: () => setHovered(i),
|
|
69
69
|
onBlur: () => setHovered(null),
|
|
70
|
-
className: "relative flex min-w-0 flex-1 flex-col items-center gap-1.5 rounded-md focus-visible:outline-none",
|
|
70
|
+
className: "sa:relative sa:flex sa:min-w-0 sa:flex-1 sa:flex-col sa:items-center sa:gap-1.5 sa:rounded-md sa:focus-visible:outline-none",
|
|
71
71
|
children: [
|
|
72
|
-
/* @__PURE__ */ jsxs("div", { className: "relative flex w-full flex-col items-center justify-end gap-1.5", style: { height: TRACK }, children: [
|
|
72
|
+
/* @__PURE__ */ jsxs("div", { className: "sa:relative sa:flex sa:w-full sa:flex-col sa:items-center sa:justify-end sa:gap-1.5", style: { height: TRACK }, children: [
|
|
73
73
|
isActive && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
74
74
|
/* @__PURE__ */ jsx(
|
|
75
75
|
ChartTooltip,
|
|
@@ -79,17 +79,17 @@ function BarCard({
|
|
|
79
79
|
value: `${formatValue(d.value)}${unit ? ` ${unit}` : ""}`
|
|
80
80
|
}
|
|
81
81
|
),
|
|
82
|
-
/* @__PURE__ */ jsx("span", { ref: setAnchor, className: "text-sm leading-(--text-sm--line-height) font-medium text-text-default", children: formatValue(d.value) })
|
|
82
|
+
/* @__PURE__ */ jsx("span", { ref: setAnchor, className: "sa:text-sm sa:leading-(--sa-text-sm--line-height) sa:font-medium sa:text-text-default", children: formatValue(d.value) })
|
|
83
83
|
] }),
|
|
84
84
|
/* @__PURE__ */ jsx(
|
|
85
85
|
"span",
|
|
86
86
|
{
|
|
87
87
|
"aria-hidden": true,
|
|
88
88
|
className: cn(
|
|
89
|
-
"w-full rounded-md transition-[background-color,outline-color] duration-(--duration-fast) ease-(--ease-out)",
|
|
89
|
+
"sa:w-full sa:rounded-md sa:transition-[background-color,outline-color] sa:duration-(--sa-duration-fast) sa:ease-(--sa-ease-out)",
|
|
90
90
|
// Dimmed bars stay a tint of chart/3 on the card, so the brand colour never reaches them.
|
|
91
|
-
dimmed ? "bg-[color-mix(in_oklab,var(--chart-3)_30%,var(--bg-card))]" : "bg-chart-3",
|
|
92
|
-
isActive && "outline outline-offset-2 outline-chart-3",
|
|
91
|
+
dimmed ? "sa:bg-[color-mix(in_oklab,var(--sa-chart-3)_30%,var(--bg-card))]" : "sa:bg-chart-3",
|
|
92
|
+
isActive && "sa:outline sa:outline-offset-2 sa:outline-chart-3",
|
|
93
93
|
regrow && "satin-bar-regrow"
|
|
94
94
|
),
|
|
95
95
|
style: { height }
|
|
@@ -100,8 +100,8 @@ function BarCard({
|
|
|
100
100
|
"span",
|
|
101
101
|
{
|
|
102
102
|
className: cn(
|
|
103
|
-
"text-sm leading-(--text-sm--line-height) font-medium whitespace-nowrap",
|
|
104
|
-
isActive ? "text-text-default" : "text-text-muted",
|
|
103
|
+
"sa:text-sm sa:leading-(--sa-text-sm--line-height) sa:font-medium sa:whitespace-nowrap",
|
|
104
|
+
isActive ? "sa:text-text-default" : "sa:text-text-muted",
|
|
105
105
|
regrow && "satin-bar-fade"
|
|
106
106
|
),
|
|
107
107
|
children: d.label
|
|
@@ -116,7 +116,7 @@ function BarCard({
|
|
|
116
116
|
legend && /* @__PURE__ */ jsx(
|
|
117
117
|
ChartLegendRow,
|
|
118
118
|
{
|
|
119
|
-
color: "var(--chart-3)",
|
|
119
|
+
color: "var(--sa-chart-3)",
|
|
120
120
|
label: legend.label,
|
|
121
121
|
value: legend.value ?? formatValue(sum),
|
|
122
122
|
note: legend.note
|
|
@@ -126,5 +126,3 @@ function BarCard({
|
|
|
126
126
|
}
|
|
127
127
|
|
|
128
128
|
export { BarCard, niceMax };
|
|
129
|
-
//# sourceMappingURL=chunk-DO3TBNSC.js.map
|
|
130
|
-
//# sourceMappingURL=chunk-DO3TBNSC.js.map
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { useSatinLabels } from './chunk-NTSU44FY.js';
|
|
2
|
+
import { cn } from './chunk-EHEXE2UV.js';
|
|
3
|
+
import 'react';
|
|
4
|
+
import { Slot } from 'radix-ui';
|
|
5
|
+
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
6
|
+
|
|
7
|
+
var variantClass = {
|
|
8
|
+
default: "sa:text-text-default sa:decoration-border-strong sa:hover:decoration-current",
|
|
9
|
+
brand: "sa:text-status-brand-fg sa:decoration-status-brand-fg/40 sa:hover:decoration-current",
|
|
10
|
+
muted: "sa:text-text-muted sa:decoration-current sa:hover:text-text-default"
|
|
11
|
+
};
|
|
12
|
+
function Link({
|
|
13
|
+
variant = "default",
|
|
14
|
+
underline,
|
|
15
|
+
external,
|
|
16
|
+
asChild = false,
|
|
17
|
+
target,
|
|
18
|
+
rel,
|
|
19
|
+
className,
|
|
20
|
+
children,
|
|
21
|
+
...props
|
|
22
|
+
}) {
|
|
23
|
+
const labels = useSatinLabels();
|
|
24
|
+
const line = underline ?? (variant === "muted" ? "hover" : "always");
|
|
25
|
+
const isExternal = external ?? target === "_blank";
|
|
26
|
+
const Comp = asChild ? Slot.Root : "a";
|
|
27
|
+
return /* @__PURE__ */ jsx(
|
|
28
|
+
Comp,
|
|
29
|
+
{
|
|
30
|
+
"data-slot": "link",
|
|
31
|
+
"data-variant": variant,
|
|
32
|
+
target: target ?? (isExternal && !asChild ? "_blank" : void 0),
|
|
33
|
+
rel: rel ?? (isExternal ? "noopener noreferrer" : void 0),
|
|
34
|
+
className: cn(
|
|
35
|
+
"sa:rounded-xs sa:font-medium sa:underline-offset-[3px] sa:outline-none sa:[text-decoration-thickness:1px]",
|
|
36
|
+
"sa:transition-[color,text-decoration-color,box-shadow] sa:duration-(--sa-duration-fast) sa:ease-(--sa-ease-out)",
|
|
37
|
+
"sa:focus-visible:[box-shadow:0_0_0_2px_var(--action-focus-ring)]",
|
|
38
|
+
line === "always" && "sa:underline",
|
|
39
|
+
line === "hover" && "sa:no-underline sa:hover:underline",
|
|
40
|
+
line === "none" && "sa:no-underline",
|
|
41
|
+
variantClass[variant],
|
|
42
|
+
className
|
|
43
|
+
),
|
|
44
|
+
...props,
|
|
45
|
+
children: asChild ? children : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
46
|
+
children,
|
|
47
|
+
isExternal && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
48
|
+
/* @__PURE__ */ jsx("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", "aria-hidden": true, className: "sa:ml-0.5 sa:inline-block sa:align-[-1px]", children: /* @__PURE__ */ jsx("path", { d: "M4 3H9V8M9 3L3 9", stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", style: { strokeWidth: 1.1 } }) }),
|
|
49
|
+
/* @__PURE__ */ jsx("span", { className: "sa:sr-only", children: ` ${labels.opensInNewTab}` })
|
|
50
|
+
] })
|
|
51
|
+
] })
|
|
52
|
+
}
|
|
53
|
+
);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export { Link };
|