@midas-ds/components 10.4.0 → 11.0.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/{AccordionItem-BqsgiVWV.js → AccordionItem-BtDoammf.js} +7 -7
- package/{AccordionItem-BcsoC78F.cjs → AccordionItem-D2QYNgZS.cjs} +1 -1
- package/{BadgeContainer-DM8TdyMT.js → BadgeContainer-CKBIZWsc.js} +13 -13
- package/BadgeContainer-DWVHS5dn.cjs +1 -0
- package/{Breadcrumbs-D7eoibWk.js → Breadcrumbs-BBzSV4SK.js} +4 -4
- package/{Breadcrumbs-CfW5IuyE.cjs → Breadcrumbs-CFUryOhf.cjs} +1 -1
- package/{Button-BZUo7vsZ.js → Button-BjMaGya2.js} +2 -2
- package/{Button-CFYdzG0H.js → Button-CepQFEit.js} +4 -4
- package/{Button-BXY5ZhqI.cjs → Button-Dq6ugqxT.cjs} +1 -1
- package/Button.module-D-mPLRxe.js +14 -0
- package/Button.module-goCEz5qs.cjs +1 -0
- package/CHANGELOG.md +36 -0
- package/{Card-BaWSgtSF.js → Card-BRs1FKX5.js} +4 -4
- package/{Card-Cc1TNPcQ.cjs → Card-cdL5669N.cjs} +1 -1
- package/{CharacterCounter-cLhqPZlk.js → CharacterCounter-DpBDwvLw.js} +2 -2
- package/{Checkbox-LuUwTZ3W.js → Checkbox-EB_SCBEo.js} +3 -3
- package/{CheckboxGroup-CUA8_xSx.js → CheckboxGroup-CC9QGMuE.js} +7 -8
- package/CheckboxGroup-DhQX10rP.cjs +1 -0
- package/{Collection--62xKPm9.js → Collection-D2jVTmDW.js} +1 -1
- package/{ColorSchemeSwitch-Cwono7Ap.js → ColorSchemeSwitch-Cnyb9EKC.js} +42 -41
- package/ColorSchemeSwitch-owUryjYz.cjs +16 -0
- package/ComboBox-CiCB2e4W.cjs +1 -0
- package/{ComboBox-HLIAbb2q.js → ComboBox-Dnk8JMQ6.js} +65 -66
- package/{DateField-CnLEi7uX.js → DateField-BAS2v9aI.js} +4 -4
- package/{DateField-B3VjOSde.cjs → DateField-DleDM0Sy.cjs} +1 -1
- package/{DateInputDivider-Bi5N-C0c.js → DateInputDivider-B3oE1_tB.js} +39 -38
- package/DateInputDivider-ToFY-yjB.cjs +1 -0
- package/{DateRangePicker-CFOoGvut.js → DateRangePicker-Blej-jD0.js} +71 -72
- package/DateRangePicker-CYXWnCTq.cjs +6 -0
- package/{Dialog-pSSy1zwf.cjs → Dialog-B3R3WtL5.cjs} +1 -1
- package/{Dialog-SqciohRY.js → Dialog-BkUw6PlA.js} +7 -7
- package/{Dialog-CtVrVuMr.js → Dialog-DKHo0W9B.js} +443 -468
- package/Dialog-DtHk3eXI.cjs +1 -0
- package/{DragAndDrop-BoEd260f.cjs → DragAndDrop-CSg60YQE.cjs} +1 -1
- package/{DragAndDrop-DkSTL28C.js → DragAndDrop-DOXLfJaA.js} +1 -1
- package/Dropdown-CYakzdJg.cjs +6 -0
- package/{Dropdown-CkBp70BH.js → Dropdown-D6WCi_Ll.js} +19 -19
- package/FieldError-Bv3Q6ZP-.cjs +1 -0
- package/FieldError-CDCvUjK5.js +46 -0
- package/{FileUpload-B4rv-wke.js → FileUpload-BokzdXVc.js} +448 -562
- package/{FileUpload-BwMhyLjG.cjs → FileUpload-Bz9md5zc.cjs} +2 -2
- package/{FocusScope-D_hwN_TJ.js → FocusScope-BCsrRPqD.js} +1 -1
- package/{Group-CpkUzEAs.js → Group-B0vQfHDy.js} +1 -1
- package/{Heading-NxtGri2i.js → Heading-D2y_kiC0.js} +1 -1
- package/{InfoBanner-CVry6Y8i.cjs → InfoBanner-CzwbOdRG.cjs} +1 -1
- package/{InfoBanner-CBUoad7A.js → InfoBanner-D05poAe3.js} +5 -5
- package/{Input-LnjmFI1x.js → Input-n-Z20KbW.js} +1 -1
- package/{Label-TVxwGZ-O.js → Label-JLgFEbP9.js} +5 -5
- package/{Label-CNmTN1YY.cjs → Label-VO6CAFux.cjs} +1 -1
- package/Layout-BwLxIwtY.cjs +16 -0
- package/{Layout-amz9BESl.js → Layout-CcADAhds.js} +98 -98
- package/{Link-Bn8V3ZI0.js → Link-CibH8uRY.js} +3 -3
- package/Link-ESjrl63P.cjs +6 -0
- package/Link-ovwNVMfg.js +60 -0
- package/LinkButton-B6AWNiRn.cjs +6 -0
- package/LinkButton-BkZULm2a.js +69 -0
- package/{ListBox-BCz5-23H.cjs → ListBox-B0E1hdEt.cjs} +1 -1
- package/{ListBox-C-isJIHL.js → ListBox-CsxDGpCA.js} +11 -11
- package/{ListBoxButton-DNm3gvcT.cjs → ListBoxButton-BsuHFd_O.cjs} +1 -1
- package/{ListBoxButton-C_krklY0.js → ListBoxButton-DawRfuny.js} +1 -1
- package/{ListBoxSection-CfQZoURJ.cjs → ListBoxSection-C-Rz358T.cjs} +1 -1
- package/{ListBoxSection-BVR2xtOH.js → ListBoxSection-Cc2cx0_S.js} +6 -6
- package/{ListKeyboardDelegate-CY6t6y1t.js → ListKeyboardDelegate-C-sPNj0f.js} +2 -2
- package/{ListKeyboardDelegate-CPsZ7D83.cjs → ListKeyboardDelegate-ZKBk2IId.cjs} +1 -1
- package/{OverlayArrow-CfhSYL46.js → OverlayArrow-DB_aVTVM.js} +1 -1
- package/Popover--r4Zr4mO.cjs +1 -0
- package/{Popover-C8VY1YKi.js → Popover-DypW9ift.js} +13 -13
- package/PressResponder-4jE_HLu3.cjs +1 -0
- package/PressResponder-C3APAKsz.js +34 -0
- package/{ProgressBar-BNCjpcv8.js → ProgressBar-CFgcqHTR.js} +2 -2
- package/{ProgressBar-CcbxcWdT.cjs → ProgressBar-CJFNiudl.cjs} +1 -1
- package/Radio-CMH6pTWD.cjs +1 -0
- package/{Radio-CZYibh9r.js → Radio-DUBSD0kQ.js} +19 -20
- package/{RangeCalendar-B16b6tJD.js → RangeCalendar-BCruEq9d.js} +106 -109
- package/RangeCalendar-BY82hPRu.cjs +11 -0
- package/SearchField-QFyuaT-K.cjs +6 -0
- package/{SearchField-giwECmXS.js → SearchField-nwlyszwt.js} +47 -47
- package/Select-C5i-rIDh.cjs +1 -0
- package/{Select-mwaAv20X.js → Select-DKME5lZp.js} +107 -108
- package/SelectionManager-BJjqIWtf.cjs +1 -0
- package/{SelectionManager-zsWy3vsd.js → SelectionManager-BubxiIKu.js} +25 -24
- package/{Separator-Dn5LYN5I.js → Separator-CEZ5y7tZ.js} +4 -4
- package/{Separator-CxF-3jhR.cjs → Separator-DPLEx950.cjs} +1 -1
- package/Spinner-VSyPhiJ9.js +51 -0
- package/Spinner-vof0Y9Hh.cjs +6 -0
- package/{TabList-7VtCiXxX.cjs → TabList-BkSWzbDG.cjs} +1 -1
- package/{TabList-CthsM5h6.js → TabList-QApx8qRC.js} +90 -90
- package/{Table-BcQPvJT3.js → Table-B5Aine4F.js} +55 -54
- package/Table-DGYC-sDq.cjs +16 -0
- package/{Tag-Bs8T2Ei7.js → Tag-Byva_Xuy.js} +136 -135
- package/Tag-bYq-wf5D.cjs +1 -0
- package/{Text-DlKqpvSa.js → Text-BPcfhYQ9.js} +1 -1
- package/{Text-92cPh38G.js → Text-DcZqSUN9.js} +3 -3
- package/{TextArea-DBNAVWqL.js → TextArea-BhmdgD1w.js} +8 -8
- package/{TextArea-XJDfeXRs.cjs → TextArea-CY_tzBAJ.cjs} +1 -1
- package/{TextField-BdK9KEQ5.cjs → TextField-BAX93sq7.cjs} +1 -1
- package/{TextField-ByDJkig9.js → TextField-Dma22dnD.js} +19 -19
- package/{Toast-DPPvPhrF.js → Toast-CWt_mNIg.js} +5 -5
- package/{Toast-l1bKo2oA.cjs → Toast-DdmSvNaO.cjs} +1 -1
- package/{ToggleButtonGroup-DH8IgR4G.cjs → ToggleButtonGroup-DZ_wo0qx.cjs} +1 -1
- package/{ToggleButtonGroup-HOWNWtQZ.js → ToggleButtonGroup-HjvaTYD4.js} +4 -4
- package/{Tooltip-5mLWn_wO.js → Tooltip-DjNc93tV.js} +3 -3
- package/accordion/index.cjs +1 -1
- package/accordion/index.js +1 -1
- package/arrow-right-BGd86zzR.cjs +6 -0
- package/{arrow-right-Dg8sttFO.js → arrow-right-uemUGIg8.js} +5 -5
- package/assets/BadgeContainer.css +1 -1
- package/assets/Button.css +1 -1
- package/assets/FileUpload.css +1 -1
- package/assets/LinkButton.css +1 -1
- package/assets/Popover.css +1 -1
- package/assets/TabList.css +1 -1
- package/assets/Tag.css +1 -1
- package/badge/index.cjs +1 -1
- package/badge/index.js +1 -1
- package/breadcrumbs/index.cjs +1 -1
- package/breadcrumbs/index.js +1 -1
- package/button/index.cjs +1 -1
- package/button/index.js +1 -1
- package/calendar/index.cjs +1 -1
- package/calendar/index.js +1 -1
- package/card/Card.d.ts +1 -1
- package/card/index.cjs +1 -1
- package/card/index.js +1 -1
- package/character-counter/index.js +1 -1
- package/check-B0aKTFe5.cjs +6 -0
- package/check-B5h1DvDs.js +11 -0
- package/checkbox/index.cjs +1 -1
- package/checkbox/index.js +2 -2
- package/chevron-down-5hFlg_lR.cjs +6 -0
- package/chevron-down-DmZMdOiC.js +11 -0
- package/{circle-check-B9HYcH7Z.js → circle-check-BErh6TKu.js} +9 -9
- package/circle-check-OVUGxwp9.cjs +11 -0
- package/color-scheme-switch/index.cjs +1 -1
- package/color-scheme-switch/index.js +1 -1
- package/combobox/index.cjs +1 -1
- package/combobox/index.js +1 -1
- package/createLucideIcon-CTVXwe6i.cjs +21 -0
- package/createLucideIcon-XRdN60yz.js +94 -0
- package/date-field/index.cjs +1 -1
- package/date-field/index.js +2 -2
- package/date-picker/index.cjs +1 -1
- package/date-picker/index.js +1 -1
- package/dropdown/index.cjs +1 -1
- package/dropdown/index.js +1 -1
- package/field-error/index.cjs +1 -1
- package/field-error/index.js +1 -1
- package/file-upload/FileUpload.d.ts +3 -14
- package/file-upload/index.cjs +1 -1
- package/file-upload/index.d.ts +1 -1
- package/file-upload/index.js +3 -2
- package/{getScrollParent-CsZ9ciml.cjs → getScrollParent-DuKmPmUa.cjs} +1 -1
- package/{getScrollParent-CT_L9LUr.js → getScrollParent-Ru2U2LlM.js} +1 -1
- package/heading/index.js +1 -1
- package/index.cjs +1 -1
- package/index.js +97 -96
- package/{info-BZwphdye.js → info-CPK1vbOJ.js} +5 -5
- package/info-Dj6SyPex.cjs +6 -0
- package/info-banner/index.cjs +1 -1
- package/info-banner/index.js +1 -1
- package/label/index.cjs +1 -1
- package/label/index.js +1 -1
- package/layout/index.cjs +1 -1
- package/layout/index.js +1 -1
- package/link/Link.d.ts +1 -1
- package/link/index.cjs +1 -1
- package/link/index.js +2 -2
- package/link-button/LinkButton.d.ts +1 -1
- package/link-button/index.cjs +1 -1
- package/link-button/index.js +2 -2
- package/list-box/index.cjs +1 -1
- package/list-box/index.js +2 -2
- package/modal/index.cjs +1 -1
- package/modal/index.js +2 -2
- package/package.json +1 -1
- package/popover/index.cjs +1 -1
- package/popover/index.js +1 -1
- package/progress-bar/index.cjs +1 -1
- package/progress-bar/index.js +1 -1
- package/radio/index.cjs +1 -1
- package/radio/index.js +1 -1
- package/scrollIntoView-ClEACHUk.js +57 -0
- package/scrollIntoView-DRSoJp89.cjs +1 -0
- package/search-field/index.cjs +1 -1
- package/search-field/index.js +1 -1
- package/select/index.cjs +1 -1
- package/select/index.js +1 -1
- package/spinner/index.cjs +1 -1
- package/spinner/index.js +1 -1
- package/{square-arrow-out-up-right-BkyqV2PN.js → square-arrow-out-up-right-ok0A3Ovo.js} +4 -4
- package/square-arrow-out-up-right-xCFdJTzY.cjs +6 -0
- package/table/index.cjs +1 -1
- package/table/index.js +1 -1
- package/tabs/index.cjs +1 -1
- package/tabs/index.js +1 -1
- package/tag/index.cjs +1 -1
- package/tag/index.js +1 -1
- package/text/index.js +1 -1
- package/textfield/index.cjs +1 -1
- package/textfield/index.js +1 -1
- package/theme/index.cjs +1 -1
- package/theme/index.d.ts +1 -0
- package/theme/index.js +2 -2
- package/theme/tokens.d.ts +1 -0
- package/toast/index.cjs +1 -1
- package/toast/index.js +1 -1
- package/toggle-button/index.cjs +1 -1
- package/toggle-button/index.js +1 -1
- package/{tokens-BghDnMdO.cjs → tokens-BF-dPard.cjs} +1 -1
- package/{tokens-fEwCQXDv.js → tokens-r1r3wC04.js} +4 -3
- package/tooltip/index.js +1 -1
- package/{triangle-alert-wxyxspAl.js → triangle-alert-B_qAPmWC.js} +5 -5
- package/triangle-alert-BviJNFjf.cjs +6 -0
- package/{useButton-1-Jf-oHj.js → useButton-BoIV3kDJ.js} +5 -5
- package/{useDateFormatter-BVCkxVdw.js → useDateFormatter-C7BJgoDR.js} +1 -1
- package/useDescription-CPo72trh.cjs +1 -0
- package/useDescription-DYfKjGGU.js +32 -0
- package/{useField-BEBXv5Mh.js → useField-CefQB81E.js} +1 -1
- package/{useFilter-e2oIVF_O.cjs → useFilter-BhM2yVO3.cjs} +1 -1
- package/{useFilter-CousKe2K.js → useFilter-DginflOU.js} +1 -1
- package/{useFocusable-ChPA2Jc7.js → useFocusable-BjE42axF.js} +7 -7
- package/{useHasTabbableChild-BE81d_ab.js → useHasTabbableChild-DP62kzkG.js} +1 -1
- package/{useHighlightSelectionDescription-BfR_vGOe.cjs → useHighlightSelectionDescription-DmbDkFGY.cjs} +1 -1
- package/{useHighlightSelectionDescription-D73hrkmn.js → useHighlightSelectionDescription-xr_16pKd.js} +2 -2
- package/{useListState-CebsX_1d.js → useListState-DNB7JWoj.js} +1 -1
- package/{useListState-DymkJGDF.cjs → useListState-wLau6fXo.cjs} +1 -1
- package/{usePress-DuR4pVsE.js → usePress-BW47IcyU.js} +34 -34
- package/{useSingleSelectListState-BLXvGjLI.js → useSingleSelectListState-B0OMoHd_.js} +1 -1
- package/{useSingleSelectListState-BPhlCU26.cjs → useSingleSelectListState-DlO5H9N-.cjs} +1 -1
- package/{useTextField-C-sUypsx.js → useTextField-DjxayZsV.js} +2 -2
- package/{utils-DJhAJHk_.js → utils-KLjWgdLR.js} +5 -5
- package/{x-JK7i-TQC.js → x-C2xUHAEl.js} +5 -5
- package/x-rV-nu490.cjs +6 -0
- package/BadgeContainer-I1XA3OCl.cjs +0 -1
- package/Button.module-DEQtBYe5.cjs +0 -1
- package/Button.module-tti8HGxs.js +0 -14
- package/CheckboxGroup-DmUOM0xl.cjs +0 -1
- package/ColorSchemeSwitch-DDXdSzqg.cjs +0 -16
- package/ComboBox-BBC7jhnm.cjs +0 -1
- package/DateInputDivider-3BvwXXa9.cjs +0 -1
- package/DateRangePicker-BPlZ12r8.cjs +0 -6
- package/Dialog-CSnN6baf.cjs +0 -1
- package/Dropdown-DAsVShlt.cjs +0 -6
- package/FieldError-B3YFj-an.js +0 -23
- package/FieldError-BbR-29BM.js +0 -28
- package/FieldError-MVsU-Mgw.cjs +0 -1
- package/FieldError-bRTpchvr.cjs +0 -1
- package/Layout-Dw-oCqxd.cjs +0 -16
- package/Link-D92ftFi2.cjs +0 -6
- package/Link-DegonJfl.js +0 -59
- package/LinkButton-CckYzfJ8.js +0 -69
- package/LinkButton-DKZ4z6zu.cjs +0 -6
- package/Popover-CnAsw3wI.cjs +0 -1
- package/Radio-B2zfEFdq.cjs +0 -1
- package/RangeCalendar-C1LFeOVk.cjs +0 -11
- package/SearchField-CML0kjtn.cjs +0 -6
- package/Select-DKey6CeS.cjs +0 -1
- package/SelectionManager-D0jYUYcy.cjs +0 -1
- package/Spinner-CbJ6YAz-.js +0 -53
- package/Spinner-yHcy8YHC.cjs +0 -6
- package/Table-DkvNp6xm.cjs +0 -16
- package/Tag-CFWZ2LQW.cjs +0 -1
- package/arrow-right-QJ2gXPKQ.cjs +0 -6
- package/check-CLF6Yxza.js +0 -11
- package/check-D_KoootC.cjs +0 -6
- package/chevron-down-Cd1bkzXT.js +0 -13
- package/chevron-down-jl83cllc.cjs +0 -6
- package/circle-check-BGo8gML8.cjs +0 -11
- package/createLucideIcon-Cg_wkoIA.cjs +0 -21
- package/createLucideIcon-DeWljiyi.js +0 -79
- package/file-upload/intl/translations.json.d.ts +0 -17
- package/info-CIEIENo6.cjs +0 -6
- package/scrollIntoView-BLnsPvFA.js +0 -87
- package/scrollIntoView-joIyo-Jt.cjs +0 -1
- package/square-arrow-out-up-right-V4Gd08uI.cjs +0 -6
- package/triangle-alert-DJW8U7jL.cjs +0 -6
- package/x-H8Zrx8-x.cjs +0 -6
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as u, jsxs as D } from "react/jsx-runtime";
|
|
2
2
|
import { c as b } from "./clsx-OuTLNxxd.js";
|
|
3
|
-
import { e as C } from "./Button-
|
|
4
|
-
import { a as h, $ as W,
|
|
3
|
+
import { e as C } from "./Button-CepQFEit.js";
|
|
4
|
+
import { a as h, $ as W, f as w, g as k, h as j } from "./utils-KLjWgdLR.js";
|
|
5
5
|
import { c as m, $ as z, a as O } from "./mergeProps-C1U1OIeJ.js";
|
|
6
6
|
import { $ as _ } from "./filterDOMProps-D6KHYVBX.js";
|
|
7
7
|
import p, { useRef as G, useCallback as $, useEffect as I, useMemo as P, forwardRef as E, createContext as x, useContext as N } from "react";
|
|
@@ -10,11 +10,11 @@ import { flushSync as H } from "react-dom";
|
|
|
10
10
|
import { $ as q } from "./useEvent-CigwyJOw.js";
|
|
11
11
|
import { $ as J } from "./SSRProvider-40TXmsUG.js";
|
|
12
12
|
import { $ as S } from "./useFocusRing-DOfBqnUN.js";
|
|
13
|
-
import { B as L } from "./Button-
|
|
14
|
-
import { H as Q } from "./Heading-
|
|
15
|
-
import { C as U } from "./chevron-down-
|
|
16
|
-
import { T as X } from "./triangle-alert-
|
|
17
|
-
import { C as Y } from "./check-
|
|
13
|
+
import { B as L } from "./Button-BjMaGya2.js";
|
|
14
|
+
import { H as Q } from "./Heading-D2y_kiC0.js";
|
|
15
|
+
import { C as U } from "./chevron-down-DmZMdOiC.js";
|
|
16
|
+
import { T as X } from "./triangle-alert-B_qAPmWC.js";
|
|
17
|
+
import { C as Y } from "./check-B5h1DvDs.js";
|
|
18
18
|
import './assets/AccordionItem.css';const Z = "_root_1t40y_4", ee = "_contained_1t40y_13", te = "_item_1t40y_22", ne = "_success_1t40y_23", ae = "_warning_1t40y_30", de = "_uncontained_1t40y_43", se = "_content_1t40y_44", ie = "_triggerButton_1t40y_52", oe = "_trigger_1t40y_52", re = "_triggerMainContent_1t40y_77", ce = "_triggerText_1t40y_81", le = "_chevronIcon_1t40y_95", fe = "_statusIcon_1t40y_101", ue = "_panel_1t40y_119", pe = "_hasBackground_1t40y_136", i = {
|
|
19
19
|
root: Z,
|
|
20
20
|
contained: ee,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";require('./assets/AccordionItem.css');const u=require("react/jsx-runtime"),g=require("./clsx-C11secjj.cjs"),E=require("./Button-DExMoP5f.cjs"),x=require("./utils-DHNZrQmj.cjs"),b=require("./mergeProps-B5KXZAI3.cjs"),h=require("./filterDOMProps-BS2lrgFA.cjs"),a=require("react"),v=require("./useControlledState-D0L6S_5r.cjs"),S=require("react-dom"),M=require("./useEvent-DPxMu-X9.cjs"),N=require("./SSRProvider-Bc-sMhsT.cjs"),y=require("./useFocusRing-B-A1OLhU.cjs"),A=require("./Button-
|
|
1
|
+
"use strict";require('./assets/AccordionItem.css');const u=require("react/jsx-runtime"),g=require("./clsx-C11secjj.cjs"),E=require("./Button-DExMoP5f.cjs"),x=require("./utils-DHNZrQmj.cjs"),b=require("./mergeProps-B5KXZAI3.cjs"),h=require("./filterDOMProps-BS2lrgFA.cjs"),a=require("react"),v=require("./useControlledState-D0L6S_5r.cjs"),S=require("react-dom"),M=require("./useEvent-DPxMu-X9.cjs"),N=require("./SSRProvider-Bc-sMhsT.cjs"),y=require("./useFocusRing-B-A1OLhU.cjs"),A=require("./Button-Dq6ugqxT.cjs"),K=require("./Heading-CKTR4sOz.cjs"),B=require("./chevron-down-5hFlg_lR.cjs"),j=require("./triangle-alert-BviJNFjf.cjs"),F=require("./check-B0aKTFe5.cjs"),T="_root_1t40y_4",k="_contained_1t40y_13",V="_item_1t40y_22",W="_success_1t40y_23",O="_warning_1t40y_30",z="_uncontained_1t40y_43",G="_content_1t40y_44",H="_triggerButton_1t40y_52",J="_trigger_1t40y_52",L="_triggerMainContent_1t40y_77",Q="_triggerText_1t40y_81",U="_chevronIcon_1t40y_95",X="_statusIcon_1t40y_101",Y="_panel_1t40y_119",Z="_hasBackground_1t40y_136",r={root:T,contained:k,item:V,success:W,warning:O,uncontained:z,content:G,triggerButton:H,trigger:J,triggerMainContent:L,triggerText:Q,chevronIcon:U,statusIcon:X,panel:Y,hasBackground:Z};function ee(d,e,n){let{isDisabled:t}=d,s=b.$bdb11010cef70236$export$f680877a34711e37(),c=b.$bdb11010cef70236$export$f680877a34711e37(),l=!N.$b5e257d569688ac6$export$535bd6ca7f90a273()&&"onbeforematch"in document.body,o=a.useRef(null),f=a.useCallback(()=>{o.current=requestAnimationFrame(()=>{n.current&&n.current.setAttribute("hidden","until-found")}),S.flushSync(()=>{e.toggle()})},[n,e]);return M.$e9faafb641e167db$export$90fc3a17d93f704c(n,"beforematch",l?f:null),b.$f0a04ccd8dbdd83b$export$e5c5a5f917a5871c(()=>{o.current&&cancelAnimationFrame(o.current),l&&n.current&&!t&&(e.isExpanded?n.current.removeAttribute("hidden"):n.current.setAttribute("hidden","until-found"))},[t,n,e.isExpanded,l]),a.useEffect(()=>()=>{o.current&&cancelAnimationFrame(o.current)},[]),{buttonProps:{id:s,"aria-expanded":e.isExpanded,"aria-controls":c,onPress:$=>{!t&&$.pointerType!=="keyboard"&&e.toggle()},isDisabled:t,onPressStart($){$.pointerType==="keyboard"&&!t&&e.toggle()}},panelProps:{id:c,role:"group","aria-labelledby":s,"aria-hidden":!e.isExpanded,hidden:l?!0:!e.isExpanded}}}function te(d){let[e,n]=v.$458b0a5536c1a7cf$export$40bfa8c7b0832715(d.isExpanded,d.defaultExpanded||!1,d.onExpandedChange);const t=a.useCallback(()=>{n(!0)},[n]),s=a.useCallback(()=>{n(!1)},[n]),c=a.useCallback(()=>{n(!e)},[n,e]);return{isExpanded:e,setExpanded:n,expand:t,collapse:s,toggle:c}}function ne(d){let{allowsMultipleExpanded:e=!1,isDisabled:n=!1}=d,[t,s]=v.$458b0a5536c1a7cf$export$40bfa8c7b0832715(a.useMemo(()=>d.expandedKeys?new Set(d.expandedKeys):void 0,[d.expandedKeys]),a.useMemo(()=>d.defaultExpandedKeys?new Set(d.defaultExpandedKeys):new Set,[d.defaultExpandedKeys]),d.onExpandedChange);return a.useEffect(()=>{if(!e&&t.size>1){let c=t.values().next().value;c!=null&&s(new Set([c]))}}),{allowsMultipleExpanded:e,isDisabled:n,expandedKeys:t,setExpandedKeys:s,toggleKey(c){let i;e?(i=new Set(t),i.has(c)?i.delete(c):i.add(c)):i=new Set(t.has(c)?[]:[c]),s(i)}}}const C=a.createContext(null),ae=a.forwardRef(function(e,n){let t=ne(e),s=x.$64fa3d84918910a7$export$4d86445c2cf5e3({...e,defaultClassName:"react-aria-DisclosureGroup",values:{isDisabled:t.isDisabled,state:t}}),c=h.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(e);return a.createElement("div",{...c,...s,ref:n,"data-disabled":e.isDisabled||void 0},a.createElement(C.Provider,{value:t},s.children))}),de=a.createContext(null),se=a.createContext(null),P=a.createContext(null),ce=a.forwardRef(function(e,n){[e,n]=x.$64fa3d84918910a7$export$29f1550f4b0d4415(e,n,de);let t=a.useContext(C),{id:s,...c}=e,i=b.$bdb11010cef70236$export$f680877a34711e37();s||(s=i);let l=t?t.expandedKeys.has(s):e.isExpanded,o=te({...e,isExpanded:l,onExpandedChange(R){var p;t&&t.toggleKey(s),(p=e.onExpandedChange)===null||p===void 0||p.call(e,R)}}),f=a.useRef(null),$=e.isDisabled||(t==null?void 0:t.isDisabled)||!1,{buttonProps:D,panelProps:w}=ee({...e,isExpanded:l,isDisabled:$},o,f),{isFocusVisible:_,focusProps:I}=y.$f7dceffc5ad7768b$export$4e328f61c538687f({within:!0}),m=x.$64fa3d84918910a7$export$4d86445c2cf5e3({...e,id:void 0,defaultClassName:"react-aria-Disclosure",values:{isExpanded:o.isExpanded,isDisabled:$,isFocusVisibleWithin:_,state:o}}),q=h.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(c);return a.createElement(x.$64fa3d84918910a7$export$2881499e37b75b9a,{values:[[E.$d2b4bc8c273e7be6$export$24d547caef80ccd1,{slots:{[x.$64fa3d84918910a7$export$c62b8e45d58ddad9]:{},trigger:D}}],[P,{panelProps:w,panelRef:f}],[se,o]]},a.createElement("div",{ref:n,"data-expanded":o.isExpanded||void 0,"data-disabled":$||void 0,"data-focus-visible-within":_||void 0,...q,...I,...m},m.children))}),re=a.forwardRef(function(e,n){let{role:t="group"}=e,{panelProps:s,panelRef:c}=a.useContext(P),{isFocusVisible:i,focusProps:l}=y.$f7dceffc5ad7768b$export$4e328f61c538687f({within:!0}),o=x.$64fa3d84918910a7$export$4d86445c2cf5e3({...e,defaultClassName:"react-aria-DisclosurePanel",values:{isFocusVisibleWithin:i}}),f=h.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(e);return a.createElement("div",{...f,ref:x.$5dc95899b306f630$export$c9058316764c140e(n,c),...b.$3ef42575df84b30b$export$9d1611c77c2fe928(s,l),...o,role:t,"data-focus-visible-within":i||void 0},a.createElement(x.$64fa3d84918910a7$export$2881499e37b75b9a,{values:[[E.$d2b4bc8c273e7be6$export$24d547caef80ccd1,null]]},e.children))}),ie="accordion",oe=({variant:d="uncontained",children:e,className:n,...t})=>u.jsx(ae,{"data-testid":ie,className:g.clsx(r.root,d==="contained"?r.contained:r.uncontained,n),...t,children:e}),le=({title:d,children:e,className:n,headingLevel:t="h2",type:s,hasBackground:c=!0,...i})=>{const l=typeof d=="object",f={success:F.Check,warning:j.TriangleAlert,default:null}[s||"default"],$=f?u.jsx(f,{size:20,className:r.statusIcon}):null;return u.jsxs(ce,{...i,className:g.clsx(r.item,s==="success"&&r.success,s==="warning"&&r.warning,n),children:[u.jsx("div",{className:r.trigger,children:u.jsxs(A.Button,{className:r.triggerButton,slot:"trigger",variant:"icon",children:[u.jsx(B.ChevronDown,{size:20,className:r.chevronIcon}),u.jsx("div",{className:r.triggerMainContent,children:l?d:u.jsx(K.Heading,{level:3,elementType:t,className:r.triggerText,children:d})}),$]})}),u.jsx(re,{className:r.panel,children:u.jsx("div",{className:g.clsx(r.content,c&&r.hasBackground),children:e})})]})};exports.Accordion=oe;exports.AccordionItem=le;
|
|
@@ -1,37 +1,37 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import * as d from "react";
|
|
3
3
|
import { c as t } from "./clsx-OuTLNxxd.js";
|
|
4
|
-
import './assets/BadgeContainer.css';const i = "
|
|
4
|
+
import './assets/BadgeContainer.css';const i = "_badge_12ljs_4", c = "_hasChildren_12ljs_13", l = "_badgeContainer_12ljs_22", n = {
|
|
5
5
|
badge: i,
|
|
6
6
|
hasChildren: c,
|
|
7
|
-
badgeContainer:
|
|
8
|
-
},
|
|
7
|
+
badgeContainer: l
|
|
8
|
+
}, h = ({
|
|
9
9
|
children: a,
|
|
10
|
-
className:
|
|
11
|
-
...
|
|
10
|
+
className: s,
|
|
11
|
+
...e
|
|
12
12
|
}) => {
|
|
13
13
|
const o = d.Children.count(a) > 0;
|
|
14
14
|
return /* @__PURE__ */ r(
|
|
15
15
|
"span",
|
|
16
16
|
{
|
|
17
17
|
className: t(
|
|
18
|
-
|
|
19
|
-
o &&
|
|
20
|
-
|
|
18
|
+
n.badge,
|
|
19
|
+
o && n.hasChildren,
|
|
20
|
+
s
|
|
21
21
|
),
|
|
22
|
-
...
|
|
22
|
+
...e,
|
|
23
23
|
children: a
|
|
24
24
|
}
|
|
25
25
|
);
|
|
26
|
-
}, _ = ({ children: a, className:
|
|
26
|
+
}, _ = ({ children: a, className: s, ...e }) => /* @__PURE__ */ r(
|
|
27
27
|
"span",
|
|
28
28
|
{
|
|
29
|
-
className: t(
|
|
30
|
-
...
|
|
29
|
+
className: t(n.badgeContainer, s),
|
|
30
|
+
...e,
|
|
31
31
|
children: a
|
|
32
32
|
}
|
|
33
33
|
);
|
|
34
34
|
export {
|
|
35
|
-
|
|
35
|
+
h as B,
|
|
36
36
|
_ as a
|
|
37
37
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";require('./assets/BadgeContainer.css');const r=require("react/jsx-runtime"),o=require("react"),c=require("./clsx-C11secjj.cjs");function i(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const a=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,a.get?a:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const l=i(o),d="_badge_12ljs_4",u="_hasChildren_12ljs_13",g="_badgeContainer_12ljs_22",s={badge:d,hasChildren:u,badgeContainer:g},b=({children:e,className:t,...n})=>{const a=l.Children.count(e)>0;return r.jsx("span",{className:c.clsx(s.badge,a&&s.hasChildren,t),...n,children:e})},C=({children:e,className:t,...n})=>r.jsx("span",{className:c.clsx(s.badgeContainer,t),...n,children:e});exports.Badge=b;exports.BadgeContainer=C;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import { $ as W, d as Z, b as q, c as Q } from "./Collection
|
|
3
|
-
import { $ as X,
|
|
4
|
-
import { a as re } from "./Link-
|
|
2
|
+
import { $ as W, d as Z, b as q, c as Q } from "./Collection-D2jVTmDW.js";
|
|
3
|
+
import { $ as X, c as Y, a as ee } from "./utils-KLjWgdLR.js";
|
|
4
|
+
import { a as re } from "./Link-CibH8uRY.js";
|
|
5
5
|
import { $ as f } from "./filterDOMProps-D6KHYVBX.js";
|
|
6
6
|
import b, { forwardRef as ae, createContext as ue, useContext as ce } from "react";
|
|
7
7
|
import { $ as te } from "./useLocalizedStringFormatter-CL9MUZ8A.js";
|
|
8
8
|
import { c as de } from "./clsx-OuTLNxxd.js";
|
|
9
|
-
import { L as be } from "./Link-
|
|
9
|
+
import { L as be } from "./Link-ovwNVMfg.js";
|
|
10
10
|
import './assets/Breadcrumbs.css';var i = {};
|
|
11
11
|
i = {
|
|
12
12
|
breadcrumbs: "عناصر الواجهة"
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";require('./assets/Breadcrumbs.css');const o=require("react/jsx-runtime"),b=require("./Collection-BtBX5IMY.cjs"),$=require("./utils-DHNZrQmj.cjs"),Z=require("./Link-CidjjqHb.cjs"),f=require("./filterDOMProps-BS2lrgFA.cjs"),c=require("react"),Q=require("./useLocalizedStringFormatter-BiX5BTlb.cjs"),X=require("./clsx-C11secjj.cjs"),Y=require("./Link-
|
|
1
|
+
"use strict";require('./assets/Breadcrumbs.css');const o=require("react/jsx-runtime"),b=require("./Collection-BtBX5IMY.cjs"),$=require("./utils-DHNZrQmj.cjs"),Z=require("./Link-CidjjqHb.cjs"),f=require("./filterDOMProps-BS2lrgFA.cjs"),c=require("react"),Q=require("./useLocalizedStringFormatter-BiX5BTlb.cjs"),X=require("./clsx-C11secjj.cjs"),Y=require("./Link-ESjrl63P.cjs");var l={};l={breadcrumbs:"عناصر الواجهة"};var m={};m={breadcrumbs:"Трохи хляб"};var x={};x={breadcrumbs:"Popis cesty"};var p={};p={breadcrumbs:"Brødkrummer"};var v={};v={breadcrumbs:"Breadcrumbs"};var C={};C={breadcrumbs:"Πλοηγήσεις breadcrumb"};var D={};D={breadcrumbs:"Breadcrumbs"};var B={};B={breadcrumbs:"Migas de pan"};var E={};E={breadcrumbs:"Lingiread"};var k={};k={breadcrumbs:"Navigointilinkit"};var P={};P={breadcrumbs:"Chemin de navigation"};var g={};g={breadcrumbs:"שבילי ניווט"};var h={};h={breadcrumbs:"Navigacijski putovi"};var L={};L={breadcrumbs:"Morzsamenü"};var N={};N={breadcrumbs:"Breadcrumb"};var R={};R={breadcrumbs:"パンくずリスト"};var A={};A={breadcrumbs:"탐색 표시"};var j={};j={breadcrumbs:"Naršymo kelias"};var F={};F={breadcrumbs:"Atpakaļceļi"};var q={};q={breadcrumbs:"Navigasjonsstier"};var y={};y={breadcrumbs:"Broodkruimels"};var S={};S={breadcrumbs:"Struktura nawigacyjna"};var _={};_={breadcrumbs:"Caminho detalhado"};var z={};z={breadcrumbs:"Categorias"};var M={};M={breadcrumbs:"Miez de pâine"};var T={};T={breadcrumbs:"Навигация"};var I={};I={breadcrumbs:"Navigačné prvky Breadcrumbs"};var K={};K={breadcrumbs:"Drobtine"};var U={};U={breadcrumbs:"Putanje navigacije"};var w={};w={breadcrumbs:"Sökvägar"};var O={};O={breadcrumbs:"İçerik haritaları"};var G={};G={breadcrumbs:"Навігаційна стежка"};var H={};H={breadcrumbs:"导航栏"};var J={};J={breadcrumbs:"導覽列"};var V={};V={"ar-AE":l,"bg-BG":m,"cs-CZ":x,"da-DK":p,"de-DE":v,"el-GR":C,"en-US":D,"es-ES":B,"et-EE":E,"fi-FI":k,"fr-FR":P,"he-IL":g,"hr-HR":h,"hu-HU":L,"it-IT":N,"ja-JP":R,"ko-KR":A,"lt-LT":j,"lv-LV":F,"nb-NO":q,"nl-NL":y,"pl-PL":S,"pt-BR":_,"pt-PT":z,"ro-RO":M,"ru-RU":T,"sk-SK":I,"sl-SI":K,"sr-SP":U,"sv-SE":w,"tr-TR":O,"uk-UA":G,"zh-CN":H,"zh-TW":J};function ee(a){return a&&a.__esModule?a.default:a}function re(a){let{"aria-label":e,...t}=a,r=Q.$fca6afa0e843324b$export$f12b703ca79dfbb1(ee(V),"@react-aria/breadcrumbs");return{navProps:{...f.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(t,{labelable:!0}),"aria-label":e||r.format("breadcrumbs")}}}const n=c.createContext(null),ae=c.forwardRef(function(e,t){[e,t]=$.$64fa3d84918910a7$export$29f1550f4b0d4415(e,t,n);let{CollectionRoot:r}=c.useContext(b.$7135fc7d473fd974$export$4feb769f8ddf26c5),{navProps:u}=re(e);return c.createElement(b.$e1995378a142960e$export$bf788dd355e3a401,{content:c.createElement(b.$e1995378a142960e$export$fb8073518f34e6ec,e)},s=>{var d;return c.createElement("ol",{ref:t,...u,slot:e.slot||void 0,style:e.style,className:(d=e.className)!==null&&d!==void 0?d:"react-aria-Breadcrumbs"},c.createElement(n.Provider,{value:e},c.createElement(r,{collection:s})))})}),ue=b.$e1995378a142960e$export$18af5c7a9e9b3664("item",function(e,t,r){let u=r.nextKey==null,{isDisabled:s,onAction:d}=$.$64fa3d84918910a7$export$fabf2dc03a41866e(n),W={"aria-current":u?"page":null,isDisabled:s||u,onPress:()=>d==null?void 0:d(r.key)},i=$.$64fa3d84918910a7$export$4d86445c2cf5e3({...r.props,children:r.rendered,values:{isDisabled:s||u,isCurrent:u},defaultClassName:"react-aria-Breadcrumb"});return c.createElement("li",{...f.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(e),...i,ref:t,"data-disabled":s||u||void 0,"data-current":u||void 0},c.createElement(Z.$4f118338184dc1d9$export$e2509388b49734e7.Provider,{value:W},i.children))}),ce="_container_1fsfi_4",te={container:ce},de=({items:a,className:e,...t})=>o.jsx(ae,{className:X.clsx(te.container,e),...t,children:a.map(({title:r,href:u,isDisabled:s},d)=>o.jsx(ue,{children:o.jsx(Y.Link,{href:u,isDisabled:s,children:r})},r.toLocaleLowerCase()+d))});exports.Breadcrumbs=de;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as o, jsxs as a, Fragment as l } from "react/jsx-runtime";
|
|
2
|
-
import { B as r } from "./Button.module-
|
|
3
|
-
import { $ as p } from "./Button-
|
|
2
|
+
import { B as r } from "./Button.module-D-mPLRxe.js";
|
|
3
|
+
import { $ as p } from "./Button-CepQFEit.js";
|
|
4
4
|
import { c as u } from "./clsx-OuTLNxxd.js";
|
|
5
5
|
const b = ({
|
|
6
6
|
variant: e = "primary",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as E,
|
|
1
|
+
import { $ as E, d as j, a as F } from "./utils-KLjWgdLR.js";
|
|
2
2
|
import { $ as A } from "./Hidden-C9KWUR7b.js";
|
|
3
3
|
import m, { useMemo as _, createContext as L, forwardRef as B, useRef as S, useEffect as H } from "react";
|
|
4
4
|
import { $ as C } from "./number-BE8InLgI.js";
|
|
@@ -6,7 +6,7 @@ import { c as h, a as R } from "./mergeProps-C1U1OIeJ.js";
|
|
|
6
6
|
import { $ as I } from "./filterDOMProps-D6KHYVBX.js";
|
|
7
7
|
import { $ as K } from "./useLabels-LrKQiY11.js";
|
|
8
8
|
import { $ as U } from "./context-CGNJ3grH.js";
|
|
9
|
-
import { $ as Z } from "./useButton-
|
|
9
|
+
import { $ as Z } from "./useButton-BoIV3kDJ.js";
|
|
10
10
|
import { $ as k } from "./useFocusRing-DOfBqnUN.js";
|
|
11
11
|
import { $ as z } from "./useHover-DQvJ3Y-W.js";
|
|
12
12
|
let P = /* @__PURE__ */ new Map(), x = !1;
|
|
@@ -331,8 +331,8 @@ function ae(a) {
|
|
|
331
331
|
export {
|
|
332
332
|
he as $,
|
|
333
333
|
Q as a,
|
|
334
|
-
|
|
335
|
-
|
|
334
|
+
N as b,
|
|
335
|
+
pe as c,
|
|
336
336
|
me as d,
|
|
337
337
|
te as e,
|
|
338
338
|
D as f,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const r=require("react/jsx-runtime"),t=require("./Button.module-
|
|
1
|
+
"use strict";const r=require("react/jsx-runtime"),t=require("./Button.module-goCEz5qs.cjs"),y=require("./Button-DExMoP5f.cjs"),d=require("./clsx-C11secjj.cjs"),B=({variant:e="primary",fullwidth:u,className:o,iconPlacement:i,size:c="large",icon:n,iconSize:l,...s})=>r.jsx(y.$d2b4bc8c273e7be6$export$353f5b6fc5456de1,{className:d.clsx(t.ButtonStyles.button,e==="primary"&&t.ButtonStyles.primary,e==="secondary"&&t.ButtonStyles.secondary,e==="tertiary"&&t.ButtonStyles.tertiary,e==="danger"&&t.ButtonStyles.danger,e==="icon"&&t.ButtonStyles.iconBtn,u&&t.ButtonStyles.fullwidth,c==="medium"&&t.ButtonStyles.medium,i==="right"&&t.ButtonStyles.iconRight,o),...s,children:r.jsxs(r.Fragment,{children:[n&&r.jsx(n,{"aria-hidden":!0,size:l??20}),s.children]})});exports.Button=B;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import './assets/Button.css';const t = "_button_1ggve_4", n = "_secondary_1ggve_51", _ = "_tertiary_1ggve_74", g = "_iconBtn_1ggve_94", o = "_medium_1ggve_114", e = "_danger_1ggve_119", i = "_iconRight_1ggve_141", c = "_fullwidth_1ggve_145", r = "_primary_1ggve_155", s = {
|
|
2
|
+
button: t,
|
|
3
|
+
secondary: n,
|
|
4
|
+
tertiary: _,
|
|
5
|
+
iconBtn: g,
|
|
6
|
+
medium: o,
|
|
7
|
+
danger: e,
|
|
8
|
+
iconRight: i,
|
|
9
|
+
fullwidth: c,
|
|
10
|
+
primary: r
|
|
11
|
+
};
|
|
12
|
+
export {
|
|
13
|
+
s as B
|
|
14
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";require('./assets/Button.css');const t="_button_1ggve_4",n="_secondary_1ggve_51",_="_tertiary_1ggve_74",e="_iconBtn_1ggve_94",g="_medium_1ggve_114",o="_danger_1ggve_119",i="_iconRight_1ggve_141",c="_fullwidth_1ggve_145",r="_primary_1ggve_155",s={button:t,secondary:n,tertiary:_,iconBtn:e,medium:g,danger:o,iconRight:i,fullwidth:c,primary:r};exports.ButtonStyles=s;
|
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,39 @@
|
|
|
1
|
+
# 11.0.0 (2025-08-06)
|
|
2
|
+
|
|
3
|
+
### 🚀 Features
|
|
4
|
+
|
|
5
|
+
- ⚠️ **file-upload:** replace FileUpload with React Aria FileTrigger ([c539f84bcc](https://github.com/migrationsverket/midas/commit/c539f84bcc))
|
|
6
|
+
- **theme:** add badgeBackground token ([c37972d7a6](https://github.com/migrationsverket/midas/commit/c37972d7a6))
|
|
7
|
+
- **badge:** replace background token ([6f3cf9d4e8](https://github.com/migrationsverket/midas/commit/6f3cf9d4e8))
|
|
8
|
+
- **theme:** add badge-background token ([887eead46f](https://github.com/migrationsverket/midas/commit/887eead46f))
|
|
9
|
+
|
|
10
|
+
### 🩹 Fixes
|
|
11
|
+
|
|
12
|
+
- **link:** fix issue with Link not opening in new window when target='\_blank' ([e172ec0e7c](https://github.com/migrationsverket/midas/commit/e172ec0e7c))
|
|
13
|
+
- **theme:** change dark mode values for danger button ([46099f843e](https://github.com/migrationsverket/midas/commit/46099f843e))
|
|
14
|
+
- **popover:** add overflow-wrap to prevent long string from overflowing ([35895e2d99](https://github.com/migrationsverket/midas/commit/35895e2d99))
|
|
15
|
+
|
|
16
|
+
### 🔧 Maintenance
|
|
17
|
+
|
|
18
|
+
- **deps:** bump the npm_and_yarn group across 1 directory with 4 updates ([e267f19a62](https://github.com/migrationsverket/midas/commit/e267f19a62))
|
|
19
|
+
|
|
20
|
+
### ⚠️ Breaking Changes
|
|
21
|
+
|
|
22
|
+
- **file-upload:** FileUpload is removed and replaced by FileTrigger. Aligns API exactly with React Aria
|
|
23
|
+
|
|
24
|
+
## 10.4.1 (2025-07-05)
|
|
25
|
+
|
|
26
|
+
### 🩹 Fixes
|
|
27
|
+
|
|
28
|
+
- **tag:** 📏 padding changes ([8116a667ed](https://github.com/migrationsverket/midas/commit/8116a667ed))
|
|
29
|
+
- **tabs:** remove list border ([9f1ac2a251](https://github.com/migrationsverket/midas/commit/9f1ac2a251))
|
|
30
|
+
|
|
31
|
+
### 🔧 Maintenance
|
|
32
|
+
|
|
33
|
+
- upgrade RAC to 1.10 + some other minor package upgrades ([71a7ab8093](https://github.com/migrationsverket/midas/commit/71a7ab8093))
|
|
34
|
+
- cleanup repo from unused apps and dependencies ([4cf2fc61f8](https://github.com/migrationsverket/midas/commit/4cf2fc61f8))
|
|
35
|
+
- remove unused test apps ([74c5f90604](https://github.com/migrationsverket/midas/commit/74c5f90604))
|
|
36
|
+
|
|
1
37
|
## 10.4.0 (2025-07-02)
|
|
2
38
|
|
|
3
39
|
### 🚀 Features
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsx as c, jsxs as l } from "react/jsx-runtime";
|
|
2
2
|
import { c as n } from "./clsx-OuTLNxxd.js";
|
|
3
3
|
import * as e from "react";
|
|
4
|
-
import { H as m } from "./Heading-
|
|
5
|
-
import { $ as _ } from "./Button-
|
|
6
|
-
import { $ as h } from "./Link-
|
|
7
|
-
import { A as C } from "./arrow-right-
|
|
4
|
+
import { H as m } from "./Heading-D2y_kiC0.js";
|
|
5
|
+
import { $ as _ } from "./Button-CepQFEit.js";
|
|
6
|
+
import { $ as h } from "./Link-CibH8uRY.js";
|
|
7
|
+
import { A as C } from "./arrow-right-uemUGIg8.js";
|
|
8
8
|
import './assets/Card.css';const A = "_card_1hl11_4", I = "_horizontal_1hl11_10", p = "_cardLink_1hl11_15", u = "_cardContent_1hl11_20", x = "_cardActions_1hl11_39", f = "_cardActionArea_1hl11_49", z = "_cardImage_1hl11_82", k = "_cardLinkIcon_1hl11_114", r = {
|
|
9
9
|
card: A,
|
|
10
10
|
horizontal: I,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";require('./assets/Card.css');const a=require("react/jsx-runtime"),o=require("./clsx-C11secjj.cjs"),l=require("react"),u=require("./Heading-CKTR4sOz.cjs"),C=require("./Button-DExMoP5f.cjs"),x=require("./Link-CidjjqHb.cjs"),_=require("./arrow-right-
|
|
1
|
+
"use strict";require('./assets/Card.css');const a=require("react/jsx-runtime"),o=require("./clsx-C11secjj.cjs"),l=require("react"),u=require("./Heading-CKTR4sOz.cjs"),C=require("./Button-DExMoP5f.cjs"),x=require("./Link-CidjjqHb.cjs"),_=require("./arrow-right-BGd86zzR.cjs");function h(e){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(c,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return c.default=e,Object.freeze(c)}const s=h(l),m="_card_1hl11_4",A="_horizontal_1hl11_10",g="_cardLink_1hl11_15",I="_cardContent_1hl11_20",j="_cardActions_1hl11_39",b="_cardActionArea_1hl11_49",f="_cardImage_1hl11_82",k="_cardLinkIcon_1hl11_114",n={card:m,horizontal:A,cardLink:g,cardContent:I,cardActions:j,cardActionArea:b,cardImage:f,cardLinkIcon:k},i=s.createContext({horizontal:void 0,titleId:void 0}),z=({horizontal:e,className:c,children:t,...r})=>{const d=`card-title-${s.useId()}`;return a.jsx(i.Provider,{value:{horizontal:e,titleId:d},children:a.jsx("div",{...r,className:o.clsx(n.card,e&&n.horizontal,c),children:t})})},L=({children:e,...c})=>{const{horizontal:t}=s.useContext(i);return a.jsx("div",{...c,className:o.clsx(n.cardContent,t&&n.horizontal),children:e})},p=({elementType:e="h2",children:c})=>{const{horizontal:t,titleId:r}=s.useContext(i);return a.jsx(u.Heading,{level:t?5:3,elementType:e,isExpressive:t,className:o.clsx(n.cardTitle,t&&n.horizontal),id:r,children:c})},v=({children:e,...c})=>{const{horizontal:t}=s.useContext(i);return a.jsx("div",{...c,className:o.clsx(n.cardActions,t&&n.horizontal),children:e})},N=({children:e,className:c,...t})=>{const{titleId:r}=s.useContext(i);return a.jsx(C.$d2b4bc8c273e7be6$export$353f5b6fc5456de1,{...t,"aria-labelledby":r,className:o.clsx(n.cardActionArea,c),children:e})},q=({as:e="img",className:c,...t})=>a.jsx(e,{...t,className:o.clsx(n.cardImage,c)}),$=({children:e,as:c,...t})=>{const r=c||x.$4f118338184dc1d9$export$a6c7ac8248d6e38a;return a.jsxs(r,{...t,className:o.clsx(n.cardLink,t.className),children:[e,a.jsx(_.ArrowRight,{className:n.cardLinkIcon,size:24})]})};exports.Card=z;exports.CardActionArea=N;exports.CardActions=v;exports.CardContent=L;exports.CardImage=q;exports.CardLink=$;exports.CardTitle=p;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as s } from "react/jsx-runtime";
|
|
2
2
|
import * as d from "react";
|
|
3
|
-
import { $ as f } from "./utils-
|
|
4
|
-
import { $ as i } from "./Input-
|
|
3
|
+
import { $ as f } from "./utils-KLjWgdLR.js";
|
|
4
|
+
import { $ as i } from "./Input-n-Z20KbW.js";
|
|
5
5
|
import './assets/CharacterCounter.css';const m = "_characterCounter_4224k_4", $ = {
|
|
6
6
|
characterCounter: m
|
|
7
7
|
}, l = d.forwardRef((t, c) => {
|
|
@@ -2,15 +2,15 @@ import { jsxs as E, jsx as r } from "react/jsx-runtime";
|
|
|
2
2
|
import * as x from "react";
|
|
3
3
|
import G, { useEffect as D, useRef as N } from "react";
|
|
4
4
|
import { a as L } from "./RSPContexts-BW2SEIqe.js";
|
|
5
|
-
import { $ as j,
|
|
5
|
+
import { $ as j, c as A } from "./utils-KLjWgdLR.js";
|
|
6
6
|
import { $ as M } from "./Form-CXcEMuBf.js";
|
|
7
7
|
import { c as g } from "./clsx-OuTLNxxd.js";
|
|
8
8
|
import { a as R } from "./mergeProps-C1U1OIeJ.js";
|
|
9
9
|
import { $ as F } from "./VisuallyHidden-CYfmTSCD.js";
|
|
10
10
|
import { a as H, $ as S, b as W, d as _, e as z } from "./useFormValidation-BzzruZKm.js";
|
|
11
|
-
import {
|
|
11
|
+
import { b as I } from "./usePress-BW47IcyU.js";
|
|
12
12
|
import { $ as J } from "./filterDOMProps-D6KHYVBX.js";
|
|
13
|
-
import {
|
|
13
|
+
import { a as K } from "./useFocusable-BjE42axF.js";
|
|
14
14
|
import { $ as C } from "./useToggleState-Bz5rAf4C.js";
|
|
15
15
|
import { $ as Q } from "./useHover-DQvJ3Y-W.js";
|
|
16
16
|
import { $ as T } from "./useFocusRing-DOfBqnUN.js";
|
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
import { jsx as n, jsxs as x } from "react/jsx-runtime";
|
|
2
|
-
import { a as g, L as P } from "./Label-
|
|
3
|
-
import { T as V } from "./Text-
|
|
2
|
+
import { a as g, L as P } from "./Label-JLgFEbP9.js";
|
|
3
|
+
import { T as V } from "./Text-BPcfhYQ9.js";
|
|
4
4
|
import * as b from "react";
|
|
5
5
|
import { useRef as C } from "react";
|
|
6
|
-
import { $ as y, C as m, s as S, a as p } from "./Checkbox-
|
|
7
|
-
import { $ as D } from "./FieldError-
|
|
8
|
-
import { F as I } from "./FieldError-B3YFj-an.js";
|
|
6
|
+
import { $ as y, C as m, s as S, a as p } from "./Checkbox-EB_SCBEo.js";
|
|
7
|
+
import { $ as D, F as I } from "./FieldError-CDCvUjK5.js";
|
|
9
8
|
import { $ as R, c as k } from "./useFormValidation-BzzruZKm.js";
|
|
10
9
|
import { $ as F } from "./useControlledState-u436Wbp1.js";
|
|
11
10
|
import { a as A } from "./mergeProps-C1U1OIeJ.js";
|
|
12
11
|
import { $ as E } from "./filterDOMProps-D6KHYVBX.js";
|
|
13
|
-
import { $ as M } from "./useField-
|
|
12
|
+
import { $ as M } from "./useField-CefQB81E.js";
|
|
14
13
|
import { $ as O } from "./useFocusWithin-T1ifEM_s.js";
|
|
15
14
|
import { u as W } from "./useLocalizedStringFormatter-N0AyjzbM.js";
|
|
16
15
|
function B(e, a) {
|
|
@@ -102,7 +101,7 @@ const G = (e, { value: a }) => {
|
|
|
102
101
|
en: j,
|
|
103
102
|
sv: q
|
|
104
103
|
};
|
|
105
|
-
function
|
|
104
|
+
function ae(e) {
|
|
106
105
|
const a = L(e), t = W(w), { groupProps: f, labelProps: d, descriptionProps: o } = B(
|
|
107
106
|
e,
|
|
108
107
|
a
|
|
@@ -156,5 +155,5 @@ function ie(e) {
|
|
|
156
155
|
);
|
|
157
156
|
}
|
|
158
157
|
export {
|
|
159
|
-
|
|
158
|
+
ae as C
|
|
160
159
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const c=require("react/jsx-runtime"),v=require("./Label-VO6CAFux.cjs"),S=require("./Text-DBHWi5gA.cjs"),m=require("react"),b=require("./Checkbox-Co3h0hur.cjs"),x=require("./FieldError-Bv3Q6ZP-.cjs"),$=require("./useFormValidation-BlFGdPZB.cjs"),V=require("./useControlledState-D0L6S_5r.cjs"),y=require("./mergeProps-B5KXZAI3.cjs"),j=require("./filterDOMProps-BS2lrgFA.cjs"),q=require("./useField-D1UkzeaI.cjs"),k=require("./useFocusWithin-CG8mAt2D.cjs"),D=require("./useLocalizedStringFormatter-BO2iZEL0.cjs");function F(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const l in e)if(l!=="default"){const n=Object.getOwnPropertyDescriptor(e,l);Object.defineProperty(t,l,n.get?n:{enumerable:!0,get:()=>e[l]})}}return t.default=e,Object.freeze(t)}const h=F(m);function O(e,t){let{isDisabled:l,name:n,validationBehavior:d="aria"}=e,{isInvalid:s,validationErrors:o,validationDetails:u}=t.displayValidation,{labelProps:a,fieldProps:i,descriptionProps:r,errorMessageProps:f}=q.$2baaea4c71418dea$export$294aa081a6c6f55d({...e,labelElementType:"span",isInvalid:s,errorMessage:e.errorMessage||o});b.$1ae600c947479353$export$ec98120685d4f57d.set(t,{name:n,descriptionId:r.id,errorMessageId:f.id,validationBehavior:d});let P=j.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(e,{labelable:!0}),{focusWithinProps:C}=k.$9ab94262bd0047c7$export$420e68273165f4ec({onBlurWithin:e.onBlur,onFocusWithin:e.onFocus,onFocusWithinChange:e.onFocusChange});return{groupProps:y.$3ef42575df84b30b$export$9d1611c77c2fe928(P,{role:"group","aria-disabled":l||void 0,...i,...C}),labelProps:a,descriptionProps:r,errorMessageProps:f,isInvalid:s,validationErrors:o,validationDetails:u}}function R(e={}){let[t,l]=V.$458b0a5536c1a7cf$export$40bfa8c7b0832715(e.value,e.defaultValue||[],e.onChange),n=!!e.isRequired&&t.length===0,d=m.useRef(new Map),s=$.$e5be200c675c3b3a$export$fc1a364ae1f3ff10({...e,value:t}),o=s.displayValidation.isInvalid;var u;return{...s,value:t,setValue(i){e.isReadOnly||e.isDisabled||l(i)},isDisabled:e.isDisabled||!1,isReadOnly:e.isReadOnly||!1,isSelected(i){return t.includes(i)},addValue(i){e.isReadOnly||e.isDisabled||t.includes(i)||l(t.concat(i))},removeValue(i){e.isReadOnly||e.isDisabled||t.includes(i)&&l(t.filter(r=>r!==i))},toggleValue(i){e.isReadOnly||e.isDisabled||(t.includes(i)?l(t.filter(r=>r!==i)):l(t.concat(i)))},setInvalid(i,r){let f=new Map(d.current);r.isInvalid?f.set(i,r):f.delete(i),d.current=f,s.updateValidation($.$e5be200c675c3b3a$export$75ee7c75d68f5b0e(...f.values()))},validationState:(u=e.validationState)!==null&&u!==void 0?u:o?"invalid":null,isInvalid:o,isRequired:n}}const I=(e,{value:t})=>{const l=h.Children.toArray(e).filter(a=>h.isValidElement(a)&&a.type===b.Checkbox),n=h.Children.count(l),d=h.Children.toArray(e).filter(a=>h.isValidElement(a)).filter(a=>!!a&&a.type===b.Checkbox).map(a=>a.props.value),s=t.length===0,o=t.length===n;return{allSelected:o,someSelected:!s&&!o,checkboxValues:d}},g=({state:e,errorMessage:t})=>c.jsx(x.$ee014567cb39d3f0$export$ff05c3ac10437e03.Provider,{value:e.displayValidation,children:c.jsx(x.FieldError,{children:t})}),M={selectAll:"Select all"},E={selectAll:"Välj alla"},A={en:M,sv:E};function W(e){const t=R(e),l=D.useLocalizedStringFormatter(A),{groupProps:n,labelProps:d,descriptionProps:s}=O(e,t),{allSelected:o,someSelected:u,checkboxValues:a}=I(e.children,t),i=r=>{t.setValue(r?a:[])};return c.jsxs("div",{...n,className:b.styles.checkboxGroup,children:[c.jsx(v.LabelWrapper,{popover:e.popover,children:e.label&&c.jsx(v.Label,{...d,children:e.label})}),e.description&&c.jsx(S.Text,{slot:"description",...s,children:e.description}),e.errorPosition==="top"&&c.jsx(g,{...e,state:t}),e.showSelectAll&&c.jsx(b.Checkbox,{isSelected:o,isIndeterminate:u,onChange:i,children:e.selectAllLabel||l.format("selectAll")}),c.jsx(b.CheckboxGroupContext.Provider,{value:t,children:e.children}),e.errorPosition==="bottom"&&c.jsx(g,{...e,state:t})]})}exports.CheckboxGroup=W;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { a as H } from "./Hidden-C9KWUR7b.js";
|
|
2
2
|
import { createPortal as z } from "react-dom";
|
|
3
|
-
import {
|
|
3
|
+
import { c as K } from "./useFocusable-BjE42axF.js";
|
|
4
4
|
import u, { useMemo as C, cloneElement as I, forwardRef as N, useContext as y, createContext as v, useCallback as m, useState as q, useRef as B, isValidElement as U } from "react";
|
|
5
5
|
import { $ as M } from "./SSRProvider-40TXmsUG.js";
|
|
6
6
|
import { $ as L } from "./mergeProps-C1U1OIeJ.js";
|
|
@@ -1,40 +1,41 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import * as
|
|
3
|
-
import { a as y, T as
|
|
4
|
-
import { c as d } from "./createLucideIcon-
|
|
5
|
-
import { $ as
|
|
6
|
-
import { u } from "./useLocalizedStringFormatter-N0AyjzbM.js";
|
|
1
|
+
import { jsxs as t, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import * as i from "react";
|
|
3
|
+
import { a as y, T as a } from "./ToggleButtonGroup-HjvaTYD4.js";
|
|
4
|
+
import { c as d } from "./createLucideIcon-XRdN60yz.js";
|
|
5
|
+
import { $ as r } from "./VisuallyHidden-CYfmTSCD.js";
|
|
6
|
+
import { u as g } from "./useLocalizedStringFormatter-N0AyjzbM.js";
|
|
7
7
|
import './assets/ColorSchemeSwitch.css';/**
|
|
8
|
-
* @license lucide-react v0.
|
|
8
|
+
* @license lucide-react v0.525.0 - ISC
|
|
9
9
|
*
|
|
10
10
|
* This source code is licensed under the ISC license.
|
|
11
11
|
* See the LICENSE file in the root directory of this source tree.
|
|
12
12
|
*/
|
|
13
|
-
const
|
|
13
|
+
const u = [
|
|
14
14
|
[
|
|
15
15
|
"path",
|
|
16
16
|
{
|
|
17
|
-
d: "
|
|
18
|
-
key: "
|
|
17
|
+
d: "M18 5a2 2 0 0 1 2 2v8.526a2 2 0 0 0 .212.897l1.068 2.127a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45l1.068-2.127A2 2 0 0 0 4 15.526V7a2 2 0 0 1 2-2z",
|
|
18
|
+
key: "1pdavp"
|
|
19
19
|
}
|
|
20
|
-
]
|
|
21
|
-
]
|
|
20
|
+
],
|
|
21
|
+
["path", { d: "M20.054 15.987H3.946", key: "14rxg9" }]
|
|
22
|
+
], k = d("laptop", u);
|
|
22
23
|
/**
|
|
23
|
-
* @license lucide-react v0.
|
|
24
|
+
* @license lucide-react v0.525.0 - ISC
|
|
24
25
|
*
|
|
25
26
|
* This source code is licensed under the ISC license.
|
|
26
27
|
* See the LICENSE file in the root directory of this source tree.
|
|
27
28
|
*/
|
|
28
|
-
const
|
|
29
|
+
const M = [
|
|
29
30
|
["path", { d: "M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z", key: "a7tn18" }]
|
|
30
|
-
]);
|
|
31
|
+
], f = d("moon", M);
|
|
31
32
|
/**
|
|
32
|
-
* @license lucide-react v0.
|
|
33
|
+
* @license lucide-react v0.525.0 - ISC
|
|
33
34
|
*
|
|
34
35
|
* This source code is licensed under the ISC license.
|
|
35
36
|
* See the LICENSE file in the root directory of this source tree.
|
|
36
37
|
*/
|
|
37
|
-
const
|
|
38
|
+
const S = [
|
|
38
39
|
["circle", { cx: "12", cy: "12", r: "4", key: "4exip2" }],
|
|
39
40
|
["path", { d: "M12 2v2", key: "tus03m" }],
|
|
40
41
|
["path", { d: "M12 20v2", key: "1lh1kg" }],
|
|
@@ -44,34 +45,34 @@ const M = d("Sun", [
|
|
|
44
45
|
["path", { d: "M20 12h2", key: "1q8mjw" }],
|
|
45
46
|
["path", { d: "m6.34 17.66-1.41 1.41", key: "1m8zz5" }],
|
|
46
47
|
["path", { d: "m19.07 4.93-1.41 1.41", key: "1shlcs" }]
|
|
47
|
-
]),
|
|
48
|
-
button:
|
|
49
|
-
},
|
|
48
|
+
], _ = d("sun", S), b = "_button_1dy1i_1", c = {
|
|
49
|
+
button: b
|
|
50
|
+
}, v = {
|
|
50
51
|
darkMode: "Dark Mode",
|
|
51
52
|
lightMode: "Light Mode",
|
|
52
53
|
system: "System Setting"
|
|
53
|
-
},
|
|
54
|
+
}, x = {
|
|
54
55
|
darkMode: "Mörkt läge",
|
|
55
56
|
lightMode: "Ljust läge",
|
|
56
57
|
system: "Systeminställning"
|
|
57
|
-
},
|
|
58
|
-
en:
|
|
59
|
-
sv:
|
|
58
|
+
}, N = {
|
|
59
|
+
en: v,
|
|
60
|
+
sv: x
|
|
60
61
|
}, C = ({
|
|
61
62
|
selector: o = "body",
|
|
62
|
-
defaultValue:
|
|
63
|
+
defaultValue: m = /* @__PURE__ */ new Set(["light dark"]),
|
|
63
64
|
className: h
|
|
64
65
|
}) => {
|
|
65
|
-
const [s, p] =
|
|
66
|
-
|
|
66
|
+
const [s, p] = i.useState(m);
|
|
67
|
+
i.useEffect(() => {
|
|
67
68
|
const l = document.querySelector(o);
|
|
68
69
|
l ? l.style.setProperty(
|
|
69
70
|
"color-scheme",
|
|
70
71
|
Array.from(s).join(" ")
|
|
71
72
|
) : console.warn(`No element found for selector: "${o}"`);
|
|
72
73
|
}, [s, o]);
|
|
73
|
-
const n =
|
|
74
|
-
return /* @__PURE__ */
|
|
74
|
+
const n = g(N);
|
|
75
|
+
return /* @__PURE__ */ t(
|
|
75
76
|
y,
|
|
76
77
|
{
|
|
77
78
|
selectionMode: "single",
|
|
@@ -80,36 +81,36 @@ const M = d("Sun", [
|
|
|
80
81
|
disallowEmptySelection: !0,
|
|
81
82
|
className: h,
|
|
82
83
|
children: [
|
|
83
|
-
/* @__PURE__ */
|
|
84
|
-
|
|
84
|
+
/* @__PURE__ */ t(
|
|
85
|
+
a,
|
|
85
86
|
{
|
|
86
87
|
id: "light dark",
|
|
87
88
|
className: c.button,
|
|
88
89
|
children: [
|
|
89
|
-
/* @__PURE__ */
|
|
90
|
-
/* @__PURE__ */
|
|
90
|
+
/* @__PURE__ */ e(k, {}),
|
|
91
|
+
/* @__PURE__ */ e(r, { children: n.format("system") })
|
|
91
92
|
]
|
|
92
93
|
}
|
|
93
94
|
),
|
|
94
|
-
/* @__PURE__ */
|
|
95
|
-
|
|
95
|
+
/* @__PURE__ */ t(
|
|
96
|
+
a,
|
|
96
97
|
{
|
|
97
98
|
id: "light",
|
|
98
99
|
className: c.button,
|
|
99
100
|
children: [
|
|
100
|
-
/* @__PURE__ */
|
|
101
|
-
/* @__PURE__ */
|
|
101
|
+
/* @__PURE__ */ e(_, {}),
|
|
102
|
+
/* @__PURE__ */ e(r, { children: n.format("lightMode") })
|
|
102
103
|
]
|
|
103
104
|
}
|
|
104
105
|
),
|
|
105
|
-
/* @__PURE__ */
|
|
106
|
-
|
|
106
|
+
/* @__PURE__ */ t(
|
|
107
|
+
a,
|
|
107
108
|
{
|
|
108
109
|
id: "dark",
|
|
109
110
|
className: c.button,
|
|
110
111
|
children: [
|
|
111
|
-
/* @__PURE__ */
|
|
112
|
-
/* @__PURE__ */
|
|
112
|
+
/* @__PURE__ */ e(f, {}),
|
|
113
|
+
/* @__PURE__ */ e(r, { children: n.format("darkMode") })
|
|
113
114
|
]
|
|
114
115
|
}
|
|
115
116
|
)
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";require('./assets/ColorSchemeSwitch.css');const e=require("react/jsx-runtime"),m=require("react"),s=require("./ToggleButtonGroup-DZ_wo0qx.cjs"),i=require("./createLucideIcon-CTVXwe6i.cjs"),a=require("./VisuallyHidden-Doyzl0F7.cjs"),g=require("./useLocalizedStringFormatter-BO2iZEL0.cjs");function p(t){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const o in t)if(o!=="default"){const n=Object.getOwnPropertyDescriptor(t,o);Object.defineProperty(c,o,n.get?n:{enumerable:!0,get:()=>t[o]})}}return c.default=t,Object.freeze(c)}const u=p(m);/**
|
|
2
|
+
* @license lucide-react v0.525.0 - ISC
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the ISC license.
|
|
5
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/const y=[["path",{d:"M18 5a2 2 0 0 1 2 2v8.526a2 2 0 0 0 .212.897l1.068 2.127a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45l1.068-2.127A2 2 0 0 0 4 15.526V7a2 2 0 0 1 2-2z",key:"1pdavp"}],["path",{d:"M20.054 15.987H3.946",key:"14rxg9"}]],f=i.createLucideIcon("laptop",y);/**
|
|
7
|
+
* @license lucide-react v0.525.0 - ISC
|
|
8
|
+
*
|
|
9
|
+
* This source code is licensed under the ISC license.
|
|
10
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
11
|
+
*/const k=[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]],j=i.createLucideIcon("moon",k);/**
|
|
12
|
+
* @license lucide-react v0.525.0 - ISC
|
|
13
|
+
*
|
|
14
|
+
* This source code is licensed under the ISC license.
|
|
15
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
16
|
+
*/const M=[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]],S=i.createLucideIcon("sun",M),x="_button_1dy1i_1",d={button:x},b={darkMode:"Dark Mode",lightMode:"Light Mode",system:"System Setting"},_={darkMode:"Mörkt läge",lightMode:"Ljust läge",system:"Systeminställning"},$={en:b,sv:_},L=({selector:t="body",defaultValue:c=new Set(["light dark"]),className:o})=>{const[n,h]=u.useState(c);u.useEffect(()=>{const l=document.querySelector(t);l?l.style.setProperty("color-scheme",Array.from(n).join(" ")):console.warn(`No element found for selector: "${t}"`)},[n,t]);const r=g.useLocalizedStringFormatter($);return e.jsxs(s.ToggleButtonGroup,{selectionMode:"single",selectedKeys:n,onSelectionChange:h,disallowEmptySelection:!0,className:o,children:[e.jsxs(s.ToggleButton,{id:"light dark",className:d.button,children:[e.jsx(f,{}),e.jsx(a.$5c3e21d68f1c4674$export$439d29a4e110a164,{children:r.format("system")})]}),e.jsxs(s.ToggleButton,{id:"light",className:d.button,children:[e.jsx(S,{}),e.jsx(a.$5c3e21d68f1c4674$export$439d29a4e110a164,{children:r.format("lightMode")})]}),e.jsxs(s.ToggleButton,{id:"dark",className:d.button,children:[e.jsx(j,{}),e.jsx(a.$5c3e21d68f1c4674$export$439d29a4e110a164,{children:r.format("darkMode")})]})]})};exports.ColorSchemeSwitch=L;
|