@cupra/ui-react 1.0.0-canary.2 → 1.0.0-canary.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +21 -8
- package/{THIRD-PARTY-LICENSES.MD → THIRD_PARTY_LICENSES.MD} +3 -3
- package/dist/components/Accordion/Accordion.d.ts +1 -1
- package/dist/components/Accordion/Accordion.js +1 -1
- package/dist/components/Avatar/Avatar.d.ts +1 -1
- package/dist/components/Avatar/Avatar.js +8 -7
- package/dist/components/Bullets/Bullets.d.ts +1 -1
- package/dist/components/Bullets/Bullets.js +1 -1
- package/dist/components/Button/Button.d.ts +1 -1
- package/dist/components/Button/Button.js +7 -6
- package/dist/components/CarouselIndicator/CarouselIndicator.d.ts +1 -1
- package/dist/components/CarouselIndicator/CarouselIndicator.js +1 -1
- package/dist/components/Checkbox/Checkbox.d.ts +1 -1
- package/dist/components/Checkbox/Checkbox.js +7 -6
- package/dist/components/Chip/Chip.d.ts +1 -1
- package/dist/components/Chip/Chip.js +1 -1
- package/dist/components/Chips/Chips.d.ts +1 -1
- package/dist/components/Chips/Chips.js +7 -6
- package/dist/components/Currency/Currency.d.ts +1 -1
- package/dist/components/Currency/Currency.js +1 -1
- package/dist/components/Dialog/Dialog.d.ts +1 -1
- package/dist/components/Dialog/Dialog.js +4 -3
- package/dist/components/DialogBody/DialogBody.d.ts +1 -1
- package/dist/components/DialogBody/DialogBody.js +1 -1
- package/dist/components/DialogFooter/DialogFooter.d.ts +1 -1
- package/dist/components/DialogFooter/DialogFooter.js +1 -1
- package/dist/components/DialogHeader/DialogHeader.d.ts +1 -1
- package/dist/components/DialogHeader/DialogHeader.js +1 -1
- package/dist/components/Divider/Divider.d.ts +1 -1
- package/dist/components/Divider/Divider.js +1 -1
- package/dist/components/Hyperlink/Hyperlink.d.ts +1 -1
- package/dist/components/Hyperlink/Hyperlink.js +6 -5
- package/dist/components/Icon/Icon.d.ts +1 -1
- package/dist/components/Icon/Icon.js +1 -1
- package/dist/components/IconButton/IconButton.d.ts +1 -1
- package/dist/components/IconButton/IconButton.js +7 -6
- package/dist/components/Input/Input.d.ts +1 -1
- package/dist/components/Input/Input.js +1 -1
- package/dist/components/InteractiveCard/InteractiveCard.d.ts +1 -1
- package/dist/components/InteractiveCard/InteractiveCard.js +5 -4
- package/dist/components/LinkButton/LinkButton.d.ts +1 -1
- package/dist/components/LinkButton/LinkButton.js +4 -3
- package/dist/components/Loader/Loader.d.ts +4 -1
- package/dist/components/Loader/Loader.js +16 -13
- package/dist/components/Logo/Logo.d.ts +1 -1
- package/dist/components/Logo/Logo.js +1 -1
- package/dist/components/MapPin/MapPin.d.ts +1 -1
- package/dist/components/MapPin/MapPin.js +8 -7
- package/dist/components/Modal/Modal.d.ts +1 -1
- package/dist/components/Modal/Modal.js +2 -1
- package/dist/components/PasswordInput/PasswordInput.d.ts +1 -1
- package/dist/components/PasswordInput/PasswordInput.js +33 -35
- package/dist/components/PickerItem/PickerItem.d.ts +1 -1
- package/dist/components/PickerItem/PickerItem.js +1 -1
- package/dist/components/Radio/Radio.d.ts +1 -1
- package/dist/components/Radio/Radio.js +7 -6
- package/dist/components/RadioButton/RadioButton.d.ts +1 -1
- package/dist/components/RadioButton/RadioButton.js +1 -1
- package/dist/components/RadioButtonGroup/RadioButtonGroup.d.ts +1 -1
- package/dist/components/RadioButtonGroup/RadioButtonGroup.js +1 -1
- package/dist/components/Search/Search.d.ts +1 -1
- package/dist/components/Search/Search.js +1 -1
- package/dist/components/SearchInput/SearchInput.d.ts +1 -1
- package/dist/components/SearchInput/SearchInput.js +8 -7
- package/dist/components/SecondaryNavigation/SecondaryNavigation.d.ts +1 -1
- package/dist/components/SecondaryNavigation/SecondaryNavigation.js +2 -1
- package/dist/components/SegmentedControl/SegmentedControl.d.ts +1 -1
- package/dist/components/SegmentedControl/SegmentedControl.js +8 -7
- package/dist/components/Select/Select.d.ts +1 -1
- package/dist/components/Select/Select.js +1 -1
- package/dist/components/Selection/Selection.d.ts +1 -1
- package/dist/components/Selection/Selection.js +1 -1
- package/dist/components/SidebarNavigation/SidebarNavigation.d.ts +1 -1
- package/dist/components/SidebarNavigation/SidebarNavigation.js +1 -1
- package/dist/components/Slider/Slider.d.ts +2 -2
- package/dist/components/Slider/Slider.js +1 -1
- package/dist/components/StaticBox/StaticBox.d.ts +1 -1
- package/dist/components/StaticBox/StaticBox.js +7 -6
- package/dist/components/Stepper/Stepper.d.ts +1 -1
- package/dist/components/Stepper/Stepper.js +1 -1
- package/dist/components/Tabs/Tabs.d.ts +1 -1
- package/dist/components/Tabs/Tabs.js +11 -10
- package/dist/components/Tag/Tag.d.ts +1 -1
- package/dist/components/Tag/Tag.js +8 -7
- package/dist/components/Text/Text.d.ts +1 -1
- package/dist/components/Text/Text.js +1 -1
- package/dist/components/TextInput/TextInput.d.ts +1 -1
- package/dist/components/TextInput/TextInput.js +15 -14
- package/dist/components/Textarea/Textarea.d.ts +1 -1
- package/dist/components/Textarea/Textarea.js +4 -3
- package/dist/components/ThemeProvider/ThemeProvider.d.ts +1 -1
- package/dist/components/ThemeProvider/ThemeProvider.js +1 -1
- package/dist/components/Toast/Toast.d.ts +1 -1
- package/dist/components/Toast/Toast.js +1 -1
- package/dist/components/ToastMessage/ToastMessage.d.ts +1 -1
- package/dist/components/ToastMessage/ToastMessage.js +7 -6
- package/dist/components/ToggleButton/ToggleButton.d.ts +1 -1
- package/dist/components/ToggleButton/ToggleButton.js +4 -3
- package/dist/components/ToggleSwitch/ToggleSwitch.d.ts +1 -1
- package/dist/components/ToggleSwitch/ToggleSwitch.js +9 -8
- package/dist/components/Tooltip/Tooltip.d.ts +1 -1
- package/dist/components/Tooltip/Tooltip.js +6 -5
- package/dist/hooks/useBreakpoint.js +13 -13
- package/dist/hooks/useHandleEvent.js +18 -16
- package/package.json +20 -9
- package/dist/packages/ui-kit/dist-react/index.js +0 -9221
- package/dist/packages/ui-kit/dist-react/utils/breakpoints.js +0 -11
- package/dist/packages/ui-kit/dist-react/utils/debounce.js +0 -11
package/README.md
CHANGED
|
@@ -18,10 +18,9 @@ If you need a **framework-agnostic** solution, consider `@cupra/ui-kit` (Web Com
|
|
|
18
18
|
|
|
19
19
|
This library currently provides **official support for React 18**.
|
|
20
20
|
|
|
21
|
-
- **Supported React versions:** `>=18.3.1 <
|
|
22
|
-
- **React 19:** not officially supported yet. Work is in progress to add full support.
|
|
21
|
+
- **Supported React versions:** `>=18.3.1 <20`
|
|
23
22
|
|
|
24
|
-
Projects using React
|
|
23
|
+
Projects using other React versions may still install and use the library, but behaviour is not guaranteed until official support is released.
|
|
25
24
|
|
|
26
25
|
## Installation
|
|
27
26
|
|
|
@@ -48,6 +47,14 @@ npmRegistryServer: "https://registry.npmjs.org"
|
|
|
48
47
|
|
|
49
48
|
---
|
|
50
49
|
|
|
50
|
+
## Documentation & Live Playground
|
|
51
|
+
|
|
52
|
+
You can explore all `ui-react` Components, their APIs, theming options and live examples in the online documentation and playground:
|
|
53
|
+
|
|
54
|
+
[https://diagonal.cupra.com/ui-react/index.html](https://diagonal.cupra.com/ui-react/index.html)
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
|
|
51
58
|
## Versioning and Release Channels
|
|
52
59
|
|
|
53
60
|
This package is distributed through npm using **two release channels**.
|
|
@@ -109,7 +116,10 @@ npm install @cupra/ui-react@0.1.4-canary.2
|
|
|
109
116
|
|
|
110
117
|
## Usage
|
|
111
118
|
|
|
112
|
-
|
|
119
|
+
Import components via subpaths. Do not import from the package index:
|
|
120
|
+
- @cupra/ui-react → React wrappers built on top of the Web Components (e.g. `import { Button } from '@cupra/ui-react/Button'`)
|
|
121
|
+
|
|
122
|
+
Wrap your React app with `ThemeProvider`.
|
|
113
123
|
The provider requires **three props**:
|
|
114
124
|
|
|
115
125
|
| Prop | Type | Required | Description |
|
|
@@ -123,14 +133,16 @@ If `loadFonts` or `loadStyles` are `false`, you must manually include `<link>` t
|
|
|
123
133
|
### Option A — Manual CSS and font links
|
|
124
134
|
|
|
125
135
|
```tsx
|
|
126
|
-
import { ThemeProvider
|
|
136
|
+
import { ThemeProvider } from '@cupra/ui-react/ThemeProvider';
|
|
137
|
+
import { Button } from '@cupra/ui-react/Button';
|
|
138
|
+
import { Icon } from '@cupra/ui-react/Icon';
|
|
127
139
|
|
|
128
140
|
export function App() {
|
|
129
141
|
return (
|
|
130
142
|
<>
|
|
131
143
|
<link rel="preload" as="style" href="https://ds-assets.cupra.com/[version]/styles/cupra/theme.css" />
|
|
132
144
|
<link rel="stylesheet" href="https://ds-assets.cupra.com/[version]/styles/cupra/theme.css" />
|
|
133
|
-
<ThemeProvider theme="cupra" loadFonts={false} loadStyles={false}>
|
|
145
|
+
<ThemeProvider theme="cupra-diagonal" loadFonts={false} loadStyles={false}>
|
|
134
146
|
<Button variant="destructive" icon-name="filters-background">Click me</Button>
|
|
135
147
|
<Icon icon-name="filters-background" />
|
|
136
148
|
</ThemeProvider>
|
|
@@ -142,11 +154,12 @@ export function App() {
|
|
|
142
154
|
### Option B — Provider loads assets automatically
|
|
143
155
|
|
|
144
156
|
```tsx
|
|
145
|
-
import { ThemeProvider
|
|
157
|
+
import { ThemeProvider } from '@cupra/ui-react/ThemeProvider';
|
|
158
|
+
import { Button } from '@cupra/ui-react/Button';
|
|
146
159
|
|
|
147
160
|
export function App() {
|
|
148
161
|
return (
|
|
149
|
-
<ThemeProvider theme="cupra" loadFonts={true} loadStyles={true}>
|
|
162
|
+
<ThemeProvider theme="cupra-diagonal" loadFonts={true} loadStyles={true}>
|
|
150
163
|
<Button variant="primary">Button</Button>
|
|
151
164
|
</ThemeProvider>
|
|
152
165
|
);
|
|
@@ -3,13 +3,13 @@ https://www.npmjs.com/package/generate-license-file
|
|
|
3
3
|
|
|
4
4
|
The following npm package may be included in this product:
|
|
5
5
|
|
|
6
|
-
- @cupra/ui-kit@
|
|
6
|
+
- @cupra/ui-kit@1.0.0-canary.3
|
|
7
7
|
|
|
8
8
|
This package contains the following license:
|
|
9
9
|
|
|
10
|
-
# SEAT, S.A. Library EULA
|
|
10
|
+
# SEAT, S.A. Library EULA 1.0
|
|
11
11
|
|
|
12
|
-
SEAT, S.A.U. (hereinafter, “SEAT”) is a Spanish entity domiciled in Martorell (Barcelona), Autovía A-2, Km. 585, with a Tax Identification Number (C.I.F.) A-28.049.161, duly registered in the Mercantile Registry of Barcelona in Volume 23.662, folio 1, page number B-56.855 and whose contact email is
|
|
12
|
+
SEAT, S.A.U. (hereinafter, “SEAT”) is a Spanish entity domiciled in Martorell (Barcelona), Autovía A-2, Km. 585, with a Tax Identification Number (C.I.F.) A-28.049.161, duly registered in the Mercantile Registry of Barcelona in Volume 23.662, folio 1, page number B-56.855 and whose contact email is **ds.support@seat.es**
|
|
13
13
|
SEAT releases this End-User License Agreement (“EULA”) to specify the rights and obligations when using a library or package applicable to this EULA (“Library”).
|
|
14
14
|
|
|
15
15
|
## Library Specification
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DsAccordionAttrs } from '@cupra/ui-kit/react/types/ds-accordion';
|
|
2
|
-
import '@cupra/ui-kit/react';
|
|
2
|
+
import '@cupra/ui-kit/react/ds-accordion';
|
|
3
3
|
import { type ReactElement } from 'react';
|
|
4
4
|
type Children = JSX.Element | JSX.Element[] | string;
|
|
5
5
|
interface AccordionProps extends DsAccordionAttrs {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-accordion";
|
|
3
3
|
const n = ({ children: t, ...r }) => /* @__PURE__ */ o("ds-accordion-react", { ...r, children: t }), e = ({ children: t }) => /* @__PURE__ */ o("div", { slot: "title", children: t }), c = ({ children: t }) => /* @__PURE__ */ o("div", { slot: "content", children: t });
|
|
4
4
|
n.Title = e;
|
|
5
5
|
n.Content = c;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ReactElement, ReactNode } from 'react';
|
|
2
|
-
import '@cupra/ui-kit/react';
|
|
2
|
+
import '@cupra/ui-kit/react/ds-avatar';
|
|
3
3
|
import type { DsAvatarAttrs } from '@cupra/ui-kit/react/types/ds-avatar';
|
|
4
4
|
export type AvatarProps = DsAvatarAttrs & {
|
|
5
5
|
className?: string;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import
|
|
1
|
+
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
+
import "@cupra/ui-kit/react/utils/breakpoints";
|
|
3
|
+
import { isValidElement as n, cloneElement as s } from "react";
|
|
3
4
|
import { useHandleEvent as c } from "../../hooks/useHandleEvent.js";
|
|
4
|
-
import "
|
|
5
|
-
function
|
|
6
|
-
const { className:
|
|
7
|
-
return /* @__PURE__ */
|
|
5
|
+
import "@cupra/ui-kit/react/ds-avatar";
|
|
6
|
+
function E(t) {
|
|
7
|
+
const { className: r, onClick: e, image: o, ...a } = t, { ref: i } = c({ click: e }), l = o && n(o) ? s(o, { slot: "media", ...o.props }) : null;
|
|
8
|
+
return /* @__PURE__ */ m("ds-avatar-react", { ref: i, class: r, ...a, children: l });
|
|
8
9
|
}
|
|
9
10
|
export {
|
|
10
|
-
|
|
11
|
+
E as Avatar
|
|
11
12
|
};
|
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
import { jsx as c } from "react/jsx-runtime";
|
|
2
|
+
import "@cupra/ui-kit/react/utils/breakpoints";
|
|
2
3
|
import "react";
|
|
3
4
|
import { useHandleEvent as m } from "../../hooks/useHandleEvent.js";
|
|
4
|
-
import "
|
|
5
|
-
function
|
|
6
|
-
const { className: r, children:
|
|
5
|
+
import "@cupra/ui-kit/react/ds-button";
|
|
6
|
+
function d(o) {
|
|
7
|
+
const { className: r, children: i, onClick: s, size: t, ...e } = o, { ref: n } = m({ click: s });
|
|
7
8
|
return /* @__PURE__ */ c(
|
|
8
9
|
"ds-button-react",
|
|
9
10
|
{
|
|
10
11
|
ref: n,
|
|
11
12
|
size: typeof t == "string" ? t : JSON.stringify(t),
|
|
12
13
|
class: r,
|
|
13
|
-
...
|
|
14
|
-
children:
|
|
14
|
+
...e,
|
|
15
|
+
children: i
|
|
15
16
|
}
|
|
16
17
|
);
|
|
17
18
|
}
|
|
18
19
|
export {
|
|
19
|
-
|
|
20
|
+
d as Button
|
|
20
21
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DsCarouselIndicatorAttrs } from '@cupra/ui-kit/react/types/ds-carousel-indicator';
|
|
2
2
|
import { type ReactElement } from 'react';
|
|
3
|
-
import '@cupra/ui-kit/react';
|
|
3
|
+
import '@cupra/ui-kit/react/ds-carousel-indicator';
|
|
4
4
|
type CarouselIndicatorProps = DsCarouselIndicatorAttrs & {
|
|
5
5
|
className?: string;
|
|
6
6
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-carousel-indicator";
|
|
3
3
|
function i(r) {
|
|
4
4
|
const { className: o, children: c, ...s } = r;
|
|
5
5
|
return /* @__PURE__ */ t("ds-carousel-indicator-react", { class: o, ...s });
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ReactElement } from 'react';
|
|
2
|
-
import '@cupra/ui-kit/react';
|
|
2
|
+
import '@cupra/ui-kit/react/ds-checkbox';
|
|
3
3
|
import { DsCheckboxAttrs } from '@cupra/ui-kit/react/types/ds-checkbox';
|
|
4
4
|
interface CheckboxProps extends DsCheckboxAttrs {
|
|
5
5
|
onChange?: (event: CustomEvent) => void;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { jsx as c } from "react/jsx-runtime";
|
|
2
|
+
import "@cupra/ui-kit/react/utils/breakpoints";
|
|
2
3
|
import "react";
|
|
3
|
-
import { useHandleEvent as
|
|
4
|
-
import "
|
|
5
|
-
function
|
|
6
|
-
const { ref:
|
|
7
|
-
return /* @__PURE__ */ c("ds-checkbox-react", { ref:
|
|
4
|
+
import { useHandleEvent as m } from "../../hooks/useHandleEvent.js";
|
|
5
|
+
import "@cupra/ui-kit/react/ds-checkbox";
|
|
6
|
+
function x({ onChange: o, children: r, ...t }) {
|
|
7
|
+
const { ref: e } = m({ change: o });
|
|
8
|
+
return /* @__PURE__ */ c("ds-checkbox-react", { ref: e, ...t, children: r });
|
|
8
9
|
}
|
|
9
10
|
export {
|
|
10
|
-
|
|
11
|
+
x as Checkbox
|
|
11
12
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DsChipAttrs } from '@cupra/ui-kit/react/types/ds-chip';
|
|
2
2
|
import { type ReactElement } from 'react';
|
|
3
|
-
import '@cupra/ui-kit/react';
|
|
3
|
+
import '@cupra/ui-kit/react/ds-chip';
|
|
4
4
|
type ChipProps = DsChipAttrs & {
|
|
5
5
|
className?: string;
|
|
6
6
|
children: JSX.Element | JSX.Element[] | string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as c } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-chip";
|
|
3
3
|
function p(r) {
|
|
4
4
|
const { className: o, children: s, ...t } = r;
|
|
5
5
|
return /* @__PURE__ */ c("ds-chip-react", { class: o, ...t, children: s });
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type DsChipsAttrs } from '@cupra/ui-kit/react/types/ds-chips';
|
|
2
2
|
import { type ReactElement } from 'react';
|
|
3
|
-
import '@cupra/ui-kit/react';
|
|
3
|
+
import '@cupra/ui-kit/react/ds-chips';
|
|
4
4
|
type ChipsProps = DsChipsAttrs & {
|
|
5
5
|
className?: string;
|
|
6
6
|
children: JSX.Element | JSX.Element[] | string;
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import { jsx as c } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-chips";
|
|
3
|
+
import "@cupra/ui-kit/react/utils/breakpoints";
|
|
3
4
|
import "react";
|
|
4
5
|
import { useHandleEvent as i } from "../../hooks/useHandleEvent.js";
|
|
5
|
-
function
|
|
6
|
-
const { className:
|
|
7
|
-
"ds-chips:change":
|
|
6
|
+
function f(r) {
|
|
7
|
+
const { className: o, children: s, onChange: t, ...e } = r, { ref: n } = i({
|
|
8
|
+
"ds-chips:change": t
|
|
8
9
|
});
|
|
9
|
-
return /* @__PURE__ */ c("ds-chips-react", { ref: n, class:
|
|
10
|
+
return /* @__PURE__ */ c("ds-chips-react", { ref: n, class: o, ...e, children: s });
|
|
10
11
|
}
|
|
11
12
|
export {
|
|
12
|
-
|
|
13
|
+
f as Chips
|
|
13
14
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DsDialogAttrs } from '@cupra/ui-kit/react/types/ds-dialog';
|
|
2
2
|
import { type ReactNode } from 'react';
|
|
3
|
-
import '@cupra/ui-kit/react';
|
|
3
|
+
import '@cupra/ui-kit/react/ds-dialog';
|
|
4
4
|
type DialogProps = DsDialogAttrs & {
|
|
5
5
|
className?: string;
|
|
6
6
|
withPortal?: boolean;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-dialog";
|
|
3
|
+
import "@cupra/ui-kit/react/utils/breakpoints";
|
|
3
4
|
import "react";
|
|
4
5
|
import { useHandleEvent as c } from "../../hooks/useHandleEvent.js";
|
|
5
|
-
function
|
|
6
|
+
function g(e) {
|
|
6
7
|
const { className: n, children: l, onClose: s, withPortal: i, ...o } = e, { ref: a } = c({
|
|
7
8
|
"ds-dialog:close": s
|
|
8
9
|
});
|
|
@@ -11,5 +12,5 @@ function u(e) {
|
|
|
11
12
|
return i ? /* @__PURE__ */ t("ds-portal-react", { style: { display: "none" }, children: r }) : r;
|
|
12
13
|
}
|
|
13
14
|
export {
|
|
14
|
-
|
|
15
|
+
g as Dialog
|
|
15
16
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DsDialogBodyAttrs } from '@cupra/ui-kit/react/types/ds-dialog-body';
|
|
2
2
|
import { type ReactElement } from 'react';
|
|
3
|
-
import '@cupra/ui-kit/react';
|
|
3
|
+
import '@cupra/ui-kit/react/ds-dialog-body';
|
|
4
4
|
type DialogBodyProps = DsDialogBodyAttrs & {
|
|
5
5
|
className?: string;
|
|
6
6
|
children?: JSX.Element | JSX.Element[] | string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-dialog-body";
|
|
3
3
|
function i(o) {
|
|
4
4
|
const { className: r, children: s, ...t } = o;
|
|
5
5
|
return /* @__PURE__ */ a("ds-dialog-body-react", { class: r, ...t, children: s });
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DsDialogFooterAttrs } from '@cupra/ui-kit/react/types/ds-dialog-footer';
|
|
2
2
|
import { type ReactElement } from 'react';
|
|
3
|
-
import '@cupra/ui-kit/react';
|
|
3
|
+
import '@cupra/ui-kit/react/ds-dialog-footer';
|
|
4
4
|
type DialogFooterProps = DsDialogFooterAttrs & {
|
|
5
5
|
className?: string;
|
|
6
6
|
children?: JSX.Element | JSX.Element[] | string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-dialog-footer";
|
|
3
3
|
function i(o) {
|
|
4
4
|
const { className: r, children: t, ...e } = o;
|
|
5
5
|
return /* @__PURE__ */ s("ds-dialog-footer-react", { class: r, ...e, children: t });
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DsDialogHeaderAttrs } from '@cupra/ui-kit/react/types/ds-dialog-header';
|
|
2
2
|
import { type ReactElement } from 'react';
|
|
3
|
-
import '@cupra/ui-kit/react';
|
|
3
|
+
import '@cupra/ui-kit/react/ds-dialog-header';
|
|
4
4
|
type DialogHeaderProps = DsDialogHeaderAttrs & {
|
|
5
5
|
className?: string;
|
|
6
6
|
children?: JSX.Element | JSX.Element[] | string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-dialog-header";
|
|
3
3
|
function i(r) {
|
|
4
4
|
const { className: e, children: o, ...a } = r;
|
|
5
5
|
return /* @__PURE__ */ s("ds-dialog-header-react", { class: e, ...a, children: o });
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DsDividerAttrs } from '@cupra/ui-kit/react/types/ds-divider';
|
|
2
2
|
import { type ReactElement } from 'react';
|
|
3
|
-
import '@cupra/ui-kit/react';
|
|
3
|
+
import '@cupra/ui-kit/react/ds-divider';
|
|
4
4
|
export interface DividerProps extends DsDividerAttrs {
|
|
5
5
|
className?: string;
|
|
6
6
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ReactElement } from 'react';
|
|
2
|
-
import '@cupra/ui-kit/react';
|
|
2
|
+
import '@cupra/ui-kit/react/ds-hyperlink';
|
|
3
3
|
import { DsHyperlinkAttrs } from '@cupra/ui-kit/react/types/ds-hyperlink';
|
|
4
4
|
export type HyperlinkProps = DsHyperlinkAttrs & {
|
|
5
5
|
children: JSX.Element | JSX.Element[] | string;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { jsx as i } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-hyperlink";
|
|
3
|
+
import "@cupra/ui-kit/react/utils/breakpoints";
|
|
3
4
|
import "react";
|
|
4
5
|
import { useHandleEvent as n } from "../../hooks/useHandleEvent.js";
|
|
5
|
-
function
|
|
6
|
-
const { ref:
|
|
7
|
-
return /* @__PURE__ */ i("ds-hyperlink-react", { ref:
|
|
6
|
+
function s({ children: r, onClick: t, ...o }) {
|
|
7
|
+
const { ref: e } = n({ click: t });
|
|
8
|
+
return /* @__PURE__ */ i("ds-hyperlink-react", { ref: e, ...o, children: r });
|
|
8
9
|
}
|
|
9
10
|
export {
|
|
10
|
-
|
|
11
|
+
s as Hyperlink
|
|
11
12
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-icon";
|
|
3
3
|
function a(o) {
|
|
4
4
|
const { "icon-name": n, className: c, ...r } = o;
|
|
5
5
|
return /* @__PURE__ */ e("ds-icon-react", { "icon-name": n, class: c, ...r });
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ReactElement } from 'react';
|
|
2
|
-
import '@cupra/ui-kit/react';
|
|
2
|
+
import '@cupra/ui-kit/react/ds-icon-button';
|
|
3
3
|
import { type DsIconButtonAttrs } from '@cupra/ui-kit/react/types/ds-icon-button';
|
|
4
4
|
type IconButtonProps = DsIconButtonAttrs & {
|
|
5
5
|
className?: string;
|
|
@@ -1,19 +1,20 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-icon-button";
|
|
3
|
+
import "@cupra/ui-kit/react/utils/breakpoints";
|
|
3
4
|
import "react";
|
|
4
5
|
import { useHandleEvent as c } from "../../hooks/useHandleEvent.js";
|
|
5
|
-
function
|
|
6
|
-
const { className: r, onClick:
|
|
6
|
+
function u(o) {
|
|
7
|
+
const { className: r, onClick: i, size: t, ...n } = o, { ref: s } = c({ click: i });
|
|
7
8
|
return /* @__PURE__ */ e(
|
|
8
9
|
"ds-icon-button-react",
|
|
9
10
|
{
|
|
10
|
-
ref:
|
|
11
|
+
ref: s,
|
|
11
12
|
size: typeof t == "string" ? t : JSON.stringify(t),
|
|
12
13
|
class: r,
|
|
13
|
-
...
|
|
14
|
+
...n
|
|
14
15
|
}
|
|
15
16
|
);
|
|
16
17
|
}
|
|
17
18
|
export {
|
|
18
|
-
|
|
19
|
+
u as IconButton
|
|
19
20
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DsInputAttrs } from '@cupra/ui-kit/react/types/ds-input';
|
|
2
|
-
import '@cupra/ui-kit/react';
|
|
2
|
+
import '@cupra/ui-kit/react/ds-input';
|
|
3
3
|
import { ChangeEvent, FormEvent, ForwardRefExoticComponent, KeyboardEvent, RefAttributes } from 'react';
|
|
4
4
|
type InputProps = DsInputAttrs & {
|
|
5
5
|
className?: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-input";
|
|
3
3
|
import { useHandleEvent as s } from "../../hooks/useHandleEvent.js";
|
|
4
4
|
import { forwardRef as i, useImperativeHandle as u } from "react";
|
|
5
5
|
const c = i(
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ReactElement } from 'react';
|
|
2
|
-
import '@cupra/ui-kit/react';
|
|
2
|
+
import '@cupra/ui-kit/react/ds-interactive-card';
|
|
3
3
|
import type { DsInteractiveCardAttrs } from '@cupra/ui-kit/react/types/ds-interactive-card';
|
|
4
4
|
type Children = JSX.Element | JSX.Element[] | string;
|
|
5
5
|
type InteractiveCardProps = DsInteractiveCardAttrs & {
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import "@cupra/ui-kit/react/utils/breakpoints";
|
|
2
3
|
import "react";
|
|
3
|
-
import { useHandleEvent as
|
|
4
|
-
import "
|
|
4
|
+
import { useHandleEvent as u } from "../../hooks/useHandleEvent.js";
|
|
5
|
+
import "@cupra/ui-kit/react/ds-interactive-card";
|
|
5
6
|
function e(t) {
|
|
6
|
-
const { className: d, children: v, onClick: m, ...C } = t, { ref:
|
|
7
|
-
return /* @__PURE__ */ r("ds-interactive-card-react", { ref:
|
|
7
|
+
const { className: d, children: v, onClick: m, ...C } = t, { ref: p } = u({ click: m });
|
|
8
|
+
return /* @__PURE__ */ r("ds-interactive-card-react", { ref: p, class: d, ...C, children: v });
|
|
8
9
|
}
|
|
9
10
|
const a = ({ children: t }) => /* @__PURE__ */ r("div", { slot: "title", children: t }), i = ({ children: t }) => /* @__PURE__ */ r("div", { slot: "subtitle", children: t }), n = ({ children: t }) => /* @__PURE__ */ r("div", { slot: "meta", children: t }), o = ({ children: t }) => /* @__PURE__ */ r("div", { slot: "content", children: t }), l = ({ children: t }) => /* @__PURE__ */ r("div", { slot: "cta", children: t }), s = ({ children: t }) => /* @__PURE__ */ r("div", { slot: "error-title", children: t }), c = ({ children: t }) => /* @__PURE__ */ r("div", { slot: "error-text", children: t });
|
|
10
11
|
e.Title = a;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ReactElement } from 'react';
|
|
2
|
-
import '@cupra/ui-kit/react';
|
|
2
|
+
import '@cupra/ui-kit/react/ds-link-button';
|
|
3
3
|
import { DsLinkButtonAttrs } from '@cupra/ui-kit/react/types/ds-link-button';
|
|
4
4
|
type LinkButtonProps = DsLinkButtonAttrs & {
|
|
5
5
|
children: JSX.Element | JSX.Element[] | string;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { jsx as i } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-link-button";
|
|
3
|
+
import "@cupra/ui-kit/react/utils/breakpoints";
|
|
3
4
|
import "react";
|
|
4
5
|
import { useHandleEvent as e } from "../../hooks/useHandleEvent.js";
|
|
5
|
-
function
|
|
6
|
+
function s({ children: t, onClick: o, ...r }) {
|
|
6
7
|
const { ref: n } = e({ click: o });
|
|
7
8
|
return /* @__PURE__ */ i("ds-link-button-react", { ref: n, ...r, children: t });
|
|
8
9
|
}
|
|
9
10
|
export {
|
|
10
|
-
|
|
11
|
+
s as LinkButton
|
|
11
12
|
};
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { type ReactElement } from 'react';
|
|
2
|
-
import '@cupra/ui-kit/react';
|
|
2
|
+
import '@cupra/ui-kit/react/ds-loader-bar';
|
|
3
|
+
import '@cupra/ui-kit/react/ds-loader-dots';
|
|
4
|
+
import '@cupra/ui-kit/react/ds-loader-logo';
|
|
5
|
+
import '@cupra/ui-kit/react/ds-loader-spinner';
|
|
3
6
|
import { DsLoaderBarsAttrs } from '@cupra/ui-kit/react/types/ds-loader-bar';
|
|
4
7
|
import { DsLoaderDotsAttrs } from '@cupra/ui-kit/react/types/ds-loader-dots';
|
|
5
8
|
import { DsLoaderLogoAttrs } from '@cupra/ui-kit/react/types/ds-loader-logo';
|
|
@@ -1,24 +1,27 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import "
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import "@cupra/ui-kit/react/ds-loader-bar";
|
|
3
|
+
import "@cupra/ui-kit/react/ds-loader-dots";
|
|
4
|
+
import "@cupra/ui-kit/react/ds-loader-logo";
|
|
5
|
+
import "@cupra/ui-kit/react/ds-loader-spinner";
|
|
6
6
|
function t(r) {
|
|
7
|
-
return /* @__PURE__ */
|
|
7
|
+
return /* @__PURE__ */ o("ds-loader-logo-react", { ...r });
|
|
8
|
+
}
|
|
9
|
+
function e(r) {
|
|
10
|
+
return /* @__PURE__ */ o("ds-loader-bar-react", { ...r });
|
|
8
11
|
}
|
|
9
12
|
function n(r) {
|
|
10
|
-
return /* @__PURE__ */
|
|
13
|
+
return /* @__PURE__ */ o("ds-loader-dots-react", { ...r });
|
|
11
14
|
}
|
|
12
15
|
function d(r) {
|
|
13
|
-
return /* @__PURE__ */
|
|
16
|
+
return /* @__PURE__ */ o("ds-loader-spinner-react", { ...r, children: r.text && /* @__PURE__ */ o("div", { slot: "text", children: r.text }) });
|
|
14
17
|
}
|
|
15
|
-
const
|
|
16
|
-
Logo:
|
|
17
|
-
Bar:
|
|
18
|
+
const u = {
|
|
19
|
+
Logo: t,
|
|
20
|
+
Bar: e,
|
|
18
21
|
Dots: n,
|
|
19
22
|
Spinner: d
|
|
20
23
|
};
|
|
21
24
|
export {
|
|
22
|
-
|
|
23
|
-
|
|
25
|
+
u as Loader,
|
|
26
|
+
t as LoaderLogo
|
|
24
27
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import "
|
|
2
|
+
import "@cupra/ui-kit/react/ds-logo";
|
|
3
3
|
function a(o) {
|
|
4
4
|
const { className: r, children: c, ...s } = o;
|
|
5
5
|
return /* @__PURE__ */ t("ds-logo-react", { class: r, ...s });
|