@nordhealth/react 1.0.0-rc.7 → 1.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/lib/index.d.ts +63 -63
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/package.json +6 -5
package/lib/index.d.ts
CHANGED
|
@@ -1,127 +1,127 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import * as Components from "@nordhealth/components";
|
|
3
|
-
export declare const Avatar: React.ForwardRefExoticComponent<Partial<Omit<Components.Avatar, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
3
|
+
export declare const Avatar: React.ForwardRefExoticComponent<Partial<Omit<Components.Avatar, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
4
4
|
children?: React.ReactNode;
|
|
5
5
|
} & React.RefAttributes<unknown>>;
|
|
6
|
-
export declare const Badge: React.ForwardRefExoticComponent<Partial<Omit<Components.Badge, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
6
|
+
export declare const Badge: React.ForwardRefExoticComponent<Partial<Omit<Components.Badge, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
7
7
|
children?: React.ReactNode;
|
|
8
8
|
} & React.RefAttributes<unknown>>;
|
|
9
|
-
export declare const
|
|
9
|
+
export declare const Button: React.ForwardRefExoticComponent<Partial<Omit<Components.Button, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
10
10
|
children?: React.ReactNode;
|
|
11
11
|
} & React.RefAttributes<unknown>>;
|
|
12
|
-
export declare const Calendar: React.ForwardRefExoticComponent<Partial<Omit<Components.Calendar, "children">> & {
|
|
13
|
-
onNordFocusDate
|
|
14
|
-
onChange
|
|
15
|
-
} & React.HTMLAttributes<HTMLElement> & {
|
|
12
|
+
export declare const Calendar: React.ForwardRefExoticComponent<Partial<Omit<Components.Calendar, "children">> & Partial<{
|
|
13
|
+
onNordFocusDate: (e: Event) => void;
|
|
14
|
+
onChange: (e: Event) => void;
|
|
15
|
+
}> & Omit<React.HTMLAttributes<HTMLElement>, "onChange" | "onNordFocusDate"> & {
|
|
16
16
|
children?: React.ReactNode;
|
|
17
17
|
} & React.RefAttributes<unknown>>;
|
|
18
|
-
export declare const
|
|
18
|
+
export declare const Banner: React.ForwardRefExoticComponent<Partial<Omit<Components.Banner, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
19
19
|
children?: React.ReactNode;
|
|
20
20
|
} & React.RefAttributes<unknown>>;
|
|
21
|
-
export declare const Card: React.ForwardRefExoticComponent<Partial<Omit<Components.Card, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
21
|
+
export declare const Card: React.ForwardRefExoticComponent<Partial<Omit<Components.Card, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
22
22
|
children?: React.ReactNode;
|
|
23
23
|
} & React.RefAttributes<unknown>>;
|
|
24
|
-
export declare const Checkbox: React.ForwardRefExoticComponent<Partial<Omit<Components.Checkbox, "children">> & {
|
|
25
|
-
onInput
|
|
26
|
-
onChange
|
|
27
|
-
} & React.HTMLAttributes<HTMLElement> & {
|
|
24
|
+
export declare const Checkbox: React.ForwardRefExoticComponent<Partial<Omit<Components.Checkbox, "children">> & Partial<{
|
|
25
|
+
onInput: (e: Event) => void;
|
|
26
|
+
onChange: (e: Event) => void;
|
|
27
|
+
}> & Omit<React.HTMLAttributes<HTMLElement>, "onChange" | "onInput"> & {
|
|
28
28
|
children?: React.ReactNode;
|
|
29
29
|
} & React.RefAttributes<unknown>>;
|
|
30
|
-
export declare const CommandMenu: React.ForwardRefExoticComponent<Partial<Omit<Components.CommandMenu, "children">> & {
|
|
31
|
-
onOpen
|
|
32
|
-
onClose
|
|
33
|
-
onNordSelect
|
|
34
|
-
} & React.HTMLAttributes<HTMLElement> & {
|
|
30
|
+
export declare const CommandMenu: React.ForwardRefExoticComponent<Partial<Omit<Components.CommandMenu, "children">> & Partial<{
|
|
31
|
+
onOpen: (e: Event) => void;
|
|
32
|
+
onClose: (e: Event) => void;
|
|
33
|
+
onNordSelect: (e: Event) => void;
|
|
34
|
+
}> & Omit<React.HTMLAttributes<HTMLElement>, "onOpen" | "onClose" | "onNordSelect"> & {
|
|
35
35
|
children?: React.ReactNode;
|
|
36
36
|
} & React.RefAttributes<unknown>>;
|
|
37
|
-
export declare const DatePicker: React.ForwardRefExoticComponent<Partial<Omit<Components.DatePicker, "children">> & {
|
|
38
|
-
onOpen
|
|
39
|
-
onClose
|
|
40
|
-
onChange
|
|
41
|
-
onInput
|
|
42
|
-
} & React.HTMLAttributes<HTMLElement> & {
|
|
37
|
+
export declare const DatePicker: React.ForwardRefExoticComponent<Partial<Omit<Components.DatePicker, "children">> & Partial<{
|
|
38
|
+
onOpen: (e: Event) => void;
|
|
39
|
+
onClose: (e: Event) => void;
|
|
40
|
+
onChange: (e: Event) => void;
|
|
41
|
+
onInput: (e: Event) => void;
|
|
42
|
+
}> & Omit<React.HTMLAttributes<HTMLElement>, "onChange" | "onInput" | "onOpen" | "onClose"> & {
|
|
43
43
|
children?: React.ReactNode;
|
|
44
44
|
} & React.RefAttributes<unknown>>;
|
|
45
|
-
export declare const Dropdown: React.ForwardRefExoticComponent<Partial<Omit<Components.Dropdown, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
45
|
+
export declare const Dropdown: React.ForwardRefExoticComponent<Partial<Omit<Components.Dropdown, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
46
46
|
children?: React.ReactNode;
|
|
47
47
|
} & React.RefAttributes<unknown>>;
|
|
48
|
-
export declare const DropdownGroup: React.ForwardRefExoticComponent<Partial<Omit<Components.DropdownGroup, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
48
|
+
export declare const DropdownGroup: React.ForwardRefExoticComponent<Partial<Omit<Components.DropdownGroup, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
49
49
|
children?: React.ReactNode;
|
|
50
50
|
} & React.RefAttributes<unknown>>;
|
|
51
|
-
export declare const DropdownItem: React.ForwardRefExoticComponent<Partial<Omit<Components.DropdownItem, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
51
|
+
export declare const DropdownItem: React.ForwardRefExoticComponent<Partial<Omit<Components.DropdownItem, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
52
52
|
children?: React.ReactNode;
|
|
53
53
|
} & React.RefAttributes<unknown>>;
|
|
54
|
-
export declare const EmptyState: React.ForwardRefExoticComponent<Partial<Omit<Components.EmptyState, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
54
|
+
export declare const EmptyState: React.ForwardRefExoticComponent<Partial<Omit<Components.EmptyState, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
55
55
|
children?: React.ReactNode;
|
|
56
56
|
} & React.RefAttributes<unknown>>;
|
|
57
|
-
export declare const Fieldset: React.ForwardRefExoticComponent<Partial<Omit<Components.Fieldset, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
57
|
+
export declare const Fieldset: React.ForwardRefExoticComponent<Partial<Omit<Components.Fieldset, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
58
58
|
children?: React.ReactNode;
|
|
59
59
|
} & React.RefAttributes<unknown>>;
|
|
60
|
-
export declare const Header: React.ForwardRefExoticComponent<Partial<Omit<Components.Header, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
60
|
+
export declare const Header: React.ForwardRefExoticComponent<Partial<Omit<Components.Header, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
61
61
|
children?: React.ReactNode;
|
|
62
62
|
} & React.RefAttributes<unknown>>;
|
|
63
|
-
export declare const Icon: React.ForwardRefExoticComponent<Partial<Omit<Components.Icon, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
63
|
+
export declare const Icon: React.ForwardRefExoticComponent<Partial<Omit<Components.Icon, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
64
64
|
children?: React.ReactNode;
|
|
65
65
|
} & React.RefAttributes<unknown>>;
|
|
66
|
-
export declare const Input: React.ForwardRefExoticComponent<Partial<Omit<Components.Input, "children">> & {
|
|
67
|
-
onInput
|
|
68
|
-
onChange
|
|
69
|
-
} & React.HTMLAttributes<HTMLElement> & {
|
|
66
|
+
export declare const Input: React.ForwardRefExoticComponent<Partial<Omit<Components.Input, "children">> & Partial<{
|
|
67
|
+
onInput: (e: Event) => void;
|
|
68
|
+
onChange: (e: Event) => void;
|
|
69
|
+
}> & Omit<React.HTMLAttributes<HTMLElement>, "onChange" | "onInput"> & {
|
|
70
70
|
children?: React.ReactNode;
|
|
71
71
|
} & React.RefAttributes<unknown>>;
|
|
72
|
-
export declare const Layout: React.ForwardRefExoticComponent<Partial<Omit<Components.Layout, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
72
|
+
export declare const Layout: React.ForwardRefExoticComponent<Partial<Omit<Components.Layout, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
73
73
|
children?: React.ReactNode;
|
|
74
74
|
} & React.RefAttributes<unknown>>;
|
|
75
|
-
export declare const NavGroup: React.ForwardRefExoticComponent<Partial<Omit<Components.NavGroup, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
75
|
+
export declare const NavGroup: React.ForwardRefExoticComponent<Partial<Omit<Components.NavGroup, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
76
76
|
children?: React.ReactNode;
|
|
77
77
|
} & React.RefAttributes<unknown>>;
|
|
78
|
-
export declare const NavItem: React.ForwardRefExoticComponent<Partial<Omit<Components.NavItem, "children">> & {
|
|
79
|
-
onToggle
|
|
80
|
-
} & React.HTMLAttributes<HTMLElement> & {
|
|
78
|
+
export declare const NavItem: React.ForwardRefExoticComponent<Partial<Omit<Components.NavItem, "children">> & Partial<{
|
|
79
|
+
onToggle: (e: Event) => void;
|
|
80
|
+
}> & Omit<React.HTMLAttributes<HTMLElement>, "onToggle"> & {
|
|
81
81
|
children?: React.ReactNode;
|
|
82
82
|
} & React.RefAttributes<unknown>>;
|
|
83
|
-
export declare const Navigation: React.ForwardRefExoticComponent<Partial<Omit<Components.Navigation, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
83
|
+
export declare const Navigation: React.ForwardRefExoticComponent<Partial<Omit<Components.Navigation, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
84
84
|
children?: React.ReactNode;
|
|
85
85
|
} & React.RefAttributes<unknown>>;
|
|
86
|
-
export declare const Popout: React.ForwardRefExoticComponent<Partial<Omit<Components.Popout, "children">> & {
|
|
87
|
-
onOpen
|
|
88
|
-
onClose
|
|
89
|
-
} & React.HTMLAttributes<HTMLElement> & {
|
|
86
|
+
export declare const Popout: React.ForwardRefExoticComponent<Partial<Omit<Components.Popout, "children">> & Partial<{
|
|
87
|
+
onOpen: (e: Event) => void;
|
|
88
|
+
onClose: (e: Event) => void;
|
|
89
|
+
}> & Omit<React.HTMLAttributes<HTMLElement>, "onOpen" | "onClose"> & {
|
|
90
90
|
children?: React.ReactNode;
|
|
91
91
|
} & React.RefAttributes<unknown>>;
|
|
92
|
-
export declare const ProgressBar: React.ForwardRefExoticComponent<Partial<Omit<Components.ProgressBar, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
92
|
+
export declare const ProgressBar: React.ForwardRefExoticComponent<Partial<Omit<Components.ProgressBar, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
93
93
|
children?: React.ReactNode;
|
|
94
94
|
} & React.RefAttributes<unknown>>;
|
|
95
|
-
export declare const Radio: React.ForwardRefExoticComponent<Partial<Omit<Components.Radio, "children">> & {
|
|
96
|
-
onInput
|
|
97
|
-
onChange
|
|
98
|
-
} & React.HTMLAttributes<HTMLElement> & {
|
|
95
|
+
export declare const Radio: React.ForwardRefExoticComponent<Partial<Omit<Components.Radio, "children">> & Partial<{
|
|
96
|
+
onInput: (e: Event) => void;
|
|
97
|
+
onChange: (e: Event) => void;
|
|
98
|
+
}> & Omit<React.HTMLAttributes<HTMLElement>, "onChange" | "onInput"> & {
|
|
99
99
|
children?: React.ReactNode;
|
|
100
100
|
} & React.RefAttributes<unknown>>;
|
|
101
|
-
export declare const Select: React.ForwardRefExoticComponent<Partial<Omit<Components.Select, "children">> & {
|
|
102
|
-
onInput
|
|
103
|
-
onChange
|
|
104
|
-
} & React.HTMLAttributes<HTMLElement> & {
|
|
101
|
+
export declare const Select: React.ForwardRefExoticComponent<Partial<Omit<Components.Select, "children">> & Partial<{
|
|
102
|
+
onInput: (e: Event) => void;
|
|
103
|
+
onChange: (e: Event) => void;
|
|
104
|
+
}> & Omit<React.HTMLAttributes<HTMLElement>, "onChange" | "onInput"> & {
|
|
105
105
|
children?: React.ReactNode;
|
|
106
106
|
} & React.RefAttributes<unknown>>;
|
|
107
|
-
export declare const Spinner: React.ForwardRefExoticComponent<Partial<Omit<Components.Spinner, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
107
|
+
export declare const Spinner: React.ForwardRefExoticComponent<Partial<Omit<Components.Spinner, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
108
108
|
children?: React.ReactNode;
|
|
109
109
|
} & React.RefAttributes<unknown>>;
|
|
110
|
-
export declare const Stack: React.ForwardRefExoticComponent<Partial<Omit<Components.Stack, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
110
|
+
export declare const Stack: React.ForwardRefExoticComponent<Partial<Omit<Components.Stack, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
111
111
|
children?: React.ReactNode;
|
|
112
112
|
} & React.RefAttributes<unknown>>;
|
|
113
|
-
export declare const Table: React.ForwardRefExoticComponent<Partial<Omit<Components.Table, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
113
|
+
export declare const Table: React.ForwardRefExoticComponent<Partial<Omit<Components.Table, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
114
114
|
children?: React.ReactNode;
|
|
115
115
|
} & React.RefAttributes<unknown>>;
|
|
116
|
-
export declare const Textarea: React.ForwardRefExoticComponent<Partial<Omit<Components.Textarea, "children">> & {
|
|
117
|
-
onInput
|
|
118
|
-
onChange
|
|
119
|
-
} & React.HTMLAttributes<HTMLElement> & {
|
|
116
|
+
export declare const Textarea: React.ForwardRefExoticComponent<Partial<Omit<Components.Textarea, "children">> & Partial<{
|
|
117
|
+
onInput: (e: Event) => void;
|
|
118
|
+
onChange: (e: Event) => void;
|
|
119
|
+
}> & Omit<React.HTMLAttributes<HTMLElement>, "onChange" | "onInput"> & {
|
|
120
120
|
children?: React.ReactNode;
|
|
121
121
|
} & React.RefAttributes<unknown>>;
|
|
122
|
-
export declare const Tooltip: React.ForwardRefExoticComponent<Partial<Omit<Components.Tooltip, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
122
|
+
export declare const Tooltip: React.ForwardRefExoticComponent<Partial<Omit<Components.Tooltip, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
123
123
|
children?: React.ReactNode;
|
|
124
124
|
} & React.RefAttributes<unknown>>;
|
|
125
|
-
export declare const VisuallyHidden: React.ForwardRefExoticComponent<Partial<Omit<Components.VisuallyHidden, "children">> & {} & React.HTMLAttributes<HTMLElement> & {
|
|
125
|
+
export declare const VisuallyHidden: React.ForwardRefExoticComponent<Partial<Omit<Components.VisuallyHidden, "children">> & Partial<{}> & Omit<React.HTMLAttributes<HTMLElement>, never> & {
|
|
126
126
|
children?: React.ReactNode;
|
|
127
127
|
} & React.RefAttributes<unknown>>;
|
package/lib/index.js
CHANGED
|
@@ -3,5 +3,5 @@ import*as n from"react";import*as o from"@nordhealth/components";
|
|
|
3
3
|
* @license
|
|
4
4
|
* Copyright 2018 Google LLC
|
|
5
5
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
6
|
-
*/const e=new Set(["children","localName","ref","style","className"]),t=new WeakMap,r=(n,o,e,r,a)=>{const d=null==a?void 0:a[o];void 0!==d?e!==r&&((n,o,e)=>{let r=t.get(n);void 0===r&&t.set(n,r=new Map);let a=r.get(o);void 0!==e?void 0===a?(r.set(o,a={handleEvent:e}),n.addEventListener(o,a)):a.handleEvent=e:void 0!==a&&(r.delete(o),n.removeEventListener(o,a))})(n,d,e):n[o]=e},a=(n,o,t,a,d)=>{const s=n.Component,i=n.createElement,p=new Set(Object.keys(null!=a?a:{}));for(const n in t.prototype)n in HTMLElement.prototype||(e.has(n)?console.warn(`${o} contains property ${n} which is a React reserved property. It will be used by React and not set on the element.`):p.add(n));class l extends s{constructor(){super(...arguments),this.t=null}o(n){if(null!==this.t)for(const o in this.i)r(this.t,o,this.props[o],n?n[o]:void 0,a)}componentDidMount(){this.o()}componentDidUpdate(n){this.o(n)}render(){const n=this.props.l;void 0!==this.h&&this.u===n||(this.h=o=>{null===this.t&&(this.t=o),null!==n&&((n,o)=>{"function"==typeof n?n(o):n.current=o})(n,o),this.u=n});const e={ref:this.h};this.i={};for(const[n,o]of Object.entries(this.props))p.has(n)?this.i[n]=o:e["className"===n?"class":n]=o;return i(o,e)}}l.displayName=null!=d?d:t.name;const c=n.forwardRef(((n,o)=>i(l,{...n,l:o},null==n?void 0:n.children)));return c.displayName=l.displayName,c},d=a(n,"nord-avatar",o.Avatar,{}),s=a(n,"nord-badge",o.Badge,{}),i=a(n,"nord-
|
|
6
|
+
*/const e=new Set(["children","localName","ref","style","className"]),t=new WeakMap,r=(n,o,e,r,a)=>{const d=null==a?void 0:a[o];void 0!==d?e!==r&&((n,o,e)=>{let r=t.get(n);void 0===r&&t.set(n,r=new Map);let a=r.get(o);void 0!==e?void 0===a?(r.set(o,a={handleEvent:e}),n.addEventListener(o,a)):a.handleEvent=e:void 0!==a&&(r.delete(o),n.removeEventListener(o,a))})(n,d,e):n[o]=e},a=(n,o,t,a,d)=>{const s=n.Component,i=n.createElement,p=new Set(Object.keys(null!=a?a:{}));for(const n in t.prototype)n in HTMLElement.prototype||(e.has(n)?console.warn(`${o} contains property ${n} which is a React reserved property. It will be used by React and not set on the element.`):p.add(n));class l extends s{constructor(){super(...arguments),this.t=null}o(n){if(null!==this.t)for(const o in this.i)r(this.t,o,this.props[o],n?n[o]:void 0,a)}componentDidMount(){this.o()}componentDidUpdate(n){this.o(n)}render(){const n=this.props.l;void 0!==this.h&&this.u===n||(this.h=o=>{null===this.t&&(this.t=o),null!==n&&((n,o)=>{"function"==typeof n?n(o):n.current=o})(n,o),this.u=n});const e={ref:this.h};this.i={};for(const[n,o]of Object.entries(this.props))"__forwardedRef"!==n&&(p.has(n)?this.i[n]=o:e["className"===n?"class":n]=o);return i(o,e)}}l.displayName=null!=d?d:t.name;const c=n.forwardRef(((n,o)=>i(l,{...n,l:o},null==n?void 0:n.children)));return c.displayName=l.displayName,c},d=a(n,"nord-avatar",o.Avatar,{}),s=a(n,"nord-badge",o.Badge,{}),i=a(n,"nord-button",o.Button,{}),p=a(n,"nord-calendar",o.Calendar,{onNordFocusDate:"nord-focus-date",onChange:"change"}),l=a(n,"nord-banner",o.Banner,{}),c=a(n,"nord-card",o.Card,{}),h=a(n,"nord-checkbox",o.Checkbox,{onInput:"input",onChange:"change"}),u=a(n,"nord-command-menu",o.CommandMenu,{onOpen:"open",onClose:"close",onNordSelect:"nord-select"}),m=a(n,"nord-date-picker",o.DatePicker,{onOpen:"open",onClose:"close",onChange:"change",onInput:"input"}),g=a(n,"nord-dropdown",o.Dropdown,{}),v=a(n,"nord-dropdown-group",o.DropdownGroup,{}),f=a(n,"nord-dropdown-item",o.DropdownItem,{}),y=a(n,"nord-empty-state",o.EmptyState,{}),w=a(n,"nord-fieldset",o.Fieldset,{}),C=a(n,"nord-header",o.Header,{}),b=a(n,"nord-icon",o.Icon,{}),I=a(n,"nord-input",o.Input,{onInput:"input",onChange:"change"}),N=a(n,"nord-layout",o.Layout,{}),k=a(n,"nord-nav-group",o.NavGroup,{}),D=a(n,"nord-nav-item",o.NavItem,{onToggle:"toggle"}),E=a(n,"nord-navigation",o.Navigation,{}),S=a(n,"nord-popout",o.Popout,{onOpen:"open",onClose:"close"}),x=a(n,"nord-progress-bar",o.ProgressBar,{}),M=a(n,"nord-radio",o.Radio,{onInput:"input",onChange:"change"}),O=a(n,"nord-select",o.Select,{onInput:"input",onChange:"change"}),R=a(n,"nord-spinner",o.Spinner,{}),T=a(n,"nord-stack",o.Stack,{}),B=a(n,"nord-table",o.Table,{}),L=a(n,"nord-textarea",o.Textarea,{onInput:"input",onChange:"change"}),H=a(n,"nord-tooltip",o.Tooltip,{}),P=a(n,"nord-visually-hidden",o.VisuallyHidden,{});export{d as Avatar,s as Badge,l as Banner,i as Button,p as Calendar,c as Card,h as Checkbox,u as CommandMenu,m as DatePicker,g as Dropdown,v as DropdownGroup,f as DropdownItem,y as EmptyState,w as Fieldset,C as Header,b as Icon,I as Input,N as Layout,k as NavGroup,D as NavItem,E as Navigation,S as Popout,x as ProgressBar,M as Radio,O as Select,R as Spinner,T as Stack,B as Table,L as Textarea,H as Tooltip,P as VisuallyHidden};
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../node_modules/@lit-labs/react/create-component.js","../src/index.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nconst t=new Set([\"children\",\"localName\",\"ref\",\"style\",\"className\"]),e=new WeakMap,n=(t,n,s,o,i)=>{const l=null==i?void 0:i[n];void 0!==l?s!==o&&((t,n,s)=>{let o=e.get(t);void 0===o&&e.set(t,o=new Map);let i=o.get(n);void 0!==s?void 0===i?(o.set(n,i={handleEvent:s}),t.addEventListener(n,i)):i.handleEvent=s:void 0!==i&&(o.delete(n),t.removeEventListener(n,i))})(t,l,s):t[n]=s},s=(e,s,o,i,l)=>{const c=e.Component,r=e.createElement,
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../node_modules/@lit-labs/react/create-component.js","../src/index.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nconst t=new Set([\"children\",\"localName\",\"ref\",\"style\",\"className\"]),e=new WeakMap,n=(t,n,s,o,i)=>{const l=null==i?void 0:i[n];void 0!==l?s!==o&&((t,n,s)=>{let o=e.get(t);void 0===o&&e.set(t,o=new Map);let i=o.get(n);void 0!==s?void 0===i?(o.set(n,i={handleEvent:s}),t.addEventListener(n,i)):i.handleEvent=s:void 0!==i&&(o.delete(n),t.removeEventListener(n,i))})(t,l,s):t[n]=s},s=(e,s,o,i,l)=>{const c=e.Component,r=e.createElement,d=new Set(Object.keys(null!=i?i:{}));for(const e in o.prototype)e in HTMLElement.prototype||(t.has(e)?console.warn(`${s} contains property ${e} which is a React reserved property. It will be used by React and not set on the element.`):d.add(e));class h extends c{constructor(){super(...arguments),this.t=null}o(t){if(null!==this.t)for(const e in this.i)n(this.t,e,this.props[e],t?t[e]:void 0,i)}componentDidMount(){this.o()}componentDidUpdate(t){this.o(t)}render(){const t=this.props.l;void 0!==this.h&&this.u===t||(this.h=e=>{null===this.t&&(this.t=e),null!==t&&((t,e)=>{\"function\"==typeof t?t(e):t.current=e})(t,e),this.u=t});const e={ref:this.h};this.i={};for(const[t,n]of Object.entries(this.props))\"__forwardedRef\"!==t&&(d.has(t)?this.i[t]=n:e[\"className\"===t?\"class\":t]=n);return r(s,e)}}h.displayName=null!=l?l:o.name;const a=e.forwardRef(((t,e)=>r(h,{...t,l:e},null==t?void 0:t.children)));return a.displayName=h.displayName,a};export{s as createComponent};\n//# sourceMappingURL=create-component.js.map\n","import * as React from \"react\"\nimport { createComponent } from \"@lit-labs/react\"\nimport * as Components from \"@nordhealth/components\"\n\nexport const Avatar = createComponent(React, \"nord-avatar\", Components.Avatar, {})\n\nexport const Badge = createComponent(React, \"nord-badge\", Components.Badge, {})\n\nexport const Button = createComponent(React, \"nord-button\", Components.Button, {})\n\nexport const Calendar = createComponent(React, \"nord-calendar\", Components.Calendar, {\n onNordFocusDate: \"nord-focus-date\",\n onChange: \"change\",\n})\n\nexport const Banner = createComponent(React, \"nord-banner\", Components.Banner, {})\n\nexport const Card = createComponent(React, \"nord-card\", Components.Card, {})\n\nexport const Checkbox = createComponent(React, \"nord-checkbox\", Components.Checkbox, {\n onInput: \"input\",\n onChange: \"change\",\n})\n\nexport const CommandMenu = createComponent(React, \"nord-command-menu\", Components.CommandMenu, {\n onOpen: \"open\",\n onClose: \"close\",\n onNordSelect: \"nord-select\",\n})\n\nexport const DatePicker = createComponent(React, \"nord-date-picker\", Components.DatePicker, {\n onOpen: \"open\",\n onClose: \"close\",\n onChange: \"change\",\n onInput: \"input\",\n})\n\nexport const Dropdown = createComponent(React, \"nord-dropdown\", Components.Dropdown, {})\n\nexport const DropdownGroup = createComponent(React, \"nord-dropdown-group\", Components.DropdownGroup, {})\n\nexport const DropdownItem = createComponent(React, \"nord-dropdown-item\", Components.DropdownItem, {})\n\nexport const EmptyState = createComponent(React, \"nord-empty-state\", Components.EmptyState, {})\n\nexport const Fieldset = createComponent(React, \"nord-fieldset\", Components.Fieldset, {})\n\nexport const Header = createComponent(React, \"nord-header\", Components.Header, {})\n\nexport const Icon = createComponent(React, \"nord-icon\", Components.Icon, {})\n\nexport const Input = createComponent(React, \"nord-input\", Components.Input, { onInput: \"input\", onChange: \"change\" })\n\nexport const Layout = createComponent(React, \"nord-layout\", Components.Layout, {})\n\nexport const NavGroup = createComponent(React, \"nord-nav-group\", Components.NavGroup, {})\n\nexport const NavItem = createComponent(React, \"nord-nav-item\", Components.NavItem, { onToggle: \"toggle\" })\n\nexport const Navigation = createComponent(React, \"nord-navigation\", Components.Navigation, {})\n\nexport const Popout = createComponent(React, \"nord-popout\", Components.Popout, { onOpen: \"open\", onClose: \"close\" })\n\nexport const ProgressBar = createComponent(React, \"nord-progress-bar\", Components.ProgressBar, {})\n\nexport const Radio = createComponent(React, \"nord-radio\", Components.Radio, { onInput: \"input\", onChange: \"change\" })\n\nexport const Select = createComponent(React, \"nord-select\", Components.Select, { onInput: \"input\", onChange: \"change\" })\n\nexport const Spinner = createComponent(React, \"nord-spinner\", Components.Spinner, {})\n\nexport const Stack = createComponent(React, \"nord-stack\", Components.Stack, {})\n\nexport const Table = createComponent(React, \"nord-table\", Components.Table, {})\n\nexport const Textarea = createComponent(React, \"nord-textarea\", Components.Textarea, {\n onInput: \"input\",\n onChange: \"change\",\n})\n\nexport const Tooltip = createComponent(React, \"nord-tooltip\", Components.Tooltip, {})\n\nexport const VisuallyHidden = createComponent(React, \"nord-visually-hidden\", Components.VisuallyHidden, {})\n"],"names":["t","Set","e","WeakMap","n","s","o","i","l","get","set","Map","handleEvent","addEventListener","delete","removeEventListener","c","Component","r","createElement","d","Object","keys","prototype","HTMLElement","has","console","warn","add","h","constructor","super","arguments","this","props","componentDidMount","componentDidUpdate","render","u","current","ref","entries","displayName","name","a","forwardRef","children","Avatar","createComponent","React","Components","Badge","Button","Calendar","onNordFocusDate","onChange","Banner","Card","Checkbox","onInput","CommandMenu","onOpen","onClose","onNordSelect","DatePicker","Dropdown","DropdownGroup","DropdownItem","EmptyState","Fieldset","Header","Icon","Input","Layout","NavGroup","NavItem","onToggle","Navigation","Popout","ProgressBar","Radio","Select","Spinner","Stack","Table","Textarea","Tooltip","VisuallyHidden"],"mappings":";;;;;GAKA,MAAMA,EAAE,IAAIC,IAAI,CAAC,WAAW,YAAY,MAAM,QAAQ,cAAcC,EAAE,IAAIC,QAAQC,EAAE,CAACJ,EAAEI,EAAEC,EAAEC,EAAEC,KAAK,MAAMC,EAAE,MAAMD,OAAE,EAAOA,EAAEH,QAAG,IAASI,EAAEH,IAAIC,GAAG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,EAAgBC,EAAO,uBAAwBC,EAAWqC,eAAgB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nordhealth/react",
|
|
3
|
-
"version": "1.0.0
|
|
3
|
+
"version": "1.0.0",
|
|
4
4
|
"description": "This package includes react wrappers for Nord Design System's web components",
|
|
5
5
|
"author": "Nordhealth <support@nordhealth.design>",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
@@ -20,15 +20,16 @@
|
|
|
20
20
|
"scripts": {
|
|
21
21
|
"clean": "rm -rf lib/ && rm -rf src/",
|
|
22
22
|
"generate": "node ./scripts/build.mjs --build",
|
|
23
|
-
"
|
|
23
|
+
"bundle": "rollup -c",
|
|
24
|
+
"build": "npm run clean && npm run generate && npm run bundle"
|
|
24
25
|
},
|
|
25
26
|
"bugs": {
|
|
26
27
|
"url": "https://github.com/nordhealth/design-system/issues"
|
|
27
28
|
},
|
|
28
29
|
"homepage": "https://github.com/nordhealth/design-system#readme",
|
|
29
30
|
"dependencies": {
|
|
30
|
-
"@lit-labs/react": "1.0.
|
|
31
|
-
"@nordhealth/components": "^1.0.0
|
|
31
|
+
"@lit-labs/react": "1.0.4",
|
|
32
|
+
"@nordhealth/components": "^1.0.0"
|
|
32
33
|
},
|
|
33
34
|
"peerDependencies": {
|
|
34
35
|
"react": "17.0.2"
|
|
@@ -43,5 +44,5 @@
|
|
|
43
44
|
"rollup-plugin-summary": "1.3.0",
|
|
44
45
|
"rollup-plugin-terser": "7.0.2"
|
|
45
46
|
},
|
|
46
|
-
"gitHead": "
|
|
47
|
+
"gitHead": "2c0ee9b80535af89671914bba3e8f8b00d0eb233"
|
|
47
48
|
}
|