@dpa-id-components/dpa-shared-components 18.0.4 → 18.1.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/README.md +19 -1
- package/dist/{activities-BbwWiVLr.js → activities-BhRhDOlb.js} +1 -1
- package/dist/{ai-BFVdTg_m.js → ai-C7dKOX-f.js} +1 -1
- package/dist/{alert-BwViN8RZ.js → alert-D2rNwxow.js} +1 -1
- package/dist/{alert-fill-BmVddBoF.js → alert-fill-BXmkV8eq.js} +1 -1
- package/dist/{alert-octagon-Du1XFZ53.js → alert-octagon-BPFgjTgR.js} +1 -1
- package/dist/{apps-C4H9zjLm.js → apps-Cm2_R-aL.js} +1 -1
- package/dist/{archive-DXjJhFYK.js → archive-D5JUYYJU.js} +1 -1
- package/dist/{arrow-down-CtM3fKlO.js → arrow-down-D4LfUvya.js} +1 -1
- package/dist/{arrow-left-DFdL0wI9.js → arrow-left-Dp04ad2H.js} +1 -1
- package/dist/{arrow-nav-left-CuQCQTCr.js → arrow-nav-left-NF0lMqOL.js} +1 -1
- package/dist/{arrow-nav-right-Brt5i_Yw.js → arrow-nav-right-nCu8i5He.js} +1 -1
- package/dist/{arrow-right-Cp1rwJXG.js → arrow-right-D66X1i1j.js} +1 -1
- package/dist/{arrow-up-B9TSL6kL.js → arrow-up-DYYm-SpK.js} +1 -1
- package/dist/{arrowhead-left-HG8C9_Zm.js → arrowhead-left-C_in-SkM.js} +1 -1
- package/dist/{arrowhead-right-Br5XG148.js → arrowhead-right-BVW4OzlW.js} +1 -1
- package/dist/{arrowhead-top-xqXr5CO4.js → arrowhead-top-D4JznBoD.js} +1 -1
- package/dist/{atmo-DCSxGFJp.js → atmo-CoaQJ5Z1.js} +1 -1
- package/dist/{audio-CMQihYDI.js → audio-DHDsZE00.js} +1 -1
- package/dist/{audio-circled-Qo6GRiKj.js → audio-circled-BYW-lYJU.js} +1 -1
- package/dist/{audio-filled-CEfg9Wc-.js → audio-filled-oiehd7FS.js} +1 -1
- package/dist/{bag-PfT7w_tn.js → bag-CKRBwfSw.js} +1 -1
- package/dist/{bell-3FVAjfSe.js → bell-XMnYjRes.js} +1 -1
- package/dist/{bell-fill-ARImnk3u.js → bell-fill-Bla_Yjt0.js} +1 -1
- package/dist/{book-MqLuW2Wt.js → book-MyDStgWT.js} +1 -1
- package/dist/{bookmark-VZAkhaGt.js → bookmark-9hEvl45K.js} +1 -1
- package/dist/{bookmark-fill-jSYoGzam.js → bookmark-fill-DjVGdf8c.js} +1 -1
- package/dist/{bookmark-outlined-B2S0D1no.js → bookmark-outlined-xu1B0AKI.js} +1 -1
- package/dist/{box-BWnkjo3S.js → box-ydpm1tk4.js} +1 -1
- package/dist/{bulb-DE5GZzPb.js → bulb-BSo_piVr.js} +1 -1
- package/dist/{call-BvW3lV_e.js → call-D9OC-7W4.js} +1 -1
- package/dist/{camera-pz3ZKqAK.js → camera-kXOWvOoC.js} +1 -1
- package/dist/{check-D4CJpxFW.js → check-NSQ5iBNs.js} +1 -1
- package/dist/{checklist-3lNRfKJx.js → checklist-CvvFBmGK.js} +1 -1
- package/dist/{checkmark-92_YFNHI.js → checkmark-DbiyQ8XG.js} +1 -1
- package/dist/{checkmark-double-Dq1UhRPV.js → checkmark-double-DseEPieP.js} +1 -1
- package/dist/{chevron-down-Bm9SI1LK.js → chevron-down-DZNvyf86.js} +1 -1
- package/dist/{chevron-left-CsDImGOu.js → chevron-left-BSPiU-Q-.js} +1 -1
- package/dist/{chevron-right-aUZRNunb.js → chevron-right-CoFDL1Jp.js} +1 -1
- package/dist/{chevron-up-S9m_Pf4u.js → chevron-up-BzjT5MVb.js} +1 -1
- package/dist/{clipboard-CiRQciLt.js → clipboard-_RKV4XvZ.js} +1 -1
- package/dist/{clock-DkroIQt6.js → clock-D7pC-Az0.js} +1 -1
- package/dist/{close-BLAdH-OL.js → close-DcD1_swZ.js} +1 -1
- package/dist/{cloud-save-BvSpBb1a.js → cloud-save-B4XnLwo5.js} +1 -1
- package/dist/{code-B9axM9y-.js → code-DyeAnvJL.js} +1 -1
- package/dist/{collapse-D0bdI_e2.js → collapse-Ev8ER1sf.js} +1 -1
- package/dist/{color-palette-BRFLv-4b.js → color-palette-B8j83wVH.js} +1 -1
- package/dist/{comment-COt4Oxum.js → comment-BU2TeSc5.js} +1 -1
- package/dist/{comment-fill-Dg_e-UZq.js → comment-fill-DCwGsRk9.js} +1 -1
- package/dist/components/UiAutocomplete/UiAutocomplete.vue.d.ts +2 -0
- package/dist/components/UiCheckbox/UiCheckbox.vue.d.ts +12 -0
- package/dist/components/UiInput/UiInput.vue.d.ts +14 -0
- package/dist/components/UiLabel/UiLabel.vue.d.ts +25 -0
- package/dist/components/UiMenu/UiMenu.vue.d.ts +1 -1
- package/dist/components/UiSearchInput/UiSearchInput.vue.d.ts +20 -2
- package/dist/components/UiSelect/UiSelect.vue.d.ts +54 -0
- package/dist/components/UiToggleButton/UiToggleButton.vue.d.ts +12 -2
- package/dist/components/index.d.ts +3 -1
- package/dist/{copy-Bmj3wtIm.js → copy-ZmoChZPa.js} +1 -1
- package/dist/{copy-link-C0h0PIRd.js → copy-link-B17EtN22.js} +1 -1
- package/dist/{delete-DJAERQbJ.js → delete-kp4jY4VC.js} +1 -1
- package/dist/{download-C52aOh6x.js → download-Cg3Mfd1F.js} +1 -1
- package/dist/{dpa-id-DW1Jp4QB.js → dpa-id-ClTNNulu.js} +1 -1
- package/dist/dpa-shared-components.js +32 -30
- package/dist/{edit-BHlIIDcs.js → edit-Bki_XTEC.js} +1 -1
- package/dist/{edit-add-INmEZDrx.js → edit-add-B0coqr__.js} +1 -1
- package/dist/{eil-D5RxVTPc.js → eil-DRG6fPII.js} +1 -1
- package/dist/{emoji-hbkVElJc.js → emoji-Cf1T-KUQ.js} +1 -1
- package/dist/{emoji-add-Dt0cyMwM.js → emoji-add-DqGIC6hb.js} +1 -1
- package/dist/{envelope-C94rUx0x.js → envelope-CSTV28Yv.js} +1 -1
- package/dist/{event-ADUpxBiN.js → event-BwEYFOuJ.js} +1 -1
- package/dist/{expand-C_Nqkvw9.js → expand-DNHPrmK0.js} +1 -1
- package/dist/{external-link-C-GC-l-g.js → external-link-BuR-VGNU.js} +1 -1
- package/dist/{file-D6aS-55P.js → file-BjhFi2IL.js} +1 -1
- package/dist/{file-pdf-CRcUtL3A.js → file-pdf-BHf-2EMk.js} +1 -1
- package/dist/{filter-ABRcuJ_0.js → filter-BT19RdxK.js} +1 -1
- package/dist/{filter-outline-CFuo1az3.js → filter-outline-F6nz5Bpv.js} +1 -1
- package/dist/{flag-BPc_mtYK.js → flag-CgG9oBN_.js} +1 -1
- package/dist/{flag-fill-ugjDl8am.js → flag-fill-BaJ2y1KO.js} +1 -1
- package/dist/{flag-filled-CSMtd-hr.js → flag-filled-VB61P7io.js} +1 -1
- package/dist/{flag-outline-Cw1aHxX7.js → flag-outline-DxA60mar.js} +1 -1
- package/dist/{flags-B0qdS8TL.js → flags-BoKaz6G3.js} +1 -1
- package/dist/{flash-DFdHjbK9.js → flash-Y4tcmzfR.js} +1 -1
- package/dist/{folder-Btu1EcHk.js → folder-XvaWfgWv.js} +1 -1
- package/dist/{folder-add-CXJuJFde.js → folder-add-6CZrU-DR.js} +1 -1
- package/dist/{folder-fill-BKCbcjAx.js → folder-fill-KIXzynSA.js} +1 -1
- package/dist/{folder-filled-Bfx6W-C4.js → folder-filled-B1KH5ftl.js} +1 -1
- package/dist/{gallery-BlaQ1fE-.js → gallery-BkItUHtv.js} +1 -1
- package/dist/{graphic-DSw-8gHy.js → graphic-CtmVrWFt.js} +1 -1
- package/dist/{graphic-circled-BOR22uSp.js → graphic-circled-g4_avs-O.js} +1 -1
- package/dist/{graphic-filled-atRaNeyj.js → graphic-filled-D7puYjZ3.js} +1 -1
- package/dist/{graphics-LE15zCcH.js → graphics-CFpLrSml.js} +1 -1
- package/dist/{grid-1-B7zIJuPX.js → grid-1-Cx0q8kBw.js} +1 -1
- package/dist/{grid-2-CvIXQAr8.js → grid-2-De-14OuV.js} +1 -1
- package/dist/{grid-3-Ccw0LWFQ.js → grid-3-D4xY7BZ0.js} +1 -1
- package/dist/{grid-4-gm0M_j66.js → grid-4-DWZ7WVG_.js} +1 -1
- package/dist/{grid-6-B7YoB9b2.js → grid-6-Dy1Qqd9J.js} +1 -1
- package/dist/{grid-9-QG_tmIS_.js → grid-9-C0JG04wt.js} +1 -1
- package/dist/{grid-masonry-9-ONwNQWPO.js → grid-masonry-9-ShvPSsDK.js} +1 -1
- package/dist/{grid-masonry-DuGAh8mH.js → grid-masonry-BNXF8_7C.js} +1 -1
- package/dist/{help-DYf7WQe7.js → help-yy-azDe4.js} +1 -1
- package/dist/{home-pJFLQROc.js → home-CbjD3lFF.js} +1 -1
- package/dist/{image focus point-tP21-FA6.js → image focus point-Cv3Q7T8w.js } +1 -1
- package/dist/{image-BZueRuGe.js → image-D7edNk-C.js} +1 -1
- package/dist/{impact-high-GC2HRy72.js → impact-high-Bnsk5YsA.js} +1 -1
- package/dist/{impact-low-BoBOwM8u.js → impact-low-CK-fLvjS.js} +1 -1
- package/dist/{impact-medium-BbUgtjDU.js → impact-medium-CmGfiR0q.js} +1 -1
- package/dist/{impact-very-high-Cpnddf8J.js → impact-very-high-CUsJ_26t.js} +1 -1
- package/dist/{impact-very-low-C-6uquzx.js → impact-very-low-rHoskEmi.js} +1 -1
- package/dist/{index-Dv7nm4aM.js → index-DPTr_CW4.js} +3913 -3808
- package/dist/{info-V40cTf5t.js → info-DyGrTLDs.js} +1 -1
- package/dist/{info-fill-CrohdG84.js → info-fill-DpBY1kXH.js} +1 -1
- package/dist/{info-filled-BkqFdglQ.js → info-filled-CTwiqqLB.js} +1 -1
- package/dist/{label-B80SS4P-.js → label-DibCUknb.js} +1 -1
- package/dist/{label-filled-BXIUgk-g.js → label-filled-RM4axxFO.js} +1 -1
- package/dist/{language-BEj4V8a8.js → language-C3oWb3pn.js} +1 -1
- package/dist/{latest-DMC05fKt.js → latest-BI0ob85J.js} +1 -1
- package/dist/{lightbulb-401lIxAe.js → lightbulb-CnWbpapX.js} +1 -1
- package/dist/{list-C0R3e0SU.js → list-1fajhqjy.js} +1 -1
- package/dist/{list-search-B1N0Dfaz.js → list-search--F238TI5.js} +1 -1
- package/dist/{lock-filled-DxxhfAfn.js → lock-filled-BLm0tRpx.js} +1 -1
- package/dist/{lock-5fwuAGDf.js → lock-qHiUVvb6.js} +1 -1
- package/dist/{mail-DEizanBY.js → mail-BwVLL_CQ.js} +1 -1
- package/dist/{map-DhVhFfUu.js → map-SD_wDBoB.js} +1 -1
- package/dist/{map-outline-DUZmZn-1.js → map-outline-Blwf07ko.js} +1 -1
- package/dist/{menu-CwMwgwAw.js → menu-CJMzUGhg.js} +1 -1
- package/dist/{minus-CnTIHuR2.js → minus-NMYYPN4G.js} +1 -1
- package/dist/{more-horizontal-CghMRJVo.js → more-horizontal-CR7H4XJf.js} +1 -1
- package/dist/{more-vertical-C0XQRK0N.js → more-vertical-DRi2KUBF.js} +1 -1
- package/dist/{move-D1ck-MZ3.js → move-CnXcnaI-.js} +1 -1
- package/dist/{move-up-down-BP7Od7Ac.js → move-up-down-B-MGteUJ.js} +1 -1
- package/dist/{navigation-ClS6f-3Z.js → navigation-C6_-fobC.js} +1 -1
- package/dist/{note-DbxrCI_5.js → note-D_l95t3P.js} +1 -1
- package/dist/{offline-C3OanK_f.js → offline-B-KVP0PH.js} +1 -1
- package/dist/{package-ZYdpv1ge.js → package-CKKAsIyR.js} +1 -1
- package/dist/{paper-plane-s7xBbP39.js → paper-plane-CXv4S955.js} +1 -1
- package/dist/{paperplane-Dl2ilmua.js → paperplane-Dd72tRkT.js} +1 -1
- package/dist/{pause-DaPa9lEz.js → pause-B-_Xr0gu.js} +1 -1
- package/dist/{pause-circle-BNsPjIAv.js → pause-circle-qdguAsne.js} +1 -1
- package/dist/{pdf-KYltIHyA.js → pdf-kF-z2ep4.js} +1 -1
- package/dist/{pen-B4eAtxSi.js → pen-D8Uh2zQl.js} +1 -1
- package/dist/{pen-check-kDkdMrOI.js → pen-check-Bps1eJIa.js} +1 -1
- package/dist/{people-C70YATVw.js → people-D0i7Dff8.js} +1 -1
- package/dist/{phone-BPnung5r.js → phone-DfT09W5t.js} +1 -1
- package/dist/{picture-D7xlooNu.js → picture-CGMbzcYY.js} +1 -1
- package/dist/{picture-circled-DWnLMugI.js → picture-circled-C5xr6a5V.js} +1 -1
- package/dist/{picture-filled-B6oZx2SL.js → picture-filled-bCFwoxTK.js} +1 -1
- package/dist/{picture-gallery-CUMpQqrP.js → picture-gallery-Ny7XwbWp.js} +1 -1
- package/dist/{pin-drPa4hVL.js → pin-BRQSAE3B.js} +1 -1
- package/dist/{planning-CJkQTdBI.js → planning-muG3T-6d.js} +1 -1
- package/dist/{play-CBYXQht-.js → play-BcFxtF5b.js} +1 -1
- package/dist/{play-circle-CI3C0c1w.js → play-circle-B2ahlsZk.js} +1 -1
- package/dist/{play-fill-BBlVQZYO.js → play-fill-D53-aAwU.js} +1 -1
- package/dist/{plus-DAzwGEQ1.js → plus-B86SmZGh.js} +1 -1
- package/dist/{plus-circle-Dxl8Mg-W.js → plus-circle-CnUjJsnF.js} +1 -1
- package/dist/{print-C-cBMLcJ.js → print-qLntWNd7.js} +1 -1
- package/dist/{refresh-NxKYdx7S.js → refresh-B_CT3vb1.js} +1 -1
- package/dist/{reset-BtO5MoJe.js → reset-BID4RkcV.js} +1 -1
- package/dist/{responsive-Cgs2b9oh.js → responsive-ZL1NzTfX.js} +1 -1
- package/dist/{rubix-thema-BvCOGmAA.js → rubix-thema-BvZYzAwX.js} +1 -1
- package/dist/{save-BjGYc9Oz.js → save-BybCvQGY.js} +1 -1
- package/dist/{saved-search-BOPAgxXE.js → saved-search-DBVj7gkd.js} +1 -1
- package/dist/{saved-search-fill-DcukcZ8I.js → saved-search-fill-C8grEFO7.js} +1 -1
- package/dist/{search-Cy0g7KPu.js → search-BBvIb5gY.js} +1 -1
- package/dist/{settings-CJASe3MC.js → settings-C3pzFKav.js} +1 -1
- package/dist/{share-tfBL6a2o.js → share-B9NEdX5h.js} +1 -1
- package/dist/{share-alternative-F5ZneLHK.js → share-alternative-D-owBQIX.js} +1 -1
- package/dist/{sidebar-DUDBvBVF.js → sidebar-BceztyGh.js} +1 -1
- package/dist/{sidebar-fill-DUdq-Xn6.js → sidebar-fill-meae4nW0.js} +1 -1
- package/dist/{slack-DcICWZm4.js → slack-qT8c0TWt.js} +1 -1
- package/dist/{slider-config-DQPsONUo.js → slider-config-DqpWW1vb.js} +1 -1
- package/dist/{spellcheck-vp7alkKt.js → spellcheck-s_Xcuq7Y.js} +1 -1
- package/dist/{spinner-CrvwQeFB.js → spinner-DJwVbRES.js} +1 -1
- package/dist/src/components/UiCheckbox/UiCheckbox.stories.ts +34 -1
- package/dist/src/components/UiCheckbox/UiCheckbox.vue +22 -13
- package/dist/src/components/UiColorPicker/README.md +5 -5
- package/dist/src/components/UiColorPicker/UiColorPicker.stories.ts +3 -2
- package/dist/src/components/UiInput/README.md +1 -0
- package/dist/src/components/UiInput/UiInput.spec.ts +1 -1
- package/dist/src/components/UiInput/UiInput.vue +28 -20
- package/dist/src/components/UiLabel/README.md +33 -0
- package/dist/src/components/UiLabel/UiLabel.vue +16 -0
- package/dist/src/components/UiMenu/UiMenu.stories.ts +108 -83
- package/dist/src/components/UiMenu/UiMenu.vue +33 -25
- package/dist/src/components/UiRadioInputGroup/UiRadioInputGroup.vue +4 -3
- package/dist/src/components/UiSearchInput/README.md +28 -22
- package/dist/src/components/UiSearchInput/UiSearchInput.vue +31 -3
- package/dist/src/components/UiSelect/README.md +54 -0
- package/dist/src/components/UiSelect/UIiSelect.spec.ts +102 -0
- package/dist/src/components/UiSelect/UiSelect.stories.ts +94 -0
- package/dist/src/components/UiSelect/UiSelect.vue +76 -0
- package/dist/src/components/UiToggleButton/README.md +3 -3
- package/dist/src/components/UiToggleButton/UiToggleButton.vue +14 -3
- package/dist/src/components/index.ts +4 -0
- package/dist/{standard-view-D-qovy-w.js → standard-view-Dh6JMdWs.js} +1 -1
- package/dist/{star-DkEtXygS.js → star-BSFTyui3.js} +1 -1
- package/dist/{star-fill-B3UIgpwR.js → star-fill-CVhN8bqR.js} +1 -1
- package/dist/{star-filled-CABVyxaj.js → star-filled-DacJoaAu.js} +1 -1
- package/dist/{stop-DVMTK2hL.js → stop-BwWBCobo.js} +1 -1
- package/dist/{story-CxxjsD-k.js → story-CBNTp-lp.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/{sync-zMXY0V1C.js → sync-BaZtL0xx.js} +1 -1
- package/dist/{tasks-DpN7WQZz.js → tasks-DL9yIRdK.js} +1 -1
- package/dist/{text-W_RbrRon.js → text-R4vHS9Pd.js} +1 -1
- package/dist/{text-circled-BHd0dMnB.js → text-circled-CnnnL1id.js} +1 -1
- package/dist/{text-filled-jsyj0ExF.js → text-filled-DthiiE_T.js} +1 -1
- package/dist/{thumbs-down-C2ptPqZc.js → thumbs-down-CSyRwO6Y.js} +1 -1
- package/dist/{thumbs-up-BMCx64e0.js → thumbs-up-8f-7gcq6.js} +1 -1
- package/dist/{thumbs-up-double-MTOYJ2Fl.js → thumbs-up-double-Dhf_0k-o.js} +1 -1
- package/dist/{topic-9Otcj69g.js → topic-LED8OQq_.js} +1 -1
- package/dist/{union-B40CNI61.js → union-C3GueVUs.js} +1 -1
- package/dist/{upload-cVhWF-6z.js → upload-A6JuSLcS.js} +1 -1
- package/dist/{video overlay-DkK7hhfX.js → video overlay-DIDpPww1.js } +1 -1
- package/dist/{video-circled-PNxZBQ-s.js → video-circled-BVu5I_wj.js} +1 -1
- package/dist/{video-DYgatdw7.js → video-eeoO9KOd.js} +1 -1
- package/dist/{video-filled-Bb-vqKj8.js → video-filled-_eOJ2sb3.js} +1 -1
- package/dist/{video-rounded-D3l9Fqt-.js → video-rounded-AiQniTjB.js} +1 -1
- package/dist/{view-B2bcpRUS.js → view-CuvlyhMJ.js} +1 -1
- package/dist/{view-off-CtEPSsc9.js → view-off-Ccn9Z_zK.js} +1 -1
- package/dist/{volume-up-DE0_cC3L.js → volume-up-3FMnPLw6.js} +1 -1
- package/package.json +28 -19
- package/src/components/UiCheckbox/UiCheckbox.vue +22 -13
- package/src/components/UiColorPicker/README.md +5 -5
- package/src/components/UiInput/README.md +1 -0
- package/src/components/UiInput/UiInput.vue +28 -20
- package/src/components/UiLabel/README.md +33 -0
- package/src/components/UiLabel/UiLabel.vue +16 -0
- package/src/components/UiMenu/UiMenu.vue +33 -25
- package/src/components/UiRadioInputGroup/UiRadioInputGroup.vue +4 -3
- package/src/components/UiSearchInput/README.md +28 -22
- package/src/components/UiSearchInput/UiSearchInput.vue +31 -3
- package/src/components/UiSelect/README.md +54 -0
- package/src/components/UiSelect/UiSelect.vue +76 -0
- package/src/components/UiToggleButton/README.md +3 -3
- package/src/components/UiToggleButton/UiToggleButton.vue +14 -3
- package/src/components/index.ts +4 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dpa-id-components/dpa-shared-components",
|
|
3
|
-
"version": "18.0
|
|
3
|
+
"version": "18.1.0",
|
|
4
4
|
"description": "Shared Vue components library for dpa projects",
|
|
5
5
|
"files": [
|
|
6
6
|
"src",
|
|
@@ -50,42 +50,51 @@
|
|
|
50
50
|
"engines": {
|
|
51
51
|
"node": "^23.11.0 || >=24"
|
|
52
52
|
},
|
|
53
|
+
"devEngines": {
|
|
54
|
+
"runtime": {
|
|
55
|
+
"name": "node",
|
|
56
|
+
"version": "^24.8.0"
|
|
57
|
+
},
|
|
58
|
+
"packageManager": {
|
|
59
|
+
"name": "npm",
|
|
60
|
+
"version": "^11.6.0"
|
|
61
|
+
}
|
|
62
|
+
},
|
|
53
63
|
"devDependencies": {
|
|
54
|
-
"@babel/core": "7.28.
|
|
64
|
+
"@babel/core": "7.28.4",
|
|
55
65
|
"@babel/preset-env": "7.28.3",
|
|
56
|
-
"@eslint/js": "9.
|
|
57
|
-
"@storybook/addon-docs": "9.1.
|
|
58
|
-
"@storybook/addon-links": "9.1.
|
|
59
|
-
"@storybook/addon-themes": "9.1.
|
|
60
|
-
"@storybook/builder-vite": "9.1.
|
|
61
|
-
"@storybook/vue3-vite": "9.1.
|
|
66
|
+
"@eslint/js": "9.35.0",
|
|
67
|
+
"@storybook/addon-docs": "9.1.6",
|
|
68
|
+
"@storybook/addon-links": "9.1.6",
|
|
69
|
+
"@storybook/addon-themes": "9.1.6",
|
|
70
|
+
"@storybook/builder-vite": "9.1.6",
|
|
71
|
+
"@storybook/vue3-vite": "9.1.6",
|
|
62
72
|
"@tailwindcss/typography": "0.5.16",
|
|
63
73
|
"@tailwindcss/vite": "4.1.13",
|
|
64
74
|
"@types/jsdom": "21.1.7",
|
|
65
|
-
"@types/node": "24.
|
|
66
|
-
"@types/uuid": "10.0.0",
|
|
75
|
+
"@types/node": "24.5.0",
|
|
67
76
|
"@vitejs/plugin-vue": "6.0.1",
|
|
68
77
|
"@vue/test-utils": "2.4.6",
|
|
69
78
|
"ajv": "8.17.1",
|
|
70
79
|
"commit-and-tag-version": "12.6.0",
|
|
71
|
-
"eslint": "9.
|
|
72
|
-
"eslint-plugin-simple-import-sort": "
|
|
73
|
-
"eslint-plugin-storybook": "9.1.
|
|
74
|
-
"jsdom": "
|
|
80
|
+
"eslint": "9.35.0",
|
|
81
|
+
"eslint-plugin-simple-import-sort": "12.1.1",
|
|
82
|
+
"eslint-plugin-storybook": "9.1.6",
|
|
83
|
+
"jsdom": "27.0.0",
|
|
75
84
|
"npm-run-all2": "8.0.4",
|
|
76
85
|
"prettier": "3.6.2",
|
|
77
86
|
"rimraf": "6.0.1",
|
|
78
87
|
"rollup-plugin-copy": "3.5.0",
|
|
79
|
-
"storybook": "9.1.
|
|
88
|
+
"storybook": "9.1.6",
|
|
80
89
|
"tailwindcss": "4.1.13",
|
|
81
90
|
"typescript": "5.9.2",
|
|
82
|
-
"vite": "7.1.
|
|
91
|
+
"vite": "7.1.5",
|
|
83
92
|
"vite-plugin-dts": "4.5.4",
|
|
84
93
|
"vitest": "3.2.4",
|
|
85
94
|
"vue": "3.5.21",
|
|
86
|
-
"vue-component-meta": "3.0.
|
|
95
|
+
"vue-component-meta": "3.0.7",
|
|
87
96
|
"vue-router": "4.5.1",
|
|
88
|
-
"vue-tsc": "3.0.
|
|
97
|
+
"vue-tsc": "3.0.7"
|
|
89
98
|
},
|
|
90
99
|
"dependencies": {
|
|
91
100
|
"@floating-ui/vue": "^1.1.8",
|
|
@@ -100,7 +109,7 @@
|
|
|
100
109
|
"eslint-plugin-vue": "^10.4.0",
|
|
101
110
|
"globals": "^16.3.0",
|
|
102
111
|
"tailwind-merge": "^3.3.1",
|
|
103
|
-
"uuid": "^
|
|
112
|
+
"uuid": "^13.0.0",
|
|
104
113
|
"vue-eslint-parser": "^10.2.0"
|
|
105
114
|
},
|
|
106
115
|
"peerDependencies": {
|
|
@@ -1,31 +1,32 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<
|
|
3
|
-
class="flex flex-col"
|
|
2
|
+
<UiLabel
|
|
4
3
|
:class="
|
|
5
4
|
cn(
|
|
6
|
-
disabled ? 'text-gray-400' :
|
|
5
|
+
disabled ? 'text-gray-400' : undefined,
|
|
6
|
+
'flex cursor-pointer flex-col items-start',
|
|
7
7
|
$attrs.class as string,
|
|
8
8
|
)
|
|
9
9
|
"
|
|
10
|
+
:for="id"
|
|
10
11
|
:data-testid="$attrs['data-testid']"
|
|
11
12
|
>
|
|
12
13
|
<input
|
|
13
14
|
:id="id"
|
|
14
|
-
class="peer relative size-0 appearance-none
|
|
15
|
+
class="peer relative size-0 appearance-none focus:outline-hidden"
|
|
15
16
|
:class="size"
|
|
16
17
|
type="checkbox"
|
|
17
18
|
:checked="checked"
|
|
18
19
|
:aria-checked="checked"
|
|
19
20
|
:disabled="disabled"
|
|
20
|
-
:aria-invalid="
|
|
21
|
+
:aria-invalid="Boolean($slots.errors || showError)"
|
|
21
22
|
:aria-errormessage="
|
|
22
|
-
|
|
23
|
+
$slots.errors || showError ? `${id}-errors` : undefined
|
|
23
24
|
"
|
|
24
25
|
v-bind="{ ...$attrs, class: null, 'data-testid': null }"
|
|
25
26
|
@change="handleChange"
|
|
26
27
|
/>
|
|
27
28
|
<span
|
|
28
|
-
class="flex items-center peer-checked:opacity-100 before:box-border before:inline-block before:shrink-0 before:border-2 before:transition-colors before:content-[''] after:absolute after:block peer-checked:after:content-[url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0naHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnIHZpZXdCb3g9JzAgMCAyMCAyMCcgZmlsbD0nbm9uZSc+PHJlY3QgLz48cGF0aCBmaWxsLXJ1bGU9J2V2ZW5vZGQnIGNsaXAtcnVsZT0nZXZlbm9kZCcgZD0nTTguMjE5NjUgMTVDNy45ODk2NSAxNSA3Ljc2OTY1IDE0LjkwNSA3LjYxMjE1IDE0LjczNzVMMy41NTk2NSAxMC40MjE3QzMuMjQzODEgMTAuMDg2NyAzLjI2MTMxIDkuNTU5MTggMy41OTYzMSA5LjI0NDE4QzMuOTMyMTUgOC45MjkxOCA0LjQ1OTY1IDguOTQ1ODUgNC43NzM4MSA5LjI4MDg1TDguMjExMzEgMTIuOTRMMTUuMjE4IDUuMjcxNjhDMTUuNTI5NiA0LjkzMDg1IDE2LjA1NjMgNC45MDgzNSAxNi4zOTYzIDUuMjE4MzVDMTYuNzM1NSA1LjUyODM1IDE2Ljc1ODggNi4wNTU4NSAxNi40NDg4IDYuMzk1MDFMOC44MzQ2NSAxNC43MjgzQzguNjc4ODEgMTQuOSA4LjQ1NzE1IDE0Ljk5ODMgOC4yMjU0OCAxNUg4LjIxOTY1WicgZmlsbD0nd2hpdGUnLz48L3N2Zz4=)]"
|
|
29
|
+
class="flex items-center text-base peer-checked:opacity-100 before:box-border before:inline-block before:shrink-0 before:border-2 before:transition-colors before:content-[''] after:absolute after:block peer-checked:after:content-[url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0naHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnIHZpZXdCb3g9JzAgMCAyMCAyMCcgZmlsbD0nbm9uZSc+PHJlY3QgLz48cGF0aCBmaWxsLXJ1bGU9J2V2ZW5vZGQnIGNsaXAtcnVsZT0nZXZlbm9kZCcgZD0nTTguMjE5NjUgMTVDNy45ODk2NSAxNSA3Ljc2OTY1IDE0LjkwNSA3LjYxMjE1IDE0LjczNzVMMy41NTk2NSAxMC40MjE3QzMuMjQzODEgMTAuMDg2NyAzLjI2MTMxIDkuNTU5MTggMy41OTYzMSA5LjI0NDE4QzMuOTMyMTUgOC45MjkxOCA0LjQ1OTY1IDguOTQ1ODUgNC43NzM4MSA5LjI4MDg1TDguMjExMzEgMTIuOTRMMTUuMjE4IDUuMjcxNjhDMTUuNTI5NiA0LjkzMDg1IDE2LjA1NjMgNC45MDgzNSAxNi4zOTYzIDUuMjE4MzVDMTYuNzM1NSA1LjUyODM1IDE2Ljc1ODggNi4wNTU4NSAxNi40NDg4IDYuMzk1MDFMOC44MzQ2NSAxNC43MjgzQzguNjc4ODEgMTQuOSA4LjQ1NzE1IDE0Ljk5ODMgOC4yMjU0OCAxNUg4LjIxOTY1WicgZmlsbD0nd2hpdGUnLz48L3N2Zz4=)]"
|
|
29
30
|
:class="{
|
|
30
31
|
'before:size-5 after:size-5': size === 'medium',
|
|
31
32
|
'before:size-4 after:size-4': size === 'small',
|
|
@@ -33,26 +34,27 @@
|
|
|
33
34
|
color === 'blue',
|
|
34
35
|
'before:border-gray-800 peer-checked:before:bg-gray-800 peer-hover:before:border-gray-900 peer-checked:peer-hover:before:bg-gray-900':
|
|
35
36
|
color === 'gray',
|
|
36
|
-
'before:border-gray-500 peer-checked:before:bg-gray-500':
|
|
37
|
-
|
|
37
|
+
'text-gray-400 before:border-gray-500 peer-checked:before:bg-gray-500':
|
|
38
|
+
disabled,
|
|
39
|
+
'before:mr-2': $slots.default,
|
|
38
40
|
}"
|
|
39
41
|
>
|
|
40
42
|
<slot />
|
|
41
43
|
</span>
|
|
42
44
|
|
|
43
45
|
<div
|
|
44
|
-
v-if="
|
|
46
|
+
v-if="$slots.errors || showError"
|
|
45
47
|
:id="`${id}-errors`"
|
|
46
48
|
data-testid="errorMessage"
|
|
47
|
-
class="
|
|
49
|
+
class="mt-2 bg-alert-red-default px-4 py-1 text-xs leading-normal font-medium text-white transition-all duration-150 ease-in-out peer-aria-invalid:peer-hover:bg-alert-red-dark peer-aria-invalid:peer-focus:bg-alert-red-dark"
|
|
48
50
|
>
|
|
49
|
-
<slot v-if="
|
|
51
|
+
<slot v-if="$slots.errors" name="errors" />
|
|
50
52
|
|
|
51
53
|
<template v-else>
|
|
52
54
|
{{ errorMessage }}
|
|
53
55
|
</template>
|
|
54
56
|
</div>
|
|
55
|
-
</
|
|
57
|
+
</UiLabel>
|
|
56
58
|
</template>
|
|
57
59
|
|
|
58
60
|
<script setup lang="ts">
|
|
@@ -60,6 +62,7 @@ import { v4 as uuidv4 } from "uuid";
|
|
|
60
62
|
import { computed } from "vue";
|
|
61
63
|
|
|
62
64
|
import { cn } from "../../utils/cn.js";
|
|
65
|
+
import UiLabel from "../UiLabel/UiLabel.vue";
|
|
63
66
|
|
|
64
67
|
const emit = defineEmits<{
|
|
65
68
|
change: [boolean];
|
|
@@ -70,7 +73,13 @@ defineOptions({
|
|
|
70
73
|
});
|
|
71
74
|
|
|
72
75
|
defineSlots<{
|
|
76
|
+
/**
|
|
77
|
+
* Label content.
|
|
78
|
+
*/
|
|
73
79
|
default: () => any;
|
|
80
|
+
/**
|
|
81
|
+
* Error content.
|
|
82
|
+
*/
|
|
74
83
|
errors?: () => any;
|
|
75
84
|
}>();
|
|
76
85
|
|
|
@@ -2,15 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
## Usage
|
|
4
4
|
|
|
5
|
-
```
|
|
6
|
-
<!-- SomeComponent.vue using UiColorPicker -->
|
|
5
|
+
```vue
|
|
7
6
|
<template>
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
<UiLabel for="colorPicker">Farbe wählen</UiLabel>
|
|
8
|
+
<UiColorPicker id="colorPicker" v-model="colorValue" />
|
|
10
9
|
</template>
|
|
11
10
|
|
|
12
11
|
<script setup>
|
|
13
|
-
import {
|
|
12
|
+
import { ref } from "vue";
|
|
13
|
+
import { UiColorPicker, UiLabel } from "@dpa-id-components/dpa-shared-components";
|
|
14
14
|
|
|
15
15
|
const colorValue = ref("");
|
|
16
16
|
</script>
|
|
@@ -63,4 +63,5 @@ import { UiInput } from "@dpa-id-components/dpa-shared-components";
|
|
|
63
63
|
| Name | Description |
|
|
64
64
|
|-----------|----------------------------------------------------|
|
|
65
65
|
| `buttons` | slot for rendering a button inside the input field |
|
|
66
|
+
| `default` | Label content |
|
|
66
67
|
| `errors` | For validation error content that's associated with the form control via `aria-errormessage` |
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<!-- ui-input -->
|
|
3
2
|
<div
|
|
4
|
-
class="group relative"
|
|
5
|
-
:class="$attrs.class"
|
|
3
|
+
:class="cn('group relative', $attrs.class as string)"
|
|
6
4
|
:data-testid="$attrs['data-testid']"
|
|
7
5
|
>
|
|
8
|
-
<
|
|
6
|
+
<UiLabel
|
|
7
|
+
v-if="$slots.default || label"
|
|
8
|
+
:for="id"
|
|
9
9
|
:class="
|
|
10
10
|
cn(
|
|
11
|
+
'pointer-events-none absolute left-3 origin-left px-1 transition-all duration-150 select-none',
|
|
11
12
|
labelColorClass,
|
|
12
|
-
isLabelRaised
|
|
13
|
-
? '-translate-y-1/2 bg-white text-xs'
|
|
14
|
-
: 'translate-y-4 text-sm',
|
|
13
|
+
isLabelRaised ? '-translate-y-1/2 bg-white text-xs' : 'translate-y-4',
|
|
15
14
|
)
|
|
16
15
|
"
|
|
17
|
-
:for="id"
|
|
18
|
-
class="pointer-events-none absolute left-3 origin-left px-1 transition-all duration-150 select-none"
|
|
19
16
|
>
|
|
20
|
-
|
|
21
|
-
|
|
17
|
+
<slot>
|
|
18
|
+
{{ label }}
|
|
19
|
+
</slot>
|
|
20
|
+
</UiLabel>
|
|
21
|
+
|
|
22
22
|
<textarea
|
|
23
23
|
v-if="isTextarea"
|
|
24
24
|
:id="id"
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
|
|
79
79
|
<div
|
|
80
80
|
v-if="
|
|
81
|
-
|
|
81
|
+
$slots.errors ||
|
|
82
82
|
status === 'error' ||
|
|
83
83
|
status === 'warning' ||
|
|
84
84
|
status === 'info'
|
|
@@ -86,19 +86,19 @@
|
|
|
86
86
|
:id="addonTextId"
|
|
87
87
|
:class="
|
|
88
88
|
cn(
|
|
89
|
-
'px-4 py-1 text-xs leading-normal font-medium transition-all duration-150 ease-in-out peer-aria-invalid:bg-alert-red-default peer-aria-invalid:text-white peer-
|
|
89
|
+
'px-4 py-1 text-xs leading-normal font-medium transition-all duration-150 ease-in-out peer-aria-invalid:bg-alert-red-default peer-aria-invalid:text-white peer-enabled:peer-aria-invalid:peer-hover:bg-alert-red-dark peer-enabled:peer-aria-invalid:peer-focus:bg-alert-red-dark',
|
|
90
90
|
addonClass,
|
|
91
91
|
)
|
|
92
92
|
"
|
|
93
93
|
>
|
|
94
|
-
<slot v-if="
|
|
94
|
+
<slot v-if="$slots.errors" name="errors" />
|
|
95
95
|
|
|
96
96
|
<template v-else>
|
|
97
97
|
{{ addonText }}
|
|
98
98
|
</template>
|
|
99
99
|
</div>
|
|
100
100
|
|
|
101
|
-
<slot name="buttons"
|
|
101
|
+
<slot name="buttons" />
|
|
102
102
|
<svg
|
|
103
103
|
v-if="chevron"
|
|
104
104
|
class="pointer-events-none absolute top-4 right-4 size-6 fill-current text-gray-900"
|
|
@@ -118,6 +118,7 @@ import { v4 as uuidv4 } from "uuid";
|
|
|
118
118
|
import { computed, onBeforeUpdate, onMounted, ref } from "vue";
|
|
119
119
|
|
|
120
120
|
import { cn } from "../../utils/cn.js";
|
|
121
|
+
import UiLabel from "../UiLabel/UiLabel.vue";
|
|
121
122
|
|
|
122
123
|
type UiInputStatus = "default" | "info" | "readonly" | "warning" | "error";
|
|
123
124
|
|
|
@@ -127,6 +128,13 @@ defineOptions({
|
|
|
127
128
|
|
|
128
129
|
const slots = defineSlots<{
|
|
129
130
|
buttons?: () => any;
|
|
131
|
+
/**
|
|
132
|
+
* Label content.
|
|
133
|
+
*/
|
|
134
|
+
default?: () => any;
|
|
135
|
+
/**
|
|
136
|
+
* Error content.
|
|
137
|
+
*/
|
|
130
138
|
errors?: () => any;
|
|
131
139
|
}>();
|
|
132
140
|
|
|
@@ -236,7 +244,7 @@ const addonClass = computed(() => {
|
|
|
236
244
|
readonly: "",
|
|
237
245
|
error: "",
|
|
238
246
|
warning:
|
|
239
|
-
"bg-orange-default text-gray-900 peer-hover:bg-orange-dark peer-focus:bg-orange-dark",
|
|
247
|
+
"bg-orange-default text-gray-900 peer-enabled:peer-hover:bg-orange-dark peer-focus:bg-orange-dark",
|
|
240
248
|
info: "bg-gray-300 text-gray-900",
|
|
241
249
|
}[status.value];
|
|
242
250
|
});
|
|
@@ -244,13 +252,13 @@ const addonClass = computed(() => {
|
|
|
244
252
|
const componentClass = computed(() => {
|
|
245
253
|
return {
|
|
246
254
|
default:
|
|
247
|
-
"border border-gray-300 p-4 text-gray-900 hover:border-gray-700 focus:border-2 focus:border-blue-default focus:p-inputFocused",
|
|
255
|
+
"border border-gray-300 p-4 text-gray-900 enabled:hover:border-gray-700 focus:border-2 focus:border-blue-default focus:p-inputFocused",
|
|
248
256
|
readonly: "p-4 text-gray-900 border border-gray-300 text-gray-800",
|
|
249
257
|
error:
|
|
250
|
-
"border-2 border-alert-red-default p-4 text-gray-900 hover:border-alert-red-dark focus:border-alert-red-dark",
|
|
258
|
+
"border-2 border-alert-red-default p-4 text-gray-900 enabled:hover:border-alert-red-dark focus:border-alert-red-dark",
|
|
251
259
|
warning:
|
|
252
|
-
"border-2 border-orange-default p-4 text-gray-900 hover:border-orange-dark focus:border-orange-dark",
|
|
253
|
-
info: "border border-gray-300 p-4 text-gray-900 hover:border-gray-700 focus:border-gray-700",
|
|
260
|
+
"border-2 border-orange-default p-4 text-gray-900 enabled:hover:border-orange-dark focus:border-orange-dark",
|
|
261
|
+
info: "border border-gray-300 p-4 text-gray-900 enabled:hover:border-gray-700 focus:border-gray-700",
|
|
254
262
|
}[status.value];
|
|
255
263
|
});
|
|
256
264
|
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# UiLabel
|
|
2
|
+
|
|
3
|
+
Wraps the native `label` element. Currently only used to provide some default styles for labels.
|
|
4
|
+
|
|
5
|
+
## Usage
|
|
6
|
+
|
|
7
|
+
**Associate with input via `id` attribute**:
|
|
8
|
+
|
|
9
|
+
```vue
|
|
10
|
+
<UiLabel for="name-input">
|
|
11
|
+
Name
|
|
12
|
+
</UiLabel>
|
|
13
|
+
|
|
14
|
+
<UiInput id="name-input" name="name" required />
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
**Associate with input by wrapping**:
|
|
18
|
+
|
|
19
|
+
```vue
|
|
20
|
+
<UiLabel>
|
|
21
|
+
Name
|
|
22
|
+
<UiInput name="name" required />
|
|
23
|
+
</UiLabel>
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
**Associate with checkbox**:
|
|
27
|
+
|
|
28
|
+
```vue
|
|
29
|
+
<UiLabel class="flex">
|
|
30
|
+
<UiCheckbox name="terms" required />
|
|
31
|
+
I have read and accept the terms and conditions
|
|
32
|
+
</UiLabel>
|
|
33
|
+
```
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<label :class="cn('max-w-max items-center text-sm', $attrs.class as string)">
|
|
3
|
+
<slot />
|
|
4
|
+
</label>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<script setup lang="ts">
|
|
8
|
+
import { cn } from "../../utils/cn.js";
|
|
9
|
+
|
|
10
|
+
defineSlots<{
|
|
11
|
+
/**
|
|
12
|
+
* Label content.
|
|
13
|
+
*/
|
|
14
|
+
default: () => any;
|
|
15
|
+
}>();
|
|
16
|
+
</script>
|
|
@@ -74,7 +74,12 @@
|
|
|
74
74
|
:grouped-options="groupedOptions"
|
|
75
75
|
>
|
|
76
76
|
<ul
|
|
77
|
-
v-if="
|
|
77
|
+
v-if="
|
|
78
|
+
Array.isArray(groupedOptions) &&
|
|
79
|
+
groupedOptions.some(
|
|
80
|
+
(groupedOption) => groupedOption.options.length > 0,
|
|
81
|
+
)
|
|
82
|
+
"
|
|
78
83
|
class="max-h-80 overflow-y-auto"
|
|
79
84
|
tabindex="0"
|
|
80
85
|
>
|
|
@@ -82,29 +87,32 @@
|
|
|
82
87
|
v-for="groupedOption in groupedOptions"
|
|
83
88
|
:key="groupedOption.groupLabel"
|
|
84
89
|
>
|
|
85
|
-
<
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
90
|
+
<template v-if="groupedOption.options.length > 0">
|
|
91
|
+
<li
|
|
92
|
+
v-if="groupedOption.groupLabel"
|
|
93
|
+
class="flex h-6 items-center border-t bg-gray-100 px-4 text-xs font-semibold tracking-wider text-gray-700 uppercase first:border-t-0"
|
|
94
|
+
>
|
|
95
|
+
{{ groupedOption.groupLabel }}
|
|
96
|
+
</li>
|
|
97
|
+
|
|
98
|
+
<UiListItem
|
|
99
|
+
v-for="(option, index) in groupedOption.options"
|
|
100
|
+
:key="`${groupedOption.groupLabel}-menuOptions-${index}`"
|
|
101
|
+
:selected="option.selected"
|
|
102
|
+
:selectable="listVariant === 'selectable'"
|
|
103
|
+
:is-checked="option.selected"
|
|
104
|
+
:check-box-menu="listVariant === 'checkbox'"
|
|
105
|
+
:icon-size="iconSize"
|
|
106
|
+
:image-shape="imageShape"
|
|
107
|
+
:image-src="option.imageSrc"
|
|
108
|
+
:checkbox-size="checkboxSize"
|
|
109
|
+
:check-box-color="checkboxColor"
|
|
110
|
+
class="hover:bg-gray-100 focus:bg-gray-300"
|
|
111
|
+
:data-testid="`menu-option-button-${index}`"
|
|
112
|
+
@list-item-click="selectOption(option)"
|
|
113
|
+
>{{ option.label }}
|
|
114
|
+
</UiListItem>
|
|
115
|
+
</template>
|
|
108
116
|
</template>
|
|
109
117
|
</ul>
|
|
110
118
|
<ul v-else class="max-h-60 overflow-y-auto" tabindex="0">
|
|
@@ -184,7 +192,7 @@ export type UiMenuSelectedOption<Value = unknown> = UiMenuOptionType<Value> & {
|
|
|
184
192
|
};
|
|
185
193
|
|
|
186
194
|
export type UiMenuGroupedOption<Value = unknown> = {
|
|
187
|
-
groupLabel
|
|
195
|
+
groupLabel?: string;
|
|
188
196
|
options: UiMenuOptionType<Value>[];
|
|
189
197
|
};
|
|
190
198
|
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
]"
|
|
10
10
|
>
|
|
11
11
|
<li v-for="option in internalOptions" :key="option.value">
|
|
12
|
-
<
|
|
12
|
+
<UiLabel class="flex">
|
|
13
13
|
<input
|
|
14
14
|
v-model="pickedOption"
|
|
15
15
|
:name="groupName"
|
|
@@ -22,11 +22,11 @@
|
|
|
22
22
|
/>
|
|
23
23
|
<span
|
|
24
24
|
class="ml-1 cursor-pointer"
|
|
25
|
-
:class="[labelClass, disabled ? 'text-gray-500' : '
|
|
25
|
+
:class="[labelClass, disabled ? 'text-gray-500' : '']"
|
|
26
26
|
>
|
|
27
27
|
{{ option.label }}
|
|
28
28
|
</span>
|
|
29
|
-
</
|
|
29
|
+
</UiLabel>
|
|
30
30
|
</li>
|
|
31
31
|
</ul>
|
|
32
32
|
</template>
|
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
import { computed } from "vue";
|
|
36
36
|
|
|
37
37
|
import { cn } from "../../utils/cn.js";
|
|
38
|
+
import UiLabel from "../UiLabel/UiLabel.vue";
|
|
38
39
|
|
|
39
40
|
export interface UiRadioInputGroupOption<T> {
|
|
40
41
|
value: T;
|
|
@@ -2,36 +2,36 @@
|
|
|
2
2
|
|
|
3
3
|
## Usage
|
|
4
4
|
|
|
5
|
-
```
|
|
5
|
+
```vue
|
|
6
6
|
<template>
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
7
|
+
<UiSearchInput
|
|
8
|
+
:has-add-entry-option="true"
|
|
9
|
+
:model-value="internalValue"
|
|
10
|
+
label="This is a Label"
|
|
11
|
+
placeholder="This is a placeholder"
|
|
12
|
+
@update:model-value="handleInput"
|
|
13
|
+
@handle-keypress="handleKeypress"
|
|
14
|
+
@blur="handleBlur"
|
|
15
|
+
/>
|
|
16
16
|
</template>
|
|
17
17
|
|
|
18
18
|
<script setup lang="ts">
|
|
19
|
-
|
|
19
|
+
import { UiSearchInput } from "./UiSearchInput.vue";
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
const internalValue = ref([""]);
|
|
22
|
+
function handleInput(newValue) {
|
|
23
|
+
internalValue.value = newValue;
|
|
24
|
+
}
|
|
25
25
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
}
|
|
26
|
+
function handleKeypress({ event, value }) {
|
|
27
|
+
if (event.key === 'Enter') {
|
|
28
|
+
// do something when enter key is pressed
|
|
30
29
|
}
|
|
30
|
+
}
|
|
31
31
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
32
|
+
function handleBlur(value) {
|
|
33
|
+
// value is the same as from handleInput
|
|
34
|
+
}
|
|
35
35
|
</script>
|
|
36
36
|
```
|
|
37
37
|
|
|
@@ -43,6 +43,12 @@
|
|
|
43
43
|
| `label` | `string` | `""` | Sets Label for the input field |
|
|
44
44
|
| `placeholder` | `string` | `Default placeholder` | Sets Placeholder attribute for the input |
|
|
45
45
|
|
|
46
|
+
### Slots
|
|
47
|
+
|
|
48
|
+
| Name | Description |
|
|
49
|
+
|-----------|---------------|
|
|
50
|
+
| `default` | Label content |
|
|
51
|
+
|
|
46
52
|
### Events
|
|
47
53
|
|
|
48
54
|
| Name | Type | Description |
|
|
@@ -10,7 +10,11 @@
|
|
|
10
10
|
v-if="hasLabel"
|
|
11
11
|
class="col-span-1 flex items-center pr-5 text-sm lg:py-2"
|
|
12
12
|
>
|
|
13
|
-
<
|
|
13
|
+
<UiLabel :for="id" class="font-medium">
|
|
14
|
+
<slot>
|
|
15
|
+
{{ label }}
|
|
16
|
+
</slot>
|
|
17
|
+
</UiLabel>
|
|
14
18
|
<slot name="tooltip"></slot>
|
|
15
19
|
</div>
|
|
16
20
|
|
|
@@ -21,6 +25,7 @@
|
|
|
21
25
|
>
|
|
22
26
|
<div class="flex items-center">
|
|
23
27
|
<input
|
|
28
|
+
:id="id"
|
|
24
29
|
ref="inputs"
|
|
25
30
|
:value="internalValue[index]"
|
|
26
31
|
type="text"
|
|
@@ -56,18 +61,33 @@
|
|
|
56
61
|
</template>
|
|
57
62
|
|
|
58
63
|
<script setup lang="ts">
|
|
59
|
-
import {
|
|
64
|
+
import { v4 as uuidv4 } from "uuid";
|
|
65
|
+
import { computed, nextTick, onBeforeUpdate, ref, watchEffect } from "vue";
|
|
60
66
|
|
|
61
67
|
import UiIconButton from "../UiIconButton/UiIconButton.vue";
|
|
68
|
+
import UiLabel from "../UiLabel/UiLabel.vue";
|
|
69
|
+
|
|
70
|
+
const slots = defineSlots<{
|
|
71
|
+
/**
|
|
72
|
+
* Label content.
|
|
73
|
+
*/
|
|
74
|
+
default?: () => any;
|
|
75
|
+
/**
|
|
76
|
+
* Tooltip content.
|
|
77
|
+
*/
|
|
78
|
+
tooltip?: () => any;
|
|
79
|
+
}>();
|
|
62
80
|
|
|
63
81
|
const props = withDefaults(
|
|
64
82
|
defineProps<{
|
|
83
|
+
id?: string;
|
|
65
84
|
hasAddEntryOption?: boolean;
|
|
66
85
|
label?: string;
|
|
67
86
|
modelValue: string[];
|
|
68
87
|
placeholder?: string;
|
|
69
88
|
}>(),
|
|
70
89
|
{
|
|
90
|
+
id: undefined,
|
|
71
91
|
hasAddEntryOption: false,
|
|
72
92
|
placeholder: "Default placeholder",
|
|
73
93
|
label: "",
|
|
@@ -89,6 +109,8 @@ const addRow = async () => {
|
|
|
89
109
|
}
|
|
90
110
|
};
|
|
91
111
|
|
|
112
|
+
const id = ref(props.id ?? `id-${uuidv4()}`);
|
|
113
|
+
|
|
92
114
|
const canAddRow = computed(() => {
|
|
93
115
|
return (
|
|
94
116
|
internalValue.value[internalValue.value.length - 1].length > 0 &&
|
|
@@ -131,9 +153,15 @@ function handleBlur() {
|
|
|
131
153
|
const isLastIndex = (index: number) => {
|
|
132
154
|
return index === internalValue.value.length - 1;
|
|
133
155
|
};
|
|
156
|
+
const hasDefaultSlot = ref(false);
|
|
157
|
+
|
|
158
|
+
// Manually tracks whether the “errors” slot is in use since `useSlots()` isn't reactive and so can't be correctly used inside computed reactive state.
|
|
159
|
+
onBeforeUpdate(() => {
|
|
160
|
+
hasDefaultSlot.value = "default" in slots;
|
|
161
|
+
});
|
|
134
162
|
|
|
135
163
|
const hasLabel = computed(() => {
|
|
136
|
-
return props.label.length > 0;
|
|
164
|
+
return hasDefaultSlot.value || props.label.length > 0;
|
|
137
165
|
});
|
|
138
166
|
|
|
139
167
|
const inputWrapperClass = computed(() => {
|