@transferwise/components 0.0.0-experimental-b2dc1ea → 0.0.0-experimental-4c86474
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/build/divider/Divider.js +33 -0
- package/build/divider/Divider.js.map +1 -0
- package/build/divider/Divider.mjs +31 -0
- package/build/divider/Divider.mjs.map +1 -0
- package/build/header/Header.js +34 -89
- package/build/header/Header.js.map +1 -1
- package/build/header/Header.mjs +31 -85
- package/build/header/Header.mjs.map +1 -1
- package/build/index.js +3 -1
- package/build/index.js.map +1 -1
- package/build/index.mjs +2 -1
- package/build/index.mjs.map +1 -1
- package/build/link/Link.js +3 -5
- package/build/link/Link.js.map +1 -1
- package/build/link/Link.mjs +3 -5
- package/build/link/Link.mjs.map +1 -1
- package/build/main.css +24 -3
- package/build/selectOption/SelectOption.js +1 -1
- package/build/selectOption/SelectOption.js.map +1 -1
- package/build/selectOption/SelectOption.mjs +1 -1
- package/build/styles/divider/Divider.css +24 -0
- package/build/styles/header/Header.css +0 -3
- package/build/styles/main.css +24 -3
- package/build/title/Title.js +3 -6
- package/build/title/Title.js.map +1 -1
- package/build/title/Title.mjs +3 -6
- package/build/title/Title.mjs.map +1 -1
- package/build/types/divider/Divider.d.ts +42 -0
- package/build/types/divider/Divider.d.ts.map +1 -0
- package/build/types/divider/index.d.ts +3 -0
- package/build/types/divider/index.d.ts.map +1 -0
- package/build/types/header/Header.d.ts +10 -34
- package/build/types/header/Header.d.ts.map +1 -1
- package/build/types/header/index.d.ts +0 -1
- package/build/types/header/index.d.ts.map +1 -1
- package/build/types/index.d.ts +2 -1
- package/build/types/index.d.ts.map +1 -1
- package/build/types/link/Link.d.ts +1 -3
- package/build/types/link/Link.d.ts.map +1 -1
- package/build/types/title/Title.d.ts +4 -3
- package/build/types/title/Title.d.ts.map +1 -1
- package/package.json +3 -3
- package/src/divider/Divider.css +24 -0
- package/src/divider/Divider.less +31 -0
- package/src/divider/Divider.spec.tsx +85 -0
- package/src/divider/Divider.story.tsx +29 -0
- package/src/divider/Divider.tsx +72 -0
- package/src/divider/index.ts +2 -0
- package/src/header/Header.css +0 -3
- package/src/header/Header.less +0 -4
- package/src/header/Header.spec.tsx +0 -33
- package/src/header/Header.story.tsx +40 -54
- package/src/header/Header.tsx +60 -126
- package/src/header/index.ts +0 -1
- package/src/index.ts +2 -1
- package/src/link/Link.tsx +27 -29
- package/src/main.css +24 -3
- package/src/main.less +1 -0
- package/src/ssr.spec.js +1 -0
- package/src/title/Title.tsx +11 -25
package/build/link/Link.mjs
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { NavigateAway } from '@transferwise/icons';
|
|
2
2
|
import { clsx } from 'clsx';
|
|
3
|
-
import { forwardRef } from 'react';
|
|
4
3
|
import { useIntl } from 'react-intl';
|
|
5
4
|
import messages from './Link.messages.mjs';
|
|
6
5
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
7
6
|
|
|
8
|
-
const Link =
|
|
7
|
+
const Link = ({
|
|
9
8
|
className,
|
|
10
9
|
children,
|
|
11
10
|
href,
|
|
@@ -14,13 +13,12 @@ const Link = /*#__PURE__*/forwardRef(({
|
|
|
14
13
|
'aria-label': ariaLabel,
|
|
15
14
|
onClick,
|
|
16
15
|
...props
|
|
17
|
-
}
|
|
16
|
+
}) => {
|
|
18
17
|
const isBlank = target === '_blank';
|
|
19
18
|
const {
|
|
20
19
|
formatMessage
|
|
21
20
|
} = useIntl();
|
|
22
21
|
return /*#__PURE__*/jsxs("a", {
|
|
23
|
-
ref: ref,
|
|
24
22
|
href: href,
|
|
25
23
|
target: target,
|
|
26
24
|
className: clsx('np-link', type ? `np-text-${type}` : undefined, 'd-inline-flex', className),
|
|
@@ -32,7 +30,7 @@ const Link = /*#__PURE__*/forwardRef(({
|
|
|
32
30
|
title: formatMessage(messages.opensInNewTab)
|
|
33
31
|
})]
|
|
34
32
|
});
|
|
35
|
-
}
|
|
33
|
+
};
|
|
36
34
|
|
|
37
35
|
export { Link as default };
|
|
38
36
|
//# sourceMappingURL=Link.mjs.map
|
package/build/link/Link.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Link.mjs","sources":["../../src/link/Link.tsx"],"sourcesContent":["import { NavigateAway as NavigateAwayIcon } from '@transferwise/icons';\nimport { clsx } from 'clsx';\nimport { AnchorHTMLAttributes
|
|
1
|
+
{"version":3,"file":"Link.mjs","sources":["../../src/link/Link.tsx"],"sourcesContent":["import { NavigateAway as NavigateAwayIcon } from '@transferwise/icons';\nimport { clsx } from 'clsx';\nimport { AnchorHTMLAttributes } from 'react';\nimport { useIntl } from 'react-intl';\n\nimport { LinkLarge, LinkDefault } from '../common';\n\nimport messages from './Link.messages';\n\nexport type Props = AnchorHTMLAttributes<HTMLAnchorElement> & { type?: LinkLarge | LinkDefault };\n\n/**\n * Standard Link component with navigate away icon\n *\n * Documentation: https://transferwise.github.io/neptune-web/components/content/Link\n */\nconst Link = ({\n className,\n children,\n href,\n target,\n type,\n 'aria-label': ariaLabel,\n onClick,\n ...props\n}: Props) => {\n const isBlank = target === '_blank';\n\n const { formatMessage } = useIntl();\n\n return (\n <a\n href={href}\n target={target}\n className={clsx('np-link', type ? `np-text-${type}` : undefined, 'd-inline-flex', className)}\n aria-label={ariaLabel}\n rel={isBlank ? 'noreferrer' : undefined}\n onClick={onClick}\n {...props}\n >\n {children} {isBlank && <NavigateAwayIcon title={formatMessage(messages.opensInNewTab)} />}\n </a>\n );\n};\n\nexport default Link;\n"],"names":["Link","className","children","href","target","type","ariaLabel","onClick","props","isBlank","formatMessage","useIntl","_jsxs","clsx","undefined","rel","_jsx","NavigateAwayIcon","title","messages","opensInNewTab"],"mappings":";;;;;;AAgBMA,MAAAA,IAAI,GAAGA,CAAC;EACZC,SAAS;EACTC,QAAQ;EACRC,IAAI;EACJC,MAAM;EACNC,IAAI;AACJ,EAAA,YAAY,EAAEC,SAAS;EACvBC,OAAO;EACP,GAAGC,KAAAA;AACG,CAAA,KAAI;AACV,EAAA,MAAMC,OAAO,GAAGL,MAAM,KAAK,QAAQ,CAAA;EAEnC,MAAM;AAAEM,IAAAA,aAAAA;GAAe,GAAGC,OAAO,EAAE,CAAA;AAEnC,EAAA,oBACEC,IAAA,CAAA,GAAA,EAAA;AACET,IAAAA,IAAI,EAAEA,IAAK;AACXC,IAAAA,MAAM,EAAEA,MAAO;AACfH,IAAAA,SAAS,EAAEY,IAAI,CAAC,SAAS,EAAER,IAAI,GAAG,CAAA,QAAA,EAAWA,IAAI,CAAA,CAAE,GAAGS,SAAS,EAAE,eAAe,EAAEb,SAAS,CAAE;AAC7F,IAAA,YAAA,EAAYK,SAAU;AACtBS,IAAAA,GAAG,EAAEN,OAAO,GAAG,YAAY,GAAGK,SAAU;AACxCP,IAAAA,OAAO,EAAEA,OAAQ;AAAA,IAAA,GACbC,KAAK;IAAAN,QAAA,EAAA,CAERA,QAAQ,EAAE,GAAA,EAACO,OAAO,iBAAIO,GAAA,CAACC,YAAgB,EAAA;AAACC,MAAAA,KAAK,EAAER,aAAa,CAACS,QAAQ,CAACC,aAAa,CAAA;AAAE,MAAG,CAAA;AAAA,GACxF,CAAC,CAAA;AAER;;;;"}
|
package/build/main.css
CHANGED
|
@@ -2038,6 +2038,30 @@ button.np-option {
|
|
|
2038
2038
|
padding: var(--size-24);
|
|
2039
2039
|
}
|
|
2040
2040
|
}
|
|
2041
|
+
.wds-Divider {
|
|
2042
|
+
--Divider-border-width: var(--size-4);
|
|
2043
|
+
--Divider-border-color: var(--color-border-neutral);
|
|
2044
|
+
--Divider-border-style: solid;
|
|
2045
|
+
--Divider-dash-length: var(--size-4);
|
|
2046
|
+
--Divider-dash-spacing: var(--size-4);
|
|
2047
|
+
border-top: 4px solid rgba(0,0,0,0.10196);
|
|
2048
|
+
border-top: var(--Divider-border-width) var(--Divider-border-style) var(--Divider-border-color);
|
|
2049
|
+
display: inline-block;
|
|
2050
|
+
margin: 0;
|
|
2051
|
+
padding: 0;
|
|
2052
|
+
height: 4px;
|
|
2053
|
+
height: var(--Divider-border-width);
|
|
2054
|
+
width: 100%;
|
|
2055
|
+
}
|
|
2056
|
+
.wds-Divider--content {
|
|
2057
|
+
border-top: none;
|
|
2058
|
+
background: repeating-linear-gradient(to right, var(--Divider-border-color), var(--Divider-border-color) var(--Divider-dash-length), transparent var(--Divider-dash-length), transparent calc(var(--Divider-dash-length) + var(--Divider-dash-spacing)));
|
|
2059
|
+
height: var(--Divider-border-width);
|
|
2060
|
+
}
|
|
2061
|
+
.wds-Divider--content,
|
|
2062
|
+
.wds-Divider--subsection {
|
|
2063
|
+
--Divider-border-width: 1px;
|
|
2064
|
+
}
|
|
2041
2065
|
.np-dropfade,
|
|
2042
2066
|
.np-dropfade-enter {
|
|
2043
2067
|
opacity: 0;
|
|
@@ -2242,9 +2266,6 @@ html:not([dir="rtl"]) .np-flow-navigation--sm .np-flow-navigation__stepper {
|
|
|
2242
2266
|
-moz-column-gap: var(--size-24);
|
|
2243
2267
|
column-gap: var(--size-24);
|
|
2244
2268
|
}
|
|
2245
|
-
.np-header--section {
|
|
2246
|
-
border-bottom: none;
|
|
2247
|
-
}
|
|
2248
2269
|
.np-header__title {
|
|
2249
2270
|
color: #5d7079;
|
|
2250
2271
|
color: var(--color-content-secondary);
|
|
@@ -52,7 +52,7 @@ function SelectOption({
|
|
|
52
52
|
className: clsx.clsx({
|
|
53
53
|
'p-x-2 p-y-1': isLargeScreen
|
|
54
54
|
}),
|
|
55
|
-
children: [optionsSection.title && /*#__PURE__*/jsxRuntime.jsx(Header, {
|
|
55
|
+
children: [optionsSection.title && /*#__PURE__*/jsxRuntime.jsx(Header.Header, {
|
|
56
56
|
title: optionsSection.title
|
|
57
57
|
}), /*#__PURE__*/jsxRuntime.jsx(NavigationOptionsList, {
|
|
58
58
|
children: optionsSection.options.map((option, index) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SelectOption.js","sources":["../../src/selectOption/SelectOption.tsx"],"sourcesContent":["import { useRef, useState } from 'react';\nimport { ActionButtonProps } from '../actionButton';\nimport { clsx } from 'clsx';\nimport Option from '../common/Option';\nimport type { OptionProps } from '../common/Option/Option';\nimport { Breakpoint, Position } from '../common';\nimport Section from '../section';\nimport Header from '../header';\nimport { HeaderProps } from '../header/Header';\nimport NavigationOption from '../navigationOption';\nimport NavigationOptionsList from '../navigationOptionsList';\nimport { useInputAttributes } from '../inputs/contexts';\nimport messages from './SelectOption.messages';\nimport { useIntl } from 'react-intl';\nimport ResponsivePanel from '../common/responsivePanel';\nimport { useScreenSize } from '../common/hooks/useScreenSize';\nimport { ChevronDown, Plus } from '@transferwise/icons';\n\nexport type SelectOptiopsSection<T = unknown> = {\n title?: HeaderProps['title'];\n options: SelectOptionValue<T>[];\n};\n\nexport type SelectOptionValue<T = unknown> = Pick<\n OptionProps,\n 'media' | 'title' | 'content' | 'disabled'\n> & {\n value?: T;\n};\n\nexport type SelectOptionPlaceholder = Pick<OptionProps, 'media' | 'title' | 'content'> & {\n actionLabel?: ActionButtonProps['children'];\n};\n\nexport type SelectOptionProps<T = unknown> = {\n onChange: (selected: SelectOptionValue<T>) => void;\n selected?: SelectOptionValue<T>;\n options: SelectOptiopsSection<T>[];\n placeholder: SelectOptionPlaceholder;\n} & Omit<\n OptionProps,\n 'as' | 'title' | 'media' | 'content' | 'onClick' | 'onChange' | 'showMediaAtAllSizes' | 'decision'\n>;\n\nexport default function SelectOption<T>({\n selected = undefined,\n options,\n onChange,\n placeholder,\n disabled,\n ...props\n}: SelectOptionProps<T>) {\n const intl = useIntl();\n const rootRef = useRef(null);\n const [showOptions, setShowOptions] = useState(false);\n\n const hasSelected = selected !== undefined;\n const isLargeScreen = useScreenSize(Breakpoint.SMALL);\n\n const inputAttributes = useInputAttributes();\n const ariaLabelledBy = props['aria-labelledby'] ?? inputAttributes?.['aria-labelledby'];\n\n function handleOnClick(showOptionsStatus: boolean) {\n return () => {\n setShowOptions(showOptionsStatus);\n };\n }\n\n function handleOnChange(data: SelectOptionValue<T>) {\n return () => {\n setShowOptions(false);\n onChange(data);\n };\n }\n\n function getOptions(isLargeScreen = false) {\n return (\n <div className={clsx({ 'np-select-option-list': isLargeScreen })}>\n {options.map((optionsSection, index) => (\n <Section key={index} className={clsx({ 'p-x-2 p-y-1': isLargeScreen })}>\n {optionsSection.title && <Header title={optionsSection.title} />}\n <NavigationOptionsList>\n {optionsSection.options.map((option, index) => {\n return (\n <NavigationOption\n key={index}\n isContainerAligned={!isLargeScreen}\n showMediaCircle\n showMediaAtAllSizes\n onClick={handleOnChange(option)}\n {...option}\n />\n );\n })}\n </NavigationOptionsList>\n </Section>\n ))}\n </div>\n );\n }\n\n return (\n <>\n <Option\n ref={rootRef}\n as=\"div\"\n showMediaAtAllSizes\n disabled={disabled}\n decision={false}\n media={hasSelected ? selected.media : (placeholder.media ?? <Plus size={24} />)}\n title={(hasSelected ? selected : placeholder).title}\n content={(hasSelected ? selected : placeholder).content}\n className={clsx(\n 'np-select-option',\n 'clickable',\n hasSelected ? 'np-select-option-selected' : 'np-select-option-placeholder',\n props.className,\n )}\n button={\n <button\n {...inputAttributes}\n type=\"button\"\n disabled={disabled}\n aria-labelledby={ariaLabelledBy}\n aria-haspopup=\"dialog\"\n aria-expanded={showOptions}\n className={hasSelected ? 'btn-unstyled' : 'np-action-btn'}\n aria-label={hasSelected ? undefined : props['aria-label']}\n onClick={handleOnClick(true)}\n >\n {hasSelected ? (\n <ChevronDown title={intl.formatMessage(messages.selectedActionLabel)} />\n ) : (\n placeholder.actionLabel || intl.formatMessage(messages.actionLabel)\n )}\n </button>\n }\n />\n <ResponsivePanel\n anchorWidth\n altAxis\n anchorRef={rootRef}\n open={showOptions}\n position={Position.BOTTOM}\n onClose={handleOnClick(false)}\n >\n {getOptions(isLargeScreen)}\n </ResponsivePanel>\n </>\n );\n}\n"],"names":["SelectOption","selected","undefined","options","onChange","placeholder","disabled","props","intl","useIntl","rootRef","useRef","showOptions","setShowOptions","useState","hasSelected","isLargeScreen","useScreenSize","Breakpoint","SMALL","inputAttributes","useInputAttributes","ariaLabelledBy","handleOnClick","showOptionsStatus","handleOnChange","data","getOptions","_jsx","className","clsx","children","map","optionsSection","index","_jsxs","Section","title","Header","NavigationOptionsList","option","NavigationOption","isContainerAligned","showMediaCircle","showMediaAtAllSizes","onClick","_Fragment","Option","ref","as","decision","media","Plus","size","content","button","type","ChevronDown","formatMessage","messages","selectedActionLabel","actionLabel","ResponsivePanel","anchorWidth","altAxis","anchorRef","open","position","Position","BOTTOM","onClose"],"mappings":";;;;;;;;;;;;;;;;;;;AA4CwB,SAAAA,YAAYA,CAAI;AACtCC,EAAAA,QAAQ,GAAGC,SAAS;EACpBC,OAAO;EACPC,QAAQ;EACRC,WAAW;EACXC,QAAQ;EACR,GAAGC,KAAAA;AACkB,CAAA,EAAA;AACrB,EAAA,MAAMC,IAAI,GAAGC,iBAAO,EAAE,CAAA;AACtB,EAAA,MAAMC,OAAO,GAAGC,YAAM,CAAC,IAAI,CAAC,CAAA;EAC5B,MAAM,CAACC,WAAW,EAAEC,cAAc,CAAC,GAAGC,cAAQ,CAAC,KAAK,CAAC,CAAA;AAErD,EAAA,MAAMC,WAAW,GAAGd,QAAQ,KAAKC,SAAS,CAAA;AAC1C,EAAA,MAAMc,aAAa,GAAGC,2BAAa,CAACC,qBAAU,CAACC,KAAK,CAAC,CAAA;AAErD,EAAA,MAAMC,eAAe,GAAGC,2BAAkB,EAAE,CAAA;EAC5C,MAAMC,cAAc,GAAGf,KAAK,CAAC,iBAAiB,CAAC,IAAIa,eAAe,GAAG,iBAAiB,CAAC,CAAA;EAEvF,SAASG,aAAaA,CAACC,iBAA0B,EAAA;AAC/C,IAAA,OAAO,MAAK;MACVX,cAAc,CAACW,iBAAiB,CAAC,CAAA;KAClC,CAAA;AACH,GAAA;EAEA,SAASC,cAAcA,CAACC,IAA0B,EAAA;AAChD,IAAA,OAAO,MAAK;MACVb,cAAc,CAAC,KAAK,CAAC,CAAA;MACrBT,QAAQ,CAACsB,IAAI,CAAC,CAAA;KACf,CAAA;AACH,GAAA;AAEA,EAAA,SAASC,UAAUA,CAACX,aAAa,GAAG,KAAK,EAAA;AACvC,IAAA,oBACEY,cAAA,CAAA,KAAA,EAAA;MAAKC,SAAS,EAAEC,SAAI,CAAC;AAAE,QAAA,uBAAuB,EAAEd,aAAAA;AAAe,OAAA,CAAE;AAAAe,MAAAA,QAAA,EAC9D5B,OAAO,CAAC6B,GAAG,CAAC,CAACC,cAAc,EAAEC,KAAK,kBACjCC,eAAA,CAACC,OAAO,EAAA;QAAaP,SAAS,EAAEC,SAAI,CAAC;AAAE,UAAA,aAAa,EAAEd,aAAAA;AAAe,SAAA,CAAE;AAAAe,QAAAA,QAAA,GACpEE,cAAc,CAACI,KAAK,iBAAIT,cAAA,CAACU,
|
|
1
|
+
{"version":3,"file":"SelectOption.js","sources":["../../src/selectOption/SelectOption.tsx"],"sourcesContent":["import { useRef, useState } from 'react';\nimport { ActionButtonProps } from '../actionButton';\nimport { clsx } from 'clsx';\nimport Option from '../common/Option';\nimport type { OptionProps } from '../common/Option/Option';\nimport { Breakpoint, Position } from '../common';\nimport Section from '../section';\nimport Header from '../header';\nimport { HeaderProps } from '../header/Header';\nimport NavigationOption from '../navigationOption';\nimport NavigationOptionsList from '../navigationOptionsList';\nimport { useInputAttributes } from '../inputs/contexts';\nimport messages from './SelectOption.messages';\nimport { useIntl } from 'react-intl';\nimport ResponsivePanel from '../common/responsivePanel';\nimport { useScreenSize } from '../common/hooks/useScreenSize';\nimport { ChevronDown, Plus } from '@transferwise/icons';\n\nexport type SelectOptiopsSection<T = unknown> = {\n title?: HeaderProps['title'];\n options: SelectOptionValue<T>[];\n};\n\nexport type SelectOptionValue<T = unknown> = Pick<\n OptionProps,\n 'media' | 'title' | 'content' | 'disabled'\n> & {\n value?: T;\n};\n\nexport type SelectOptionPlaceholder = Pick<OptionProps, 'media' | 'title' | 'content'> & {\n actionLabel?: ActionButtonProps['children'];\n};\n\nexport type SelectOptionProps<T = unknown> = {\n onChange: (selected: SelectOptionValue<T>) => void;\n selected?: SelectOptionValue<T>;\n options: SelectOptiopsSection<T>[];\n placeholder: SelectOptionPlaceholder;\n} & Omit<\n OptionProps,\n 'as' | 'title' | 'media' | 'content' | 'onClick' | 'onChange' | 'showMediaAtAllSizes' | 'decision'\n>;\n\nexport default function SelectOption<T>({\n selected = undefined,\n options,\n onChange,\n placeholder,\n disabled,\n ...props\n}: SelectOptionProps<T>) {\n const intl = useIntl();\n const rootRef = useRef(null);\n const [showOptions, setShowOptions] = useState(false);\n\n const hasSelected = selected !== undefined;\n const isLargeScreen = useScreenSize(Breakpoint.SMALL);\n\n const inputAttributes = useInputAttributes();\n const ariaLabelledBy = props['aria-labelledby'] ?? inputAttributes?.['aria-labelledby'];\n\n function handleOnClick(showOptionsStatus: boolean) {\n return () => {\n setShowOptions(showOptionsStatus);\n };\n }\n\n function handleOnChange(data: SelectOptionValue<T>) {\n return () => {\n setShowOptions(false);\n onChange(data);\n };\n }\n\n function getOptions(isLargeScreen = false) {\n return (\n <div className={clsx({ 'np-select-option-list': isLargeScreen })}>\n {options.map((optionsSection, index) => (\n <Section key={index} className={clsx({ 'p-x-2 p-y-1': isLargeScreen })}>\n {optionsSection.title && <Header title={optionsSection.title} />}\n <NavigationOptionsList>\n {optionsSection.options.map((option, index) => {\n return (\n <NavigationOption\n key={index}\n isContainerAligned={!isLargeScreen}\n showMediaCircle\n showMediaAtAllSizes\n onClick={handleOnChange(option)}\n {...option}\n />\n );\n })}\n </NavigationOptionsList>\n </Section>\n ))}\n </div>\n );\n }\n\n return (\n <>\n <Option\n ref={rootRef}\n as=\"div\"\n showMediaAtAllSizes\n disabled={disabled}\n decision={false}\n media={hasSelected ? selected.media : (placeholder.media ?? <Plus size={24} />)}\n title={(hasSelected ? selected : placeholder).title}\n content={(hasSelected ? selected : placeholder).content}\n className={clsx(\n 'np-select-option',\n 'clickable',\n hasSelected ? 'np-select-option-selected' : 'np-select-option-placeholder',\n props.className,\n )}\n button={\n <button\n {...inputAttributes}\n type=\"button\"\n disabled={disabled}\n aria-labelledby={ariaLabelledBy}\n aria-haspopup=\"dialog\"\n aria-expanded={showOptions}\n className={hasSelected ? 'btn-unstyled' : 'np-action-btn'}\n aria-label={hasSelected ? undefined : props['aria-label']}\n onClick={handleOnClick(true)}\n >\n {hasSelected ? (\n <ChevronDown title={intl.formatMessage(messages.selectedActionLabel)} />\n ) : (\n placeholder.actionLabel || intl.formatMessage(messages.actionLabel)\n )}\n </button>\n }\n />\n <ResponsivePanel\n anchorWidth\n altAxis\n anchorRef={rootRef}\n open={showOptions}\n position={Position.BOTTOM}\n onClose={handleOnClick(false)}\n >\n {getOptions(isLargeScreen)}\n </ResponsivePanel>\n </>\n );\n}\n"],"names":["SelectOption","selected","undefined","options","onChange","placeholder","disabled","props","intl","useIntl","rootRef","useRef","showOptions","setShowOptions","useState","hasSelected","isLargeScreen","useScreenSize","Breakpoint","SMALL","inputAttributes","useInputAttributes","ariaLabelledBy","handleOnClick","showOptionsStatus","handleOnChange","data","getOptions","_jsx","className","clsx","children","map","optionsSection","index","_jsxs","Section","title","Header","NavigationOptionsList","option","NavigationOption","isContainerAligned","showMediaCircle","showMediaAtAllSizes","onClick","_Fragment","Option","ref","as","decision","media","Plus","size","content","button","type","ChevronDown","formatMessage","messages","selectedActionLabel","actionLabel","ResponsivePanel","anchorWidth","altAxis","anchorRef","open","position","Position","BOTTOM","onClose"],"mappings":";;;;;;;;;;;;;;;;;;;AA4CwB,SAAAA,YAAYA,CAAI;AACtCC,EAAAA,QAAQ,GAAGC,SAAS;EACpBC,OAAO;EACPC,QAAQ;EACRC,WAAW;EACXC,QAAQ;EACR,GAAGC,KAAAA;AACkB,CAAA,EAAA;AACrB,EAAA,MAAMC,IAAI,GAAGC,iBAAO,EAAE,CAAA;AACtB,EAAA,MAAMC,OAAO,GAAGC,YAAM,CAAC,IAAI,CAAC,CAAA;EAC5B,MAAM,CAACC,WAAW,EAAEC,cAAc,CAAC,GAAGC,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iBAAA,EAAiBgB,cAAe;AAChC,QAAA,eAAA,EAAc,QAAQ;AACtB,QAAA,eAAA,EAAeV,WAAY;AAC3BiB,QAAAA,SAAS,EAAEd,WAAW,GAAG,cAAc,GAAG,eAAgB;AAC1D,QAAA,YAAA,EAAYA,WAAW,GAAGb,SAAS,GAAGK,KAAK,CAAC,YAAY,CAAE;AAC1DsC,QAAAA,OAAO,EAAEtB,aAAa,CAAC,IAAI,CAAE;AAAAQ,QAAAA,QAAA,EAE5BhB,WAAW,gBACVa,cAAA,CAAC6B,iBAAW,EAAA;AAACpB,UAAAA,KAAK,EAAE7B,IAAI,CAACkD,aAAa,CAACC,qBAAQ,CAACC,mBAAmB,CAAA;AAAE,SAAA,CAAG,GAExEvD,WAAW,CAACwD,WAAW,IAAIrD,IAAI,CAACkD,aAAa,CAACC,qBAAQ,CAACE,WAAW,CAAA;OAE9D,CAAA;AACT,KAEH,CAAA,eAAAjC,cAAA,CAACkC,eAAe,EAAA;MACdC,WAAW,EAAA,IAAA;MACXC,OAAO,EAAA,IAAA;AACPC,MAAAA,SAAS,EAAEvD,OAAQ;AACnBwD,MAAAA,IAAI,EAAEtD,WAAY;MAClBuD,QAAQ,EAAEC,iBAAQ,CAACC,MAAO;AAC1BC,MAAAA,OAAO,EAAE/C,aAAa,CAAC,KAAK,CAAE;MAAAQ,QAAA,EAE7BJ,UAAU,CAACX,aAAa,CAAA;AAAC,KACX,CACnB,CAAA;AAAA,GAAA,CAAG,CAAA;AAEP;;;;"}
|
|
@@ -2,7 +2,7 @@ import { useRef, useState } from 'react';
|
|
|
2
2
|
import { clsx } from 'clsx';
|
|
3
3
|
import Option from '../common/Option/Option.mjs';
|
|
4
4
|
import Section from '../section/Section.mjs';
|
|
5
|
-
import Header from '../header/Header.mjs';
|
|
5
|
+
import { Header } from '../header/Header.mjs';
|
|
6
6
|
import NavigationOption from '../navigationOption/NavigationOption.mjs';
|
|
7
7
|
import NavigationOptionList from '../navigationOptionsList/NavigationOptionsList.mjs';
|
|
8
8
|
import { useInputAttributes } from '../inputs/contexts.mjs';
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
.wds-Divider {
|
|
2
|
+
--Divider-border-width: var(--size-4);
|
|
3
|
+
--Divider-border-color: var(--color-border-neutral);
|
|
4
|
+
--Divider-border-style: solid;
|
|
5
|
+
--Divider-dash-length: var(--size-4);
|
|
6
|
+
--Divider-dash-spacing: var(--size-4);
|
|
7
|
+
border-top: 4px solid rgba(0,0,0,0.10196);
|
|
8
|
+
border-top: var(--Divider-border-width) var(--Divider-border-style) var(--Divider-border-color);
|
|
9
|
+
display: inline-block;
|
|
10
|
+
margin: 0;
|
|
11
|
+
padding: 0;
|
|
12
|
+
height: 4px;
|
|
13
|
+
height: var(--Divider-border-width);
|
|
14
|
+
width: 100%;
|
|
15
|
+
}
|
|
16
|
+
.wds-Divider--content {
|
|
17
|
+
border-top: none;
|
|
18
|
+
background: repeating-linear-gradient(to right, var(--Divider-border-color), var(--Divider-border-color) var(--Divider-dash-length), transparent var(--Divider-dash-length), transparent calc(var(--Divider-dash-length) + var(--Divider-dash-spacing)));
|
|
19
|
+
height: var(--Divider-border-width);
|
|
20
|
+
}
|
|
21
|
+
.wds-Divider--content,
|
|
22
|
+
.wds-Divider--subsection {
|
|
23
|
+
--Divider-border-width: 1px;
|
|
24
|
+
}
|
package/build/styles/main.css
CHANGED
|
@@ -2038,6 +2038,30 @@ button.np-option {
|
|
|
2038
2038
|
padding: var(--size-24);
|
|
2039
2039
|
}
|
|
2040
2040
|
}
|
|
2041
|
+
.wds-Divider {
|
|
2042
|
+
--Divider-border-width: var(--size-4);
|
|
2043
|
+
--Divider-border-color: var(--color-border-neutral);
|
|
2044
|
+
--Divider-border-style: solid;
|
|
2045
|
+
--Divider-dash-length: var(--size-4);
|
|
2046
|
+
--Divider-dash-spacing: var(--size-4);
|
|
2047
|
+
border-top: 4px solid rgba(0,0,0,0.10196);
|
|
2048
|
+
border-top: var(--Divider-border-width) var(--Divider-border-style) var(--Divider-border-color);
|
|
2049
|
+
display: inline-block;
|
|
2050
|
+
margin: 0;
|
|
2051
|
+
padding: 0;
|
|
2052
|
+
height: 4px;
|
|
2053
|
+
height: var(--Divider-border-width);
|
|
2054
|
+
width: 100%;
|
|
2055
|
+
}
|
|
2056
|
+
.wds-Divider--content {
|
|
2057
|
+
border-top: none;
|
|
2058
|
+
background: repeating-linear-gradient(to right, var(--Divider-border-color), var(--Divider-border-color) var(--Divider-dash-length), transparent var(--Divider-dash-length), transparent calc(var(--Divider-dash-length) + var(--Divider-dash-spacing)));
|
|
2059
|
+
height: var(--Divider-border-width);
|
|
2060
|
+
}
|
|
2061
|
+
.wds-Divider--content,
|
|
2062
|
+
.wds-Divider--subsection {
|
|
2063
|
+
--Divider-border-width: 1px;
|
|
2064
|
+
}
|
|
2041
2065
|
.np-dropfade,
|
|
2042
2066
|
.np-dropfade-enter {
|
|
2043
2067
|
opacity: 0;
|
|
@@ -2242,9 +2266,6 @@ html:not([dir="rtl"]) .np-flow-navigation--sm .np-flow-navigation__stepper {
|
|
|
2242
2266
|
-moz-column-gap: var(--size-24);
|
|
2243
2267
|
column-gap: var(--size-24);
|
|
2244
2268
|
}
|
|
2245
|
-
.np-header--section {
|
|
2246
|
-
border-bottom: none;
|
|
2247
|
-
}
|
|
2248
2269
|
.np-header__title {
|
|
2249
2270
|
color: #5d7079;
|
|
2250
2271
|
color: var(--color-content-secondary);
|
package/build/title/Title.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var clsx = require('clsx');
|
|
4
|
-
var React = require('react');
|
|
5
4
|
var jsxRuntime = require('react/jsx-runtime');
|
|
6
5
|
var typography = require('../common/propsValues/typography.js');
|
|
7
6
|
|
|
@@ -13,29 +12,27 @@ const titleTypeMapping = {
|
|
|
13
12
|
[typography.Typography.TITLE_BODY]: 'h4',
|
|
14
13
|
[typography.Typography.TITLE_GROUP]: 'h5'
|
|
15
14
|
};
|
|
16
|
-
|
|
15
|
+
function Title({
|
|
17
16
|
as,
|
|
18
17
|
type = DEFAULT_TYPE,
|
|
19
18
|
className,
|
|
20
19
|
...props
|
|
21
|
-
}
|
|
20
|
+
}) {
|
|
22
21
|
const mapping = titleTypeMapping[type];
|
|
23
22
|
const isTypeSupported = mapping !== undefined;
|
|
24
23
|
if (isTypeSupported) {
|
|
25
24
|
const HeaderTag = as ?? mapping;
|
|
26
25
|
return /*#__PURE__*/jsxRuntime.jsx(HeaderTag, {
|
|
27
|
-
ref: ref,
|
|
28
26
|
...props,
|
|
29
27
|
className: clsx.clsx(`np-text-${type}`, className)
|
|
30
28
|
});
|
|
31
29
|
}
|
|
32
30
|
const HeaderTag = as ?? titleTypeMapping[DEFAULT_TYPE];
|
|
33
31
|
return /*#__PURE__*/jsxRuntime.jsx(HeaderTag, {
|
|
34
|
-
ref: ref,
|
|
35
32
|
...props,
|
|
36
33
|
className: clsx.clsx(`np-text-${DEFAULT_TYPE}`, className)
|
|
37
34
|
});
|
|
38
|
-
}
|
|
35
|
+
}
|
|
39
36
|
|
|
40
37
|
module.exports = Title;
|
|
41
38
|
//# sourceMappingURL=Title.js.map
|
package/build/title/Title.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Title.js","sources":["../../src/title/Title.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport {
|
|
1
|
+
{"version":3,"file":"Title.js","sources":["../../src/title/Title.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { LabelHTMLAttributes, LiHTMLAttributes, ReactHTML } from 'react';\n\nimport { TitleTypes, Typography, Heading } from '../common';\n\nconst DEFAULT_TYPE = Typography.TITLE_GROUP;\n\nconst titleTypeMapping = {\n [Typography.TITLE_SCREEN]: 'h1',\n [Typography.TITLE_SECTION]: 'h2',\n [Typography.TITLE_SUBSECTION]: 'h3',\n [Typography.TITLE_BODY]: 'h4',\n [Typography.TITLE_GROUP]: 'h5',\n} as const;\n\ntype Props = LabelHTMLAttributes<HTMLHeadingElement | HTMLSpanElement | HTMLLabelElement> &\n LiHTMLAttributes<HTMLLIElement> & {\n /**\n * Default value will based one `type` prop\n */\n as?: 'span' | 'label' | 'li' | 'legend' | Heading;\n /**\n * Default value: {@link DEFAULT_TYPE}\n */\n type?: TitleTypes;\n };\n\nfunction Title({ as, type = DEFAULT_TYPE, className, ...props }: Props) {\n const mapping = titleTypeMapping[type];\n const isTypeSupported = mapping !== undefined;\n if (isTypeSupported) {\n const HeaderTag = as ?? mapping;\n return <HeaderTag {...props} className={clsx(`np-text-${type}`, className)} />;\n }\n const HeaderTag = as ?? titleTypeMapping[DEFAULT_TYPE];\n return <HeaderTag {...props} className={clsx(`np-text-${DEFAULT_TYPE}`, className)} />;\n}\n\nexport default Title;\n"],"names":["DEFAULT_TYPE","Typography","TITLE_GROUP","titleTypeMapping","TITLE_SCREEN","TITLE_SECTION","TITLE_SUBSECTION","TITLE_BODY","Title","as","type","className","props","mapping","isTypeSupported","undefined","HeaderTag","_jsx","clsx"],"mappings":";;;;;;AAKA,MAAMA,YAAY,GAAGC,qBAAU,CAACC,WAAW,CAAA;AAE3C,MAAMC,gBAAgB,GAAG;AACvB,EAAA,CAACF,qBAAU,CAACG,YAAY,GAAG,IAAI;AAC/B,EAAA,CAACH,qBAAU,CAACI,aAAa,GAAG,IAAI;AAChC,EAAA,CAACJ,qBAAU,CAACK,gBAAgB,GAAG,IAAI;AACnC,EAAA,CAACL,qBAAU,CAACM,UAAU,GAAG,IAAI;EAC7B,CAACN,qBAAU,CAACC,WAAW,GAAG,IAAA;CAClB,CAAA;AAcV,SAASM,KAAKA,CAAC;EAAEC,EAAE;AAAEC,EAAAA,IAAI,GAAGV,YAAY;EAAEW,SAAS;EAAE,GAAGC,KAAAA;AAAc,CAAA,EAAA;AACpE,EAAA,MAAMC,OAAO,GAAGV,gBAAgB,CAACO,IAAI,CAAC,CAAA;AACtC,EAAA,MAAMI,eAAe,GAAGD,OAAO,KAAKE,SAAS,CAAA;AAC7C,EAAA,IAAID,eAAe,EAAE;AACnB,IAAA,MAAME,SAAS,GAAGP,EAAE,IAAII,OAAO,CAAA;IAC/B,oBAAOI,cAAA,CAACD,SAAS,EAAA;AAAA,MAAA,GAAKJ,KAAK;AAAED,MAAAA,SAAS,EAAEO,SAAI,CAAC,WAAWR,IAAI,CAAA,CAAE,EAAEC,SAAS,CAAA;AAAE,MAAG,CAAA;AAChF,GAAA;AACA,EAAA,MAAMK,SAAS,GAAGP,EAAE,IAAIN,gBAAgB,CAACH,YAAY,CAAC,CAAA;EACtD,oBAAOiB,cAAA,CAACD,SAAS,EAAA;AAAA,IAAA,GAAKJ,KAAK;AAAED,IAAAA,SAAS,EAAEO,SAAI,CAAC,WAAWlB,YAAY,CAAA,CAAE,EAAEW,SAAS,CAAA;AAAE,IAAG,CAAA;AACxF;;;;"}
|
package/build/title/Title.mjs
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { clsx } from 'clsx';
|
|
2
|
-
import { forwardRef } from 'react';
|
|
3
2
|
import { jsx } from 'react/jsx-runtime';
|
|
4
3
|
import { Typography } from '../common/propsValues/typography.mjs';
|
|
5
4
|
|
|
@@ -11,29 +10,27 @@ const titleTypeMapping = {
|
|
|
11
10
|
[Typography.TITLE_BODY]: 'h4',
|
|
12
11
|
[Typography.TITLE_GROUP]: 'h5'
|
|
13
12
|
};
|
|
14
|
-
|
|
13
|
+
function Title({
|
|
15
14
|
as,
|
|
16
15
|
type = DEFAULT_TYPE,
|
|
17
16
|
className,
|
|
18
17
|
...props
|
|
19
|
-
}
|
|
18
|
+
}) {
|
|
20
19
|
const mapping = titleTypeMapping[type];
|
|
21
20
|
const isTypeSupported = mapping !== undefined;
|
|
22
21
|
if (isTypeSupported) {
|
|
23
22
|
const HeaderTag = as ?? mapping;
|
|
24
23
|
return /*#__PURE__*/jsx(HeaderTag, {
|
|
25
|
-
ref: ref,
|
|
26
24
|
...props,
|
|
27
25
|
className: clsx(`np-text-${type}`, className)
|
|
28
26
|
});
|
|
29
27
|
}
|
|
30
28
|
const HeaderTag = as ?? titleTypeMapping[DEFAULT_TYPE];
|
|
31
29
|
return /*#__PURE__*/jsx(HeaderTag, {
|
|
32
|
-
ref: ref,
|
|
33
30
|
...props,
|
|
34
31
|
className: clsx(`np-text-${DEFAULT_TYPE}`, className)
|
|
35
32
|
});
|
|
36
|
-
}
|
|
33
|
+
}
|
|
37
34
|
|
|
38
35
|
export { Title as default };
|
|
39
36
|
//# sourceMappingURL=Title.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Title.mjs","sources":["../../src/title/Title.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport {
|
|
1
|
+
{"version":3,"file":"Title.mjs","sources":["../../src/title/Title.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { LabelHTMLAttributes, LiHTMLAttributes, ReactHTML } from 'react';\n\nimport { TitleTypes, Typography, Heading } from '../common';\n\nconst DEFAULT_TYPE = Typography.TITLE_GROUP;\n\nconst titleTypeMapping = {\n [Typography.TITLE_SCREEN]: 'h1',\n [Typography.TITLE_SECTION]: 'h2',\n [Typography.TITLE_SUBSECTION]: 'h3',\n [Typography.TITLE_BODY]: 'h4',\n [Typography.TITLE_GROUP]: 'h5',\n} as const;\n\ntype Props = LabelHTMLAttributes<HTMLHeadingElement | HTMLSpanElement | HTMLLabelElement> &\n LiHTMLAttributes<HTMLLIElement> & {\n /**\n * Default value will based one `type` prop\n */\n as?: 'span' | 'label' | 'li' | 'legend' | Heading;\n /**\n * Default value: {@link DEFAULT_TYPE}\n */\n type?: TitleTypes;\n };\n\nfunction Title({ as, type = DEFAULT_TYPE, className, ...props }: Props) {\n const mapping = titleTypeMapping[type];\n const isTypeSupported = mapping !== undefined;\n if (isTypeSupported) {\n const HeaderTag = as ?? mapping;\n return <HeaderTag {...props} className={clsx(`np-text-${type}`, className)} />;\n }\n const HeaderTag = as ?? titleTypeMapping[DEFAULT_TYPE];\n return <HeaderTag {...props} className={clsx(`np-text-${DEFAULT_TYPE}`, className)} />;\n}\n\nexport default Title;\n"],"names":["DEFAULT_TYPE","Typography","TITLE_GROUP","titleTypeMapping","TITLE_SCREEN","TITLE_SECTION","TITLE_SUBSECTION","TITLE_BODY","Title","as","type","className","props","mapping","isTypeSupported","undefined","HeaderTag","_jsx","clsx"],"mappings":";;;;AAKA,MAAMA,YAAY,GAAGC,UAAU,CAACC,WAAW,CAAA;AAE3C,MAAMC,gBAAgB,GAAG;AACvB,EAAA,CAACF,UAAU,CAACG,YAAY,GAAG,IAAI;AAC/B,EAAA,CAACH,UAAU,CAACI,aAAa,GAAG,IAAI;AAChC,EAAA,CAACJ,UAAU,CAACK,gBAAgB,GAAG,IAAI;AACnC,EAAA,CAACL,UAAU,CAACM,UAAU,GAAG,IAAI;EAC7B,CAACN,UAAU,CAACC,WAAW,GAAG,IAAA;CAClB,CAAA;AAcV,SAASM,KAAKA,CAAC;EAAEC,EAAE;AAAEC,EAAAA,IAAI,GAAGV,YAAY;EAAEW,SAAS;EAAE,GAAGC,KAAAA;AAAc,CAAA,EAAA;AACpE,EAAA,MAAMC,OAAO,GAAGV,gBAAgB,CAACO,IAAI,CAAC,CAAA;AACtC,EAAA,MAAMI,eAAe,GAAGD,OAAO,KAAKE,SAAS,CAAA;AAC7C,EAAA,IAAID,eAAe,EAAE;AACnB,IAAA,MAAME,SAAS,GAAGP,EAAE,IAAII,OAAO,CAAA;IAC/B,oBAAOI,GAAA,CAACD,SAAS,EAAA;AAAA,MAAA,GAAKJ,KAAK;AAAED,MAAAA,SAAS,EAAEO,IAAI,CAAC,WAAWR,IAAI,CAAA,CAAE,EAAEC,SAAS,CAAA;AAAE,MAAG,CAAA;AAChF,GAAA;AACA,EAAA,MAAMK,SAAS,GAAGP,EAAE,IAAIN,gBAAgB,CAACH,YAAY,CAAC,CAAA;EACtD,oBAAOiB,GAAA,CAACD,SAAS,EAAA;AAAA,IAAA,GAAKJ,KAAK;AAAED,IAAAA,SAAS,EAAEO,IAAI,CAAC,WAAWlB,YAAY,CAAA,CAAE,EAAEW,SAAS,CAAA;AAAE,IAAG,CAAA;AACxF;;;;"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { FunctionComponent } from 'react';
|
|
2
|
+
export interface DividerProps {
|
|
3
|
+
/** Option prop to specify DOM render element */
|
|
4
|
+
as?: 'hr' | 'div';
|
|
5
|
+
/** Optional prop to specify classNames onto the Divider */
|
|
6
|
+
className?: string;
|
|
7
|
+
/** Optional prop to specify the ID used for testing */
|
|
8
|
+
testId?: string;
|
|
9
|
+
/** Optional prop to specify the variant of the Divider */
|
|
10
|
+
variant?: 'content' | 'subsection' | 'section';
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Divider component
|
|
14
|
+
*
|
|
15
|
+
* The Divider component is used to visually separate different sections of content.
|
|
16
|
+
* It can be rendered as a horizontal line and supports various styles such as
|
|
17
|
+
* section, subsection, and content. Additionally, the Divider can include custom styles.
|
|
18
|
+
*
|
|
19
|
+
* @component
|
|
20
|
+
* @param {'hr' | 'div'} [as='hr'] - Option prop to specify DOM render element.
|
|
21
|
+
* @param {string} [className] - Optional prop to specify classNames onto the Divider.
|
|
22
|
+
* @param {string} [testId] - Optional prop to specify the ID used for testing.
|
|
23
|
+
* @param {'section' | 'subsection' | 'content'} [variant='section'] - Optional prop to specify the variant of the Divider.
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* // Example usage:
|
|
27
|
+
* import Divider from './Divider';
|
|
28
|
+
*
|
|
29
|
+
* function App() {
|
|
30
|
+
* return (
|
|
31
|
+
* <div>
|
|
32
|
+
* <p>Content above the divider</p>
|
|
33
|
+
* <Divider variant="content" />
|
|
34
|
+
* <p>Content below the divider</p>
|
|
35
|
+
* <Divider variant="subsection" />
|
|
36
|
+
* </div>
|
|
37
|
+
* );
|
|
38
|
+
* }
|
|
39
|
+
*/
|
|
40
|
+
declare const Divider: FunctionComponent<DividerProps>;
|
|
41
|
+
export default Divider;
|
|
42
|
+
//# sourceMappingURL=Divider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Divider.d.ts","sourceRoot":"","sources":["../../../src/divider/Divider.tsx"],"names":[],"mappings":"AACA,OAAc,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAEjD,MAAM,WAAW,YAAY;IAC3B,gDAAgD;IAChD,EAAE,CAAC,EAAE,IAAI,GAAG,KAAK,CAAC;IAElB,2DAA2D;IAC3D,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB,uDAAuD;IACvD,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,0DAA0D;IAC1D,OAAO,CAAC,EAAE,SAAS,GAAG,YAAY,GAAG,SAAS,CAAC;CAChD;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,QAAA,MAAM,OAAO,EAAE,iBAAiB,CAAC,YAAY,CAwB5C,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/divider/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,YAAY,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC"}
|
|
@@ -1,52 +1,28 @@
|
|
|
1
1
|
import { ActionButtonProps } from '../actionButton/ActionButton';
|
|
2
2
|
import { AriaLabelProperty, CommonProps, Heading, LinkProps } from '../common';
|
|
3
|
-
import { FunctionComponent } from 'react';
|
|
4
3
|
type ActionProps = AriaLabelProperty & {
|
|
5
4
|
text: string;
|
|
6
5
|
};
|
|
7
6
|
type ButtonActionProps = ActionProps & ActionButtonProps;
|
|
8
7
|
type LinkActionProps = ActionProps & LinkProps;
|
|
9
|
-
export
|
|
8
|
+
export type HeaderProps = CommonProps & {
|
|
10
9
|
/**
|
|
11
|
-
*
|
|
12
|
-
* is provided, a `Link` will be rendered instead of an `ActionButton`.
|
|
10
|
+
* When the `href` property is provided to the `action`, we will render a `Link` instead of a `ActionButton`.
|
|
13
11
|
*/
|
|
14
12
|
action?: ButtonActionProps | LinkActionProps;
|
|
15
|
-
/**
|
|
13
|
+
/**
|
|
14
|
+
* Override the heading element rendered for the title, useful to specify the semantics of your header.
|
|
15
|
+
*
|
|
16
|
+
* @default "h5"
|
|
17
|
+
*/
|
|
16
18
|
as?: Heading | 'legend';
|
|
17
|
-
/** Optional prop to specify classNames onto the Header */
|
|
18
|
-
className?: string;
|
|
19
|
-
/** Optional prop to specify the ID used for testing */
|
|
20
|
-
testId?: string;
|
|
21
|
-
/** Required prop to set the title of the Header. */
|
|
22
19
|
title: string;
|
|
23
|
-
|
|
24
|
-
variant?: 'section' | 'group';
|
|
25
|
-
}
|
|
20
|
+
};
|
|
26
21
|
/**
|
|
27
|
-
* Header component
|
|
28
|
-
*
|
|
29
|
-
* The header component is used to render a section header with an optional action button or link.
|
|
30
|
-
* The header component can be rendered as a `h1`, `h2`, `h3`, `h4`, `h5`, `h6`, or `legend` element.
|
|
31
|
-
*
|
|
32
|
-
* @component
|
|
33
|
-
* @param {ButtonActionProps | LinkActionProps} [action] - Optional prop to specify the action button or link.
|
|
34
|
-
* @param {Heading | 'legend'} [as='h5'] - Optional prop to override the heading element rendered for the title.
|
|
35
|
-
* @param {string} title - Required prop to set the title of the section header.
|
|
36
|
-
* @param {'group' | 'section'} [variant='group'] - Optional prop to specify the variant of the section header.
|
|
37
|
-
* @param {string} [className] - Optional prop to specify classNames onto the Header.
|
|
38
|
-
* @param {string} [testId] - Optional prop to specify the ID used for testing.
|
|
39
22
|
*
|
|
40
|
-
*
|
|
41
|
-
* // Example usage:
|
|
42
|
-
* import Header from './Header';
|
|
23
|
+
* Neptune Web: https://transferwise.github.io/neptune-web/components/content/Header
|
|
43
24
|
*
|
|
44
|
-
* function App() {
|
|
45
|
-
* return (
|
|
46
|
-
* <Header title="Header" />
|
|
47
|
-
* );
|
|
48
|
-
* }
|
|
49
25
|
*/
|
|
50
|
-
declare const Header:
|
|
26
|
+
export declare const Header: ({ action, as, title, className }: HeaderProps) => import("react").JSX.Element;
|
|
51
27
|
export default Header;
|
|
52
28
|
//# sourceMappingURL=Header.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Header.d.ts","sourceRoot":"","sources":["../../../src/header/Header.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;
|
|
1
|
+
{"version":3,"file":"Header.d.ts","sourceRoot":"","sources":["../../../src/header/Header.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AAEjE,OAAO,EAAE,iBAAiB,EAAE,WAAW,EAAE,OAAO,EAAE,SAAS,EAAc,MAAM,WAAW,CAAC;AAI3F,KAAK,WAAW,GAAG,iBAAiB,GAAG;IACrC,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AAEF,KAAK,iBAAiB,GAAG,WAAW,GAAG,iBAAiB,CAAC;AAEzD,KAAK,eAAe,GAAG,WAAW,GAAG,SAAS,CAAC;AAE/C,MAAM,MAAM,WAAW,GAAG,WAAW,GAAG;IACtC;;OAEG;IACH,MAAM,CAAC,EAAE,iBAAiB,GAAG,eAAe,CAAC;IAC7C;;;;OAIG;IACH,EAAE,CAAC,EAAE,OAAO,GAAG,QAAQ,CAAC;IACxB,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AA4BF;;;;GAIG;AACH,eAAO,MAAM,MAAM,qCAA6C,WAAW,gCA4B1E,CAAC;AAEF,eAAe,MAAM,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/header/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/header/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC"}
|
package/build/types/index.d.ts
CHANGED
|
@@ -19,7 +19,7 @@ export type { DecisionProps } from './decision/Decision';
|
|
|
19
19
|
export type { DefinitionListProps, DefinitionListDefinition } from './definitionList';
|
|
20
20
|
export type { DimmerProps } from './dimmer';
|
|
21
21
|
export type { DrawerProps } from './drawer';
|
|
22
|
-
export type {
|
|
22
|
+
export type { DividerProps } from './divider';
|
|
23
23
|
export type { EmphasisProps } from './emphasis';
|
|
24
24
|
export type { FieldProps } from './field/Field';
|
|
25
25
|
export type { InfoProps } from './info';
|
|
@@ -97,6 +97,7 @@ export { default as Decision } from './decision';
|
|
|
97
97
|
export { default as DefinitionList } from './definitionList';
|
|
98
98
|
export { default as Dimmer } from './dimmer';
|
|
99
99
|
export { default as Display } from './display';
|
|
100
|
+
export { default as Divider } from './divider';
|
|
100
101
|
export { default as Drawer } from './drawer';
|
|
101
102
|
export { default as DropFade } from './dropFade';
|
|
102
103
|
export { default as Emphasis } from './emphasis';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,YAAY,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AACjE,YAAY,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACxD,YAAY,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AACjG,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAClE,YAAY,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAC5C,YAAY,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,YAAY,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAC;AACxC,YAAY,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC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AAU,CAAC"}
|
|
@@ -8,8 +8,6 @@ export type Props = AnchorHTMLAttributes<HTMLAnchorElement> & {
|
|
|
8
8
|
*
|
|
9
9
|
* Documentation: https://transferwise.github.io/neptune-web/components/content/Link
|
|
10
10
|
*/
|
|
11
|
-
declare const Link: import("react").
|
|
12
|
-
type?: LinkLarge | LinkDefault;
|
|
13
|
-
} & import("react").RefAttributes<HTMLAnchorElement>>;
|
|
11
|
+
declare const Link: ({ className, children, href, target, type, "aria-label": ariaLabel, onClick, ...props }: Props) => import("react").JSX.Element;
|
|
14
12
|
export default Link;
|
|
15
13
|
//# sourceMappingURL=Link.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Link.d.ts","sourceRoot":"","sources":["../../../src/link/Link.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,oBAAoB,
|
|
1
|
+
{"version":3,"file":"Link.d.ts","sourceRoot":"","sources":["../../../src/link/Link.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,oBAAoB,EAAE,MAAM,OAAO,CAAC;AAG7C,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAInD,MAAM,MAAM,KAAK,GAAG,oBAAoB,CAAC,iBAAiB,CAAC,GAAG;IAAE,IAAI,CAAC,EAAE,SAAS,GAAG,WAAW,CAAA;CAAE,CAAC;AAEjG;;;;GAIG;AACH,QAAA,MAAM,IAAI,4FASP,KAAK,gCAkBP,CAAC;AAEF,eAAe,IAAI,CAAC"}
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { LabelHTMLAttributes, LiHTMLAttributes } from 'react';
|
|
2
2
|
import { TitleTypes, Heading } from '../common';
|
|
3
|
-
|
|
3
|
+
type Props = LabelHTMLAttributes<HTMLHeadingElement | HTMLSpanElement | HTMLLabelElement> & LiHTMLAttributes<HTMLLIElement> & {
|
|
4
4
|
/**
|
|
5
5
|
* Default value will based one `type` prop
|
|
6
6
|
*/
|
|
7
|
-
as?:
|
|
7
|
+
as?: 'span' | 'label' | 'li' | 'legend' | Heading;
|
|
8
8
|
/**
|
|
9
9
|
* Default value: {@link DEFAULT_TYPE}
|
|
10
10
|
*/
|
|
11
11
|
type?: TitleTypes;
|
|
12
|
-
}
|
|
12
|
+
};
|
|
13
|
+
declare function Title({ as, type, className, ...props }: Props): import("react").JSX.Element;
|
|
13
14
|
export default Title;
|
|
14
15
|
//# sourceMappingURL=Title.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Title.d.ts","sourceRoot":"","sources":["../../../src/title/Title.tsx"],"names":[],"mappings":"AACA,OAAO,
|
|
1
|
+
{"version":3,"file":"Title.d.ts","sourceRoot":"","sources":["../../../src/title/Title.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,gBAAgB,EAAa,MAAM,OAAO,CAAC;AAEzE,OAAO,EAAE,UAAU,EAAc,OAAO,EAAE,MAAM,WAAW,CAAC;AAY5D,KAAK,KAAK,GAAG,mBAAmB,CAAC,kBAAkB,GAAG,eAAe,GAAG,gBAAgB,CAAC,GACvF,gBAAgB,CAAC,aAAa,CAAC,GAAG;IAChC;;OAEG;IACH,EAAE,CAAC,EAAE,MAAM,GAAG,OAAO,GAAG,IAAI,GAAG,QAAQ,GAAG,OAAO,CAAC;IAClD;;OAEG;IACH,IAAI,CAAC,EAAE,UAAU,CAAC;CACnB,CAAC;AAEJ,iBAAS,KAAK,CAAC,EAAE,EAAE,EAAE,IAAmB,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,+BASrE;AAED,eAAe,KAAK,CAAC"}
|