@bi-digital/react 0.11.8 → 0.11.9
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/dist/{alert-footer-HPrijrP2.d.mts → alert-footer-B0RXYXcM.d.mts} +57 -4
- package/dist/components/alert/alert-footer.d.mts +1 -1
- package/dist/components/alert/alert.d.mts +1 -1
- package/dist/components/alert/index.d.mts +1 -1
- package/dist/components/avatar/avatar.d.mts +1 -1
- package/dist/components/avatar/index.d.mts +1 -1
- package/dist/components/badge/badge.d.mts +1 -1
- package/dist/components/badge/index.d.mts +1 -1
- package/dist/components/button/button.d.mts +1 -1
- package/dist/components/button/index.d.mts +1 -1
- package/dist/components/card/card-action.d.mts +1 -1
- package/dist/components/card/card-actions.d.mts +1 -1
- package/dist/components/card/card-content.d.mts +1 -1
- package/dist/components/card/card-date.d.mts +1 -1
- package/dist/components/card/card-header.d.mts +1 -1
- package/dist/components/card/card-media.d.mts +1 -1
- package/dist/components/card/card.d.mts +1 -1
- package/dist/components/card/index.d.mts +1 -1
- package/dist/components/checkbox/checkbox-subsection.d.mts +1 -1
- package/dist/components/checkbox/checkbox.d.mts +1 -1
- package/dist/components/checkbox/index.d.mts +1 -1
- package/dist/components/chip/chip.d.mts +1 -1
- package/dist/components/chip/index.d.mts +1 -1
- package/dist/components/details/details-content.d.mts +1 -1
- package/dist/components/details/details-summary.d.mts +1 -1
- package/dist/components/details/details.d.mts +1 -1
- package/dist/components/details/index.d.mts +1 -1
- package/dist/components/dialog/dialog-close-button.d.mts +1 -1
- package/dist/components/dialog/dialog-content.d.mts +1 -1
- package/dist/components/dialog/dialog-footer.d.mts +1 -1
- package/dist/components/dialog/dialog-header.d.mts +1 -1
- package/dist/components/dialog/dialog-trigger.d.mts +1 -1
- package/dist/components/dialog/dialog.d.mts +1 -1
- package/dist/components/dialog/index.d.mts +1 -1
- package/dist/components/dropdown/dropdown-button.d.mts +1 -1
- package/dist/components/dropdown/dropdown-trigger-context.d.mts +1 -1
- package/dist/components/dropdown/dropdown-trigger.d.mts +1 -1
- package/dist/components/dropdown/dropdown.d.mts +1 -1
- package/dist/components/dropdown/index.d.mts +1 -1
- package/dist/components/field/field-affix.d.mts +1 -1
- package/dist/components/field/field-description.d.mts +1 -1
- package/dist/components/field/field.d.mts +1 -1
- package/dist/components/field/index.d.mts +1 -1
- package/dist/components/fieldset/fieldset-description.d.mts +1 -1
- package/dist/components/fieldset/fieldset-legend.d.mts +1 -1
- package/dist/components/fieldset/fieldset.d.mts +1 -1
- package/dist/components/fieldset/index.d.mts +1 -1
- package/dist/components/filter-group/filter-group.d.mts +1 -1
- package/dist/components/filter-group/index.d.mts +1 -1
- package/dist/components/footer/footer.d.mts +1 -1
- package/dist/components/footer/index.d.mts +1 -1
- package/dist/components/index.d.mts +2 -2
- package/dist/components/index.mjs +3 -1
- package/dist/components/input/index.d.mts +1 -1
- package/dist/components/input/input.d.mts +1 -1
- package/dist/components/label/index.d.mts +1 -1
- package/dist/components/label/label.d.mts +1 -1
- package/dist/components/link/index.d.mts +1 -1
- package/dist/components/link/link.d.mts +1 -1
- package/dist/components/logo/index.d.mts +1 -1
- package/dist/components/logo/logo.d.mts +1 -1
- package/dist/components/logo/logo.mjs +2 -1
- package/dist/components/logo/logo.mjs.map +1 -1
- package/dist/components/navbar/index.d.mts +1 -1
- package/dist/components/navbar/navbar.d.mts +1 -1
- package/dist/components/navbar/sub-navbar.d.mts +1 -1
- package/dist/components/pagination/index.d.mts +1 -1
- package/dist/components/pagination/pagination-button.d.mts +1 -1
- package/dist/components/pagination/pagination.d.mts +1 -1
- package/dist/components/popover/index.d.mts +1 -1
- package/dist/components/popover/popover-trigger.d.mts +1 -1
- package/dist/components/popover/popover.d.mts +1 -1
- package/dist/components/radio/index.d.mts +1 -1
- package/dist/components/radio/radio.d.mts +1 -1
- package/dist/components/search/index.d.mts +1 -1
- package/dist/components/search/search.d.mts +1 -1
- package/dist/components/select/index.d.mts +1 -1
- package/dist/components/select/select-optgroup.d.mts +1 -1
- package/dist/components/select/select-option.d.mts +1 -1
- package/dist/components/select/select.d.mts +1 -1
- package/dist/components/selectfield/index.d.mts +1 -1
- package/dist/components/selectfield/selectfield.d.mts +1 -1
- package/dist/components/skip-link/index.d.mts +1 -1
- package/dist/components/skip-link/skip-link.d.mts +1 -1
- package/dist/components/spinner/index.d.mts +1 -1
- package/dist/components/spinner/spinner.d.mts +1 -1
- package/dist/components/switch/index.d.mts +1 -1
- package/dist/components/switch/switch.d.mts +1 -1
- package/dist/components/tabs/index.d.mts +1 -1
- package/dist/components/tabs/tab.d.mts +1 -1
- package/dist/components/tabs/tabs-list.d.mts +1 -1
- package/dist/components/tabs/tabs-panel.d.mts +1 -1
- package/dist/components/tabs/tabs.d.mts +1 -1
- package/dist/components/textarea/index.d.mts +1 -1
- package/dist/components/textarea/textarea.d.mts +1 -1
- package/dist/components/textfield/index.d.mts +1 -1
- package/dist/components/textfield/textfield.d.mts +1 -1
- package/dist/components/tooltip/index.d.mts +2 -0
- package/dist/components/tooltip/index.mjs +2 -0
- package/dist/components/tooltip/tooltip.d.mts +2 -0
- package/dist/components/tooltip/tooltip.mjs +36 -0
- package/dist/components/tooltip/tooltip.mjs.map +1 -0
- package/dist/components/validation-message/index.d.mts +1 -1
- package/dist/components/validation-message/validation-message.d.mts +1 -1
- package/dist/index-Dc-SdpIe.d.mts +1 -0
- package/dist/main.d.mts +6 -6
- package/dist/main.mjs +2 -1
- package/dist/{types-CgAV-Uiu.d.mts → types-74lJC5tL.d.mts} +1 -1
- package/dist/{useIsElementAboveViewport-DmYCeDwm.d.mts → useIsElementAboveViewport-Cxt9TwLS.d.mts} +1 -1
- package/dist/{useMediaQuery-Cz0DvE8S.d.mts → useMediaQuery-Di0fXraw.d.mts} +1 -1
- package/dist/{useScrollDirection-CepdY5lA.d.mts → useScrollDirection-6pq5a8B3.d.mts} +1 -1
- package/dist/utilities/hooks/index.d.mts +4 -4
- package/dist/utilities/hooks/useIsElementAboveViewport/useIsElementAboveViewport.d.mts +1 -1
- package/dist/utilities/hooks/useMediaQuery/useMediaQuery.d.mts +1 -1
- package/dist/utilities/hooks/usePagination/usePagination.d.mts +1 -1
- package/dist/utilities/hooks/useScrollDirection/useScrollDirection.d.mts +1 -1
- package/dist/utilities/index.d.mts +5 -5
- package/dist/utilities/types.d.mts +1 -1
- package/dist/vanilla/index.mjs +1 -0
- package/dist/vanilla/tooltip/index.d.mts +1 -0
- package/dist/vanilla/tooltip/index.mjs +11 -0
- package/dist/vanilla/tooltip/index.mjs.map +1 -0
- package/package.json +4 -4
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { B as RadioProps, z as Radio } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Radio, RadioProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { L as Search, R as SearchProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Search, SearchProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { L as Search, R as SearchProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Search, SearchProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { F as Select, I as SelectProps, M as SelectOptgroupProps, N as SelectOption, P as SelectOptionProps, j as SelectOptgroup } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Select, SelectOptgroup, SelectOptgroupProps, SelectOption, SelectOptionProps, SelectProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { M as SelectOptgroupProps, j as SelectOptgroup } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { SelectOptgroup, SelectOptgroupProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { N as SelectOption, P as SelectOptionProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { SelectOption, SelectOptionProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { F as Select, I as SelectProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Select, SelectProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { A as SelectfieldProps, k as Selectfield } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Selectfield, SelectfieldProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { A as SelectfieldProps, k as Selectfield } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Selectfield, SelectfieldProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { D as SkipLink, O as SkipLinkProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { SkipLink, SkipLinkProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { D as SkipLink, O as SkipLinkProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { SkipLink, SkipLinkProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { E as SpinnerProps, T as Spinner } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Spinner, SpinnerProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { E as SpinnerProps, T as Spinner } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Spinner, SpinnerProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { C as Switch, w as SwitchProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Switch, SwitchProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { C as Switch, w as SwitchProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Switch, SwitchProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { S as TabsProps, _ as Tab, b as Tabs, g as TabsListProps, h as TabsList, m as TabsPanelProps, p as TabsPanel, v as TabProps, x as TabsContext } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Tab, TabProps, Tabs, TabsContext, TabsList, TabsListProps, TabsPanel, TabsPanelProps, TabsProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { _ as Tab, v as TabProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Tab, TabProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { g as TabsListProps, h as TabsList } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { TabsList, TabsListProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { m as TabsPanelProps, p as TabsPanel } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { TabsPanel, TabsPanelProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { S as TabsProps, b as Tabs, x as TabsContext, y as Context } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Context, Tabs, TabsContext, TabsProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { d as Textarea, f as TextareaProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Textarea, TextareaProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { d as Textarea, f as TextareaProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Textarea, TextareaProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { l as Textfield, u as TextfieldProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Textfield, TextfieldProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { l as Textfield, u as TextfieldProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { Textfield, TextfieldProps };
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import "../../vanilla/tooltip/index.mjs";
|
|
2
|
+
import "@digdir/designsystemet-web";
|
|
3
|
+
import { Slot } from "@radix-ui/react-slot";
|
|
4
|
+
import { jsx } from "react/jsx-runtime";
|
|
5
|
+
//#region src/components/tooltip/tooltip.tsx
|
|
6
|
+
/**
|
|
7
|
+
* Tooltip component that displays a small piece of information on hover or focus.
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* <Tooltip content='This is the tooltip content'>
|
|
11
|
+
* <button>Hover me</button>
|
|
12
|
+
* </Tooltip>
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* <Tooltip content='This is the tooltip content'>
|
|
16
|
+
* Hover me
|
|
17
|
+
* </Tooltip>
|
|
18
|
+
*/
|
|
19
|
+
const Tooltip = ({ children, content, placement = "top", disableAutoPlacement = false, ref, ...props }) => {
|
|
20
|
+
return /* @__PURE__ */ jsx(Slot, {
|
|
21
|
+
"data-tooltip": content,
|
|
22
|
+
"data-placement": placement,
|
|
23
|
+
"data-autoplacement": !disableAutoPlacement,
|
|
24
|
+
suppressHydrationWarning: true,
|
|
25
|
+
ref,
|
|
26
|
+
...props,
|
|
27
|
+
children: typeof children === "string" ? /* @__PURE__ */ jsx("span", {
|
|
28
|
+
tabIndex: 0,
|
|
29
|
+
children
|
|
30
|
+
}) : children
|
|
31
|
+
});
|
|
32
|
+
};
|
|
33
|
+
//#endregion
|
|
34
|
+
export { Tooltip };
|
|
35
|
+
|
|
36
|
+
//# sourceMappingURL=tooltip.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tooltip.mjs","names":[],"sources":["../../../src/components/tooltip/tooltip.tsx"],"sourcesContent":["import { Slot } from '@radix-ui/react-slot';\nimport '@digdir/designsystemet-web'; // Import ds-tooltip functionality\nimport type { HTMLAttributes, ReactElement, Ref, RefAttributes } from 'react';\nimport type { Placement } from '@floating-ui/dom';\nimport type { MergeRight } from '../../utilities';\nimport '../../vanilla/tooltip';\n\nexport type TooltipProps = MergeRight<\n HTMLAttributes<HTMLSpanElement>,\n {\n /**\n * The element or string that triggers the tooltip.\n *\n * Note: If it is a string, it will be wrapped in a span.\n * Note: If it is an element, it must be able to receive a ref.\n */\n children: (ReactElement & RefAttributes<HTMLSpanElement>) | string;\n /**\n * Content of the tooltip\n **/\n content: string;\n /**\n * Placement of the tooltip on the trigger.\n * @default 'top'\n */\n placement?: Placement;\n /**\n * Whether to disable auto placement.\n * @default false\n */\n disableAutoPlacement?: boolean;\n ref?: Ref<HTMLSpanElement>;\n }\n>;\n\n/**\n * Tooltip component that displays a small piece of information on hover or focus.\n *\n * @example\n * <Tooltip content='This is the tooltip content'>\n * <button>Hover me</button>\n * </Tooltip>\n *\n * @example\n * <Tooltip content='This is the tooltip content'>\n * Hover me\n * </Tooltip>\n */\nexport const Tooltip = ({\n children,\n content,\n placement = 'top',\n disableAutoPlacement = false,\n ref,\n ...props\n}: TooltipProps) => {\n return (\n <Slot\n data-tooltip={content}\n data-placement={placement}\n data-autoplacement={!disableAutoPlacement}\n suppressHydrationWarning // Since data-tooltip adds aria-label/aria-description\n ref={ref}\n {...props}\n >\n {/* oxlint-disable-next-line jsx-a11y/no-noninteractive-tabindex */}\n {typeof children === 'string' ? <span tabIndex={0}>{children}</span> : children}\n </Slot>\n );\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;AAgDA,MAAa,WAAW,EACtB,UACA,SACA,YAAY,OACZ,uBAAuB,OACvB,KACA,GAAG,YACe;CAClB,OACE,oBAAC,MAAD;EACE,gBAAc;EACd,kBAAgB;EAChB,sBAAoB,CAAC;EACrB,0BAAA;EACK;EACL,GAAI;YAGH,OAAO,aAAa,WAAW,oBAAC,QAAD;GAAM,UAAU;GAAI;GAAgB,CAAA,GAAG;EAClE,CAAA"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as ValidationMessage, o as ValidationMessageProps } from "../../alert-footer-
|
|
1
|
+
import { a as ValidationMessage, o as ValidationMessageProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { ValidationMessage, ValidationMessageProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as ValidationMessage, o as ValidationMessageProps } from "../../alert-footer-
|
|
1
|
+
import { a as ValidationMessage, o as ValidationMessageProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { ValidationMessage, ValidationMessageProps };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { };
|
package/dist/main.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { r as useCheckboxGroup, t as UseCheckboxGroupOptions } from "./useCheckboxGroup-Boc_tLJ3.mjs";
|
|
2
2
|
import { t as useIsomorphicLayoutEffect } from "./useIsomorphicLayoutEffect-DXCY5AxR.mjs";
|
|
3
|
-
import { $ as
|
|
3
|
+
import { $ as Footer, $t as Checkbox, A as SelectfieldProps, At as PopoverProps, B as RadioProps, Bt as DialogContentProps, C as Switch, Cn as Alert, Ct as DropdownButton, D as SkipLink, Dt as PopoverTrigger, E as SpinnerProps, Et as DropdownProps, F as Select, Ft as DialogFooter, G as SubNavbar, Gt as DetailsContent, H as PaginationButtonProps, Ht as DialogProps, I as SelectProps, It as DialogFooterProps, J as NavbarProps, Jt as DetailsProps, K as SubNavbarProps, Kt as DetailsContentProps, L as Search, Lt as DialogHeader, M as SelectOptgroupProps, Mt as DialogCloseButtonProps, N as SelectOption, Nt as DialogTrigger, O as SkipLinkProps, Ot as PopoverTriggerProps, P as SelectOptionProps, Pt as DialogTriggerProps, Q as LinkProps, Qt as CheckboxSubsectionProps, R as SearchProps, Rt as DialogHeaderProps, S as TabsProps, Sn as AvatarProps, St as DropdownTriggerProps, T as Spinner, Tt as Dropdown, U as Pagination, Ut as DetailsSummary, V as PaginationButton, Vt as Dialog, W as PaginationProps, Wt as DetailsSummaryProps, X as LogoProps, Xt as ChipProps, Y as Logo, Yt as Chip, Z as Link, Zt as CheckboxSubsection, _ as Tab, _n as Button, _t as Field, a as ValidationMessage, an as CardMedia, at as Label, b as Tabs, bn as BadgeProps, bt as DropdownTriggerContextProps, c as TooltipProps, cn as CardHeaderProps, ct as FieldsetDescriptionProps, d as Textarea, dn as CardAction, dt as FieldAffix, en as CheckboxProps, et as FooterProps, f as TextareaProps, fn as CardActionProps, ft as FieldAffixProps, g as TabsListProps, gn as CardProps, gt as FieldDescriptionProps, h as TabsList, hn as Card, ht as FieldDescription, i as usePagination, in as CardDateProps, it as FieldsetLegendProps, j as SelectOptgroup, jt as DialogCloseButton, k as Selectfield, kt as Popover, l as Textfield, ln as CardContent, lt as Fieldset, m as TabsPanelProps, mn as CardActionsProps, mt as FieldAffixesProps, n as AlertFooterProps, nn as InputProps, nt as FilterGroupProps, o as ValidationMessageProps, on as CardMediaProps, ot as LabelProps, p as TabsPanel, pn as CardActions, pt as FieldAffixes, q as Navbar, qt as Details, r as UsePaginationProps, rn as CardDate, rt as FieldsetLegend, s as Tooltip, sn as CardHeader, st as FieldsetDescription, t as AlertFooter, tn as Input, tt as FilterGroup, u as TextfieldProps, un as CardContentProps, ut as FieldsetProps, v as TabProps, vn as ButtonProps, vt as FieldProps, w as SwitchProps, wn as AlertProps, wt as DropdownButtonProps, x as TabsContext, xn as Avatar, xt as DropdownTrigger, yn as Badge, yt as DropdownTriggerContext, z as Radio, zt as DialogContent } from "./alert-footer-B0RXYXcM.mjs";
|
|
4
4
|
import { n as DialogTriggerContext, r as DialogTriggerContextProps, t as Context } from "./dialog-trigger-context-DbUhxoNL.mjs";
|
|
5
5
|
import { n as PopoverTriggerContext, r as PopoverTriggerContextProps } from "./popover-trigger-context-BLjAozBn.mjs";
|
|
6
6
|
import { n as DropdownItemProps, t as DropdownItem } from "./dropdown-item-bA64wFOZ.mjs";
|
|
@@ -8,8 +8,8 @@ import { n as DropdownListProps, t as DropdownList } from "./dropdown-list-CaYz-
|
|
|
8
8
|
import { n as FooterLinksProps, t as FooterLinks } from "./footer-links-DwBghNrz.mjs";
|
|
9
9
|
import { n as PaginationItemProps, t as PaginationItem } from "./pagination-item-DJicBrIN.mjs";
|
|
10
10
|
import { n as StickyHeaderProps, t as StickyHeader } from "./sticky-header-CVfE0TUC.mjs";
|
|
11
|
-
import { t as useIsElementAboveViewport } from "./useIsElementAboveViewport-
|
|
12
|
-
import { t as useScrollDirection } from "./useScrollDirection-
|
|
13
|
-
import { n as useMediaQuery, t as UseMediaQueryOptions } from "./useMediaQuery-
|
|
14
|
-
import { t as MergeRight } from "./types-
|
|
15
|
-
export { Alert, AlertFooter, AlertFooterProps, AlertProps, Avatar, AvatarProps, Badge, BadgeProps, Button, ButtonProps, Card, CardAction, CardActionProps, CardActions, CardActionsProps, CardContent, CardContentProps, CardDate, CardDateProps, CardHeader, CardHeaderProps, CardMedia, CardMediaProps, CardProps, Checkbox, CheckboxProps, CheckboxSubsection, CheckboxSubsectionProps, Chip, ChipProps, Context, Details, DetailsContent, DetailsContentProps, DetailsProps, DetailsSummary, DetailsSummaryProps, Dialog, DialogCloseButton, DialogCloseButtonProps, DialogContent, DialogContentProps, DialogFooter, DialogFooterProps, DialogHeader, DialogHeaderProps, DialogProps, DialogTrigger, DialogTriggerContext, DialogTriggerContextProps, DialogTriggerProps, Dropdown, DropdownButton, DropdownButtonProps, DropdownItem, DropdownItemProps, DropdownList, DropdownListProps, DropdownProps, DropdownTrigger, DropdownTriggerContext, DropdownTriggerContextProps, DropdownTriggerProps, Field, FieldAffix, FieldAffixProps, FieldAffixes, FieldAffixesProps, FieldDescription, FieldDescriptionProps, FieldProps, Fieldset, FieldsetDescription, FieldsetDescriptionProps, FieldsetLegend, FieldsetLegendProps, FieldsetProps, FilterGroup, FilterGroupProps, Footer, FooterLinks, FooterLinksProps, FooterProps, Input, InputProps, Label, LabelProps, Link, LinkProps, Logo, LogoProps, MergeRight, Navbar, NavbarProps, Pagination, PaginationButton, PaginationButtonProps, PaginationItem, PaginationItemProps, PaginationProps, Popover, PopoverProps, PopoverTrigger, PopoverTriggerContext, PopoverTriggerContextProps, PopoverTriggerProps, Radio, RadioProps, Search, SearchProps, Select, SelectOptgroup, SelectOptgroupProps, SelectOption, SelectOptionProps, SelectProps, Selectfield, SelectfieldProps, SkipLink, SkipLinkProps, Spinner, SpinnerProps, StickyHeader, StickyHeaderProps, SubNavbar, SubNavbarProps, Switch, SwitchProps, Tab, TabProps, Tabs, TabsContext, TabsList, TabsListProps, TabsPanel, TabsPanelProps, TabsProps, Textarea, TextareaProps, Textfield, TextfieldProps, UseCheckboxGroupOptions, UseMediaQueryOptions, UsePaginationProps, ValidationMessage, ValidationMessageProps, useCheckboxGroup, useIsElementAboveViewport, useIsomorphicLayoutEffect, useMediaQuery, usePagination, useScrollDirection };
|
|
11
|
+
import { t as useIsElementAboveViewport } from "./useIsElementAboveViewport-Cxt9TwLS.mjs";
|
|
12
|
+
import { t as useScrollDirection } from "./useScrollDirection-6pq5a8B3.mjs";
|
|
13
|
+
import { n as useMediaQuery, t as UseMediaQueryOptions } from "./useMediaQuery-Di0fXraw.mjs";
|
|
14
|
+
import { t as MergeRight } from "./types-74lJC5tL.mjs";
|
|
15
|
+
export { Alert, AlertFooter, AlertFooterProps, AlertProps, Avatar, AvatarProps, Badge, BadgeProps, Button, ButtonProps, Card, CardAction, CardActionProps, CardActions, CardActionsProps, CardContent, CardContentProps, CardDate, CardDateProps, CardHeader, CardHeaderProps, CardMedia, CardMediaProps, CardProps, Checkbox, CheckboxProps, CheckboxSubsection, CheckboxSubsectionProps, Chip, ChipProps, Context, Details, DetailsContent, DetailsContentProps, DetailsProps, DetailsSummary, DetailsSummaryProps, Dialog, DialogCloseButton, DialogCloseButtonProps, DialogContent, DialogContentProps, DialogFooter, DialogFooterProps, DialogHeader, DialogHeaderProps, DialogProps, DialogTrigger, DialogTriggerContext, DialogTriggerContextProps, DialogTriggerProps, Dropdown, DropdownButton, DropdownButtonProps, DropdownItem, DropdownItemProps, DropdownList, DropdownListProps, DropdownProps, DropdownTrigger, DropdownTriggerContext, DropdownTriggerContextProps, DropdownTriggerProps, Field, FieldAffix, FieldAffixProps, FieldAffixes, FieldAffixesProps, FieldDescription, FieldDescriptionProps, FieldProps, Fieldset, FieldsetDescription, FieldsetDescriptionProps, FieldsetLegend, FieldsetLegendProps, FieldsetProps, FilterGroup, FilterGroupProps, Footer, FooterLinks, FooterLinksProps, FooterProps, Input, InputProps, Label, LabelProps, Link, LinkProps, Logo, LogoProps, MergeRight, Navbar, NavbarProps, Pagination, PaginationButton, PaginationButtonProps, PaginationItem, PaginationItemProps, PaginationProps, Popover, PopoverProps, PopoverTrigger, PopoverTriggerContext, PopoverTriggerContextProps, PopoverTriggerProps, Radio, RadioProps, Search, SearchProps, Select, SelectOptgroup, SelectOptgroupProps, SelectOption, SelectOptionProps, SelectProps, Selectfield, SelectfieldProps, SkipLink, SkipLinkProps, Spinner, SpinnerProps, StickyHeader, StickyHeaderProps, SubNavbar, SubNavbarProps, Switch, SwitchProps, Tab, TabProps, Tabs, TabsContext, TabsList, TabsListProps, TabsPanel, TabsPanelProps, TabsProps, Textarea, TextareaProps, Textfield, TextfieldProps, Tooltip, TooltipProps, UseCheckboxGroupOptions, UseMediaQueryOptions, UsePaginationProps, ValidationMessage, ValidationMessageProps, useCheckboxGroup, useIsElementAboveViewport, useIsomorphicLayoutEffect, useMediaQuery, usePagination, useScrollDirection };
|
package/dist/main.mjs
CHANGED
|
@@ -73,6 +73,7 @@ import { TabsList } from "./components/tabs/tabs-list.mjs";
|
|
|
73
73
|
import { TabsPanel } from "./components/tabs/tabs-panel.mjs";
|
|
74
74
|
import { Textarea } from "./components/textarea/textarea.mjs";
|
|
75
75
|
import { Textfield } from "./components/textfield/textfield.mjs";
|
|
76
|
+
import { Tooltip } from "./components/tooltip/tooltip.mjs";
|
|
76
77
|
import "./components/index.mjs";
|
|
77
78
|
import "./utilities/index.mjs";
|
|
78
|
-
export { Alert, AlertFooter, Avatar, Badge, Button, Card, CardAction, CardActions, CardContent, CardDate, CardHeader, CardMedia, Checkbox, CheckboxSubsection, Chip, Details, DetailsContent, DetailsSummary, Dialog, DialogCloseButton, DialogContent, DialogFooter, DialogHeader, DialogTrigger, DialogTriggerContext, Dropdown, DropdownButton, DropdownItem, DropdownList, DropdownTrigger, DropdownTriggerContext, Field, FieldAffix, FieldAffixes, FieldDescription, Fieldset, FieldsetDescription, FieldsetLegend, FilterGroup, Footer, FooterLinks, Input, Label, Link, Logo, Navbar, Pagination, PaginationButton, PaginationItem, Popover, PopoverTrigger, PopoverTriggerContext, Radio, Search, Select, SelectOptgroup, SelectOption, Selectfield, SkipLink, Spinner, StickyHeader, SubNavbar, Switch, Tab, Tabs, TabsList, TabsPanel, Textarea, Textfield, ValidationMessage, useCheckboxGroup, useIsElementAboveViewport, useIsomorphicLayoutEffect, useMediaQuery, usePagination, useScrollDirection };
|
|
79
|
+
export { Alert, AlertFooter, Avatar, Badge, Button, Card, CardAction, CardActions, CardContent, CardDate, CardHeader, CardMedia, Checkbox, CheckboxSubsection, Chip, Details, DetailsContent, DetailsSummary, Dialog, DialogCloseButton, DialogContent, DialogFooter, DialogHeader, DialogTrigger, DialogTriggerContext, Dropdown, DropdownButton, DropdownItem, DropdownList, DropdownTrigger, DropdownTriggerContext, Field, FieldAffix, FieldAffixes, FieldDescription, Fieldset, FieldsetDescription, FieldsetLegend, FilterGroup, Footer, FooterLinks, Input, Label, Link, Logo, Navbar, Pagination, PaginationButton, PaginationItem, Popover, PopoverTrigger, PopoverTriggerContext, Radio, Search, Select, SelectOptgroup, SelectOption, Selectfield, SkipLink, Spinner, StickyHeader, SubNavbar, Switch, Tab, Tabs, TabsList, TabsPanel, Textarea, Textfield, Tooltip, ValidationMessage, useCheckboxGroup, useIsElementAboveViewport, useIsomorphicLayoutEffect, useMediaQuery, usePagination, useScrollDirection };
|
package/dist/{useIsElementAboveViewport-DmYCeDwm.d.mts → useIsElementAboveViewport-Cxt9TwLS.d.mts}
RENAMED
|
@@ -5,4 +5,4 @@ import { RefObject } from "react";
|
|
|
5
5
|
declare const useIsElementAboveViewport: (elementRef: RefObject<HTMLElement | null>) => boolean;
|
|
6
6
|
//#endregion
|
|
7
7
|
export { useIsElementAboveViewport as t };
|
|
8
|
-
//# sourceMappingURL=useIsElementAboveViewport-
|
|
8
|
+
//# sourceMappingURL=useIsElementAboveViewport-Cxt9TwLS.d.mts.map
|
|
@@ -29,4 +29,4 @@ declare function useMediaQuery(query: string, {
|
|
|
29
29
|
}?: UseMediaQueryOptions): boolean;
|
|
30
30
|
//#endregion
|
|
31
31
|
export { useMediaQuery as n, UseMediaQueryOptions as t };
|
|
32
|
-
//# sourceMappingURL=useMediaQuery-
|
|
32
|
+
//# sourceMappingURL=useMediaQuery-Di0fXraw.d.mts.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as useCheckboxGroup, t as UseCheckboxGroupOptions } from "../../useCheckboxGroup-Boc_tLJ3.mjs";
|
|
2
2
|
import { t as useIsomorphicLayoutEffect } from "../../useIsomorphicLayoutEffect-DXCY5AxR.mjs";
|
|
3
|
-
import { i as usePagination, r as UsePaginationProps } from "../../alert-footer-
|
|
4
|
-
import { t as useIsElementAboveViewport } from "../../useIsElementAboveViewport-
|
|
5
|
-
import { t as useScrollDirection } from "../../useScrollDirection-
|
|
6
|
-
import { n as useMediaQuery, t as UseMediaQueryOptions } from "../../useMediaQuery-
|
|
3
|
+
import { i as usePagination, r as UsePaginationProps } from "../../alert-footer-B0RXYXcM.mjs";
|
|
4
|
+
import { t as useIsElementAboveViewport } from "../../useIsElementAboveViewport-Cxt9TwLS.mjs";
|
|
5
|
+
import { t as useScrollDirection } from "../../useScrollDirection-6pq5a8B3.mjs";
|
|
6
|
+
import { n as useMediaQuery, t as UseMediaQueryOptions } from "../../useMediaQuery-Di0fXraw.mjs";
|
|
7
7
|
export { UseCheckboxGroupOptions, UseMediaQueryOptions, UsePaginationProps, useCheckboxGroup, useIsElementAboveViewport, useIsomorphicLayoutEffect, useMediaQuery, usePagination, useScrollDirection };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as useIsElementAboveViewport } from "../../../useIsElementAboveViewport-
|
|
1
|
+
import { t as useIsElementAboveViewport } from "../../../useIsElementAboveViewport-Cxt9TwLS.mjs";
|
|
2
2
|
export { useIsElementAboveViewport };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as useMediaQuery, t as UseMediaQueryOptions } from "../../../useMediaQuery-
|
|
1
|
+
import { n as useMediaQuery, t as UseMediaQueryOptions } from "../../../useMediaQuery-Di0fXraw.mjs";
|
|
2
2
|
export { UseMediaQueryOptions, useMediaQuery };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { i as usePagination, r as UsePaginationProps } from "../../../alert-footer-
|
|
1
|
+
import { i as usePagination, r as UsePaginationProps } from "../../../alert-footer-B0RXYXcM.mjs";
|
|
2
2
|
export { UsePaginationProps, usePagination };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as useScrollDirection } from "../../../useScrollDirection-
|
|
1
|
+
import { t as useScrollDirection } from "../../../useScrollDirection-6pq5a8B3.mjs";
|
|
2
2
|
export { useScrollDirection };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as useCheckboxGroup, t as UseCheckboxGroupOptions } from "../useCheckboxGroup-Boc_tLJ3.mjs";
|
|
2
2
|
import { t as useIsomorphicLayoutEffect } from "../useIsomorphicLayoutEffect-DXCY5AxR.mjs";
|
|
3
|
-
import { i as usePagination, r as UsePaginationProps } from "../alert-footer-
|
|
4
|
-
import { t as useIsElementAboveViewport } from "../useIsElementAboveViewport-
|
|
5
|
-
import { t as useScrollDirection } from "../useScrollDirection-
|
|
6
|
-
import { n as useMediaQuery, t as UseMediaQueryOptions } from "../useMediaQuery-
|
|
7
|
-
import { t as MergeRight } from "../types-
|
|
3
|
+
import { i as usePagination, r as UsePaginationProps } from "../alert-footer-B0RXYXcM.mjs";
|
|
4
|
+
import { t as useIsElementAboveViewport } from "../useIsElementAboveViewport-Cxt9TwLS.mjs";
|
|
5
|
+
import { t as useScrollDirection } from "../useScrollDirection-6pq5a8B3.mjs";
|
|
6
|
+
import { n as useMediaQuery, t as UseMediaQueryOptions } from "../useMediaQuery-Di0fXraw.mjs";
|
|
7
|
+
import { t as MergeRight } from "../types-74lJC5tL.mjs";
|
|
8
8
|
export { MergeRight, UseCheckboxGroupOptions, UseMediaQueryOptions, UsePaginationProps, useCheckboxGroup, useIsElementAboveViewport, useIsomorphicLayoutEffect, useMediaQuery, usePagination, useScrollDirection };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as MergeRight } from "../types-
|
|
1
|
+
import { t as MergeRight } from "../types-74lJC5tL.mjs";
|
|
2
2
|
export { MergeRight };
|
package/dist/vanilla/index.mjs
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { setTooltipElement } from "@digdir/designsystemet-web";
|
|
2
|
+
//#region src/vanilla/tooltip/index.ts
|
|
3
|
+
if (typeof window !== "undefined") {
|
|
4
|
+
const biTooltip = document.createElement("div");
|
|
5
|
+
biTooltip.className = "bi-tooltip";
|
|
6
|
+
setTooltipElement(biTooltip);
|
|
7
|
+
}
|
|
8
|
+
//#endregion
|
|
9
|
+
export {};
|
|
10
|
+
|
|
11
|
+
//# sourceMappingURL=index.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","names":[],"sources":["../../../src/vanilla/tooltip/index.ts"],"sourcesContent":["import { setTooltipElement } from '@digdir/designsystemet-web';\n\nif (typeof window !== 'undefined') {\n const biTooltip = document.createElement('div');\n biTooltip.className = 'bi-tooltip';\n setTooltipElement(biTooltip);\n}\n"],"mappings":";;AAEA,IAAI,OAAO,WAAW,aAAa;CACjC,MAAM,YAAY,SAAS,cAAc,MAAM;CAC/C,UAAU,YAAY;CACtB,kBAAkB,UAAU"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bi-digital/react",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.11.
|
|
4
|
+
"version": "0.11.9",
|
|
5
5
|
"description": "React components from BI Digital",
|
|
6
6
|
"author": "BI Digital",
|
|
7
7
|
"homepage": "https://designsystem.bi.no/",
|
|
@@ -38,14 +38,14 @@
|
|
|
38
38
|
"@radix-ui/react-slot": "^1.2.4",
|
|
39
39
|
"@radix-ui/react-use-controllable-state": "^1.2.2",
|
|
40
40
|
"clsx": "^2.1.1",
|
|
41
|
-
"@bi-digital/icons": "0.11.
|
|
41
|
+
"@bi-digital/icons": "0.11.9"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
44
|
"@types/react": "^19.2.14",
|
|
45
45
|
"@types/react-dom": "^19.2.3",
|
|
46
46
|
"@vitest/browser-playwright": "^4.1.4",
|
|
47
47
|
"@vitest/coverage-v8": "^4.1.4",
|
|
48
|
-
"@vitest/expect": "^4.1.
|
|
48
|
+
"@vitest/expect": "^4.1.7",
|
|
49
49
|
"playwright": "^1.60.0",
|
|
50
50
|
"react": "^19.2.0",
|
|
51
51
|
"react-dom": "^19.2.0",
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
"peerDependencies": {
|
|
57
57
|
"react": "^19",
|
|
58
58
|
"react-dom": "^19",
|
|
59
|
-
"@bi-digital/css": "0.11.
|
|
59
|
+
"@bi-digital/css": "0.11.9"
|
|
60
60
|
},
|
|
61
61
|
"scripts": {
|
|
62
62
|
"build": "tsdown",
|