@porsche-design-system/components-react 4.0.0-beta.4 → 4.0.0-rc.1
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/CHANGELOG.md +72 -4
- package/cjs/lib/components/banner.wrapper.cjs +3 -3
- package/esm/lib/components/accordion.wrapper.d.ts +8 -0
- package/esm/lib/components/banner.wrapper.d.ts +37 -15
- package/esm/lib/components/banner.wrapper.mjs +3 -3
- package/esm/lib/components/button-pure.wrapper.d.ts +22 -0
- package/esm/lib/components/button-tile.wrapper.d.ts +20 -0
- package/esm/lib/components/button.wrapper.d.ts +14 -0
- package/esm/lib/components/canvas.wrapper.d.ts +6 -0
- package/esm/lib/components/carousel.wrapper.d.ts +22 -0
- package/esm/lib/components/checkbox.wrapper.d.ts +24 -0
- package/esm/lib/components/crest.wrapper.d.ts +2 -0
- package/esm/lib/components/display.wrapper.d.ts +8 -0
- package/esm/lib/components/divider.wrapper.d.ts +4 -0
- package/esm/lib/components/drilldown-item.wrapper.d.ts +6 -0
- package/esm/lib/components/drilldown-link.wrapper.d.ts +4 -0
- package/esm/lib/components/drilldown.wrapper.d.ts +2 -0
- package/esm/lib/components/fieldset.wrapper.d.ts +10 -0
- package/esm/lib/components/flag.wrapper.d.ts +4 -0
- package/esm/lib/components/flyout.wrapper.d.ts +12 -0
- package/esm/lib/components/heading.wrapper.d.ts +12 -0
- package/esm/lib/components/icon.wrapper.d.ts +6 -0
- package/esm/lib/components/inline-notification.wrapper.d.ts +14 -0
- package/esm/lib/components/input-date.wrapper.d.ts +24 -0
- package/esm/lib/components/input-email.wrapper.d.ts +28 -0
- package/esm/lib/components/input-month.wrapper.d.ts +24 -0
- package/esm/lib/components/input-number.wrapper.d.ts +28 -0
- package/esm/lib/components/input-password.wrapper.d.ts +26 -0
- package/esm/lib/components/input-search.wrapper.d.ts +28 -0
- package/esm/lib/components/input-tel.wrapper.d.ts +26 -0
- package/esm/lib/components/input-text.wrapper.d.ts +26 -0
- package/esm/lib/components/input-time.wrapper.d.ts +24 -0
- package/esm/lib/components/input-url.wrapper.d.ts +26 -0
- package/esm/lib/components/input-week.wrapper.d.ts +24 -0
- package/esm/lib/components/link-pure.wrapper.d.ts +18 -0
- package/esm/lib/components/link-tile-product.wrapper.d.ts +8 -0
- package/esm/lib/components/link-tile.wrapper.d.ts +14 -0
- package/esm/lib/components/link.wrapper.d.ts +10 -0
- package/esm/lib/components/modal.wrapper.d.ts +12 -0
- package/esm/lib/components/model-signature.wrapper.d.ts +12 -0
- package/esm/lib/components/multi-select-option.wrapper.d.ts +2 -0
- package/esm/lib/components/multi-select.wrapper.d.ts +20 -0
- package/esm/lib/components/optgroup.wrapper.d.ts +2 -0
- package/esm/lib/components/pagination.wrapper.d.ts +10 -0
- package/esm/lib/components/pin-code.wrapper.d.ts +24 -0
- package/esm/lib/components/popover.wrapper.d.ts +2 -0
- package/esm/lib/components/radio-group-option.wrapper.d.ts +4 -0
- package/esm/lib/components/radio-group.wrapper.d.ts +22 -0
- package/esm/lib/components/scroller.wrapper.d.ts +6 -0
- package/esm/lib/components/segmented-control-item.wrapper.d.ts +2 -0
- package/esm/lib/components/segmented-control.wrapper.d.ts +18 -0
- package/esm/lib/components/select-option.wrapper.d.ts +2 -0
- package/esm/lib/components/select.wrapper.d.ts +20 -0
- package/esm/lib/components/sheet.wrapper.d.ts +8 -0
- package/esm/lib/components/spinner.wrapper.d.ts +4 -0
- package/esm/lib/components/stepper-horizontal-item.wrapper.d.ts +2 -0
- package/esm/lib/components/stepper-horizontal.wrapper.d.ts +2 -0
- package/esm/lib/components/switch.wrapper.d.ts +14 -0
- package/esm/lib/components/table-cell.wrapper.d.ts +2 -0
- package/esm/lib/components/table-head-cell.wrapper.d.ts +4 -0
- package/esm/lib/components/table.wrapper.d.ts +6 -0
- package/esm/lib/components/tabs-bar.wrapper.d.ts +6 -0
- package/esm/lib/components/tabs.wrapper.d.ts +8 -0
- package/esm/lib/components/tag-dismissible.wrapper.d.ts +2 -0
- package/esm/lib/components/tag.wrapper.d.ts +6 -0
- package/esm/lib/components/text-list.wrapper.d.ts +2 -0
- package/esm/lib/components/text.wrapper.d.ts +14 -0
- package/esm/lib/components/textarea.wrapper.d.ts +30 -0
- package/esm/lib/components/wordmark.wrapper.d.ts +4 -0
- package/esm/lib/types.d.ts +5 -0
- package/global-styles/cn/index.css +1 -0
- package/global-styles/index.css +1 -0
- package/global-styles/variables.css +1 -0
- package/package.json +4 -2
- package/ssr/cjs/components/dist/styles/esm/styles-entry.cjs +723 -775
- package/ssr/cjs/components/dist/utils/esm/utils-entry.cjs +16 -77
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/components/banner.wrapper.cjs +4 -5
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/banner.cjs +11 -6
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/button.cjs +1 -1
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/inline-notification.cjs +4 -6
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/state-message.cjs +1 -4
- package/ssr/esm/components/dist/styles/esm/styles-entry.mjs +723 -775
- package/ssr/esm/components/dist/utils/esm/utils-entry.mjs +15 -76
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/banner.wrapper.mjs +4 -5
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/banner.mjs +11 -6
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/button.mjs +1 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/inline-notification.mjs +5 -7
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/state-message.mjs +2 -5
- package/ssr/esm/lib/components/accordion.wrapper.d.ts +8 -0
- package/ssr/esm/lib/components/banner.wrapper.d.ts +37 -15
- package/ssr/esm/lib/components/button-pure.wrapper.d.ts +22 -0
- package/ssr/esm/lib/components/button-tile.wrapper.d.ts +20 -0
- package/ssr/esm/lib/components/button.wrapper.d.ts +14 -0
- package/ssr/esm/lib/components/canvas.wrapper.d.ts +6 -0
- package/ssr/esm/lib/components/carousel.wrapper.d.ts +22 -0
- package/ssr/esm/lib/components/checkbox.wrapper.d.ts +24 -0
- package/ssr/esm/lib/components/crest.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/display.wrapper.d.ts +8 -0
- package/ssr/esm/lib/components/divider.wrapper.d.ts +4 -0
- package/ssr/esm/lib/components/drilldown-item.wrapper.d.ts +6 -0
- package/ssr/esm/lib/components/drilldown-link.wrapper.d.ts +4 -0
- package/ssr/esm/lib/components/drilldown.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/fieldset.wrapper.d.ts +10 -0
- package/ssr/esm/lib/components/flag.wrapper.d.ts +4 -0
- package/ssr/esm/lib/components/flyout.wrapper.d.ts +12 -0
- package/ssr/esm/lib/components/heading.wrapper.d.ts +12 -0
- package/ssr/esm/lib/components/icon.wrapper.d.ts +6 -0
- package/ssr/esm/lib/components/inline-notification.wrapper.d.ts +14 -0
- package/ssr/esm/lib/components/input-date.wrapper.d.ts +24 -0
- package/ssr/esm/lib/components/input-email.wrapper.d.ts +28 -0
- package/ssr/esm/lib/components/input-month.wrapper.d.ts +24 -0
- package/ssr/esm/lib/components/input-number.wrapper.d.ts +28 -0
- package/ssr/esm/lib/components/input-password.wrapper.d.ts +26 -0
- package/ssr/esm/lib/components/input-search.wrapper.d.ts +28 -0
- package/ssr/esm/lib/components/input-tel.wrapper.d.ts +26 -0
- package/ssr/esm/lib/components/input-text.wrapper.d.ts +26 -0
- package/ssr/esm/lib/components/input-time.wrapper.d.ts +24 -0
- package/ssr/esm/lib/components/input-url.wrapper.d.ts +26 -0
- package/ssr/esm/lib/components/input-week.wrapper.d.ts +24 -0
- package/ssr/esm/lib/components/link-pure.wrapper.d.ts +18 -0
- package/ssr/esm/lib/components/link-tile-product.wrapper.d.ts +8 -0
- package/ssr/esm/lib/components/link-tile.wrapper.d.ts +14 -0
- package/ssr/esm/lib/components/link.wrapper.d.ts +10 -0
- package/ssr/esm/lib/components/modal.wrapper.d.ts +12 -0
- package/ssr/esm/lib/components/model-signature.wrapper.d.ts +12 -0
- package/ssr/esm/lib/components/multi-select-option.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/multi-select.wrapper.d.ts +20 -0
- package/ssr/esm/lib/components/optgroup.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/pagination.wrapper.d.ts +10 -0
- package/ssr/esm/lib/components/pin-code.wrapper.d.ts +24 -0
- package/ssr/esm/lib/components/popover.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/radio-group-option.wrapper.d.ts +4 -0
- package/ssr/esm/lib/components/radio-group.wrapper.d.ts +22 -0
- package/ssr/esm/lib/components/scroller.wrapper.d.ts +6 -0
- package/ssr/esm/lib/components/segmented-control-item.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/segmented-control.wrapper.d.ts +18 -0
- package/ssr/esm/lib/components/select-option.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/select.wrapper.d.ts +20 -0
- package/ssr/esm/lib/components/sheet.wrapper.d.ts +8 -0
- package/ssr/esm/lib/components/spinner.wrapper.d.ts +4 -0
- package/ssr/esm/lib/components/stepper-horizontal-item.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/stepper-horizontal.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/switch.wrapper.d.ts +14 -0
- package/ssr/esm/lib/components/table-cell.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/table-head-cell.wrapper.d.ts +4 -0
- package/ssr/esm/lib/components/table.wrapper.d.ts +6 -0
- package/ssr/esm/lib/components/tabs-bar.wrapper.d.ts +6 -0
- package/ssr/esm/lib/components/tabs.wrapper.d.ts +8 -0
- package/ssr/esm/lib/components/tag-dismissible.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/tag.wrapper.d.ts +6 -0
- package/ssr/esm/lib/components/text-list.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/text.wrapper.d.ts +14 -0
- package/ssr/esm/lib/components/textarea.wrapper.d.ts +30 -0
- package/ssr/esm/lib/components/wordmark.wrapper.d.ts +4 -0
- package/ssr/esm/lib/dsr-components/banner.d.ts +2 -2
- package/ssr/esm/lib/types.d.ts +5 -0
- package/tailwindcss/index.css +73 -14
package/CHANGELOG.md
CHANGED
|
@@ -14,6 +14,70 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0),
|
|
|
14
14
|
|
|
15
15
|
## [Unreleased]
|
|
16
16
|
|
|
17
|
+
## [4.0.0-rc.1] - 2026-04-07
|
|
18
|
+
|
|
19
|
+
### Added
|
|
20
|
+
|
|
21
|
+
- `Banner`:
|
|
22
|
+
- Prop `position` with values: `BreakpointCustomizable<'top' | 'bottom'>` (default: `{ base: 'bottom', s: 'top' }`)
|
|
23
|
+
([#4264](https://github.com/porsche-design-system/porsche-design-system/pull/4264))
|
|
24
|
+
- CSS Variable `--p-banner-top`: Defines the distance from the top of the viewport. Only takes effect when the
|
|
25
|
+
`position` property is set to `top` (at the respective breakpoint).
|
|
26
|
+
([#4264](https://github.com/porsche-design-system/porsche-design-system/pull/4264))
|
|
27
|
+
- CSS Variable `--p-banner-bottom`: Defines the distance from the bottom of the viewport. Only takes effect when the
|
|
28
|
+
`position` property is set to `bottom` (at the respective breakpoint).
|
|
29
|
+
([#4264](https://github.com/porsche-design-system/porsche-design-system/pull/4264))
|
|
30
|
+
- CSS Variable `--p-banner-max-w`: Defines the maximum width of the banner.
|
|
31
|
+
([#4264](https://github.com/porsche-design-system/porsche-design-system/pull/4264))
|
|
32
|
+
- CSS Variable `--p-banner-inset-x`: Defines the horizontal offset of the banner from the edges of the viewport.
|
|
33
|
+
([#4264](https://github.com/porsche-design-system/porsche-design-system/pull/4264))
|
|
34
|
+
- `Tailwind CSS`: `--spacing-static-2xs`
|
|
35
|
+
([#4262](https://github.com/porsche-design-system/porsche-design-system/pull/4262))
|
|
36
|
+
- `SCSS`: `$spacing-static-2xs` ([#4262](https://github.com/porsche-design-system/porsche-design-system/pull/4262))
|
|
37
|
+
- `Tokens`, `Emotion`, `Vanilla Extract`: `spacingStatic2xs`
|
|
38
|
+
([#4262](https://github.com/porsche-design-system/porsche-design-system/pull/4262))
|
|
39
|
+
|
|
40
|
+
### Changed
|
|
41
|
+
|
|
42
|
+
- `Banner`, `Inline Notification`: Improve visual appearance
|
|
43
|
+
([#4264](https://github.com/porsche-design-system/porsche-design-system/pull/4264))
|
|
44
|
+
- `Banner`: `max-width` is now `100ch` by default to increase readability. Use CSS Variable `--p-banner-max-w` and
|
|
45
|
+
`--p-banner-inset-x` to set custom `max-width` and horizontal offset.
|
|
46
|
+
([#4264](https://github.com/porsche-design-system/porsche-design-system/pull/4264))
|
|
47
|
+
- `SCSS`:
|
|
48
|
+
- All `prose-heading-*` and `prose-text-*` mixins set `color` to the primary token by default, overridable via the CSS
|
|
49
|
+
cascade ([#4262](https://github.com/porsche-design-system/porsche-design-system/pull/4262))
|
|
50
|
+
- `Emotion`, `Vanilla Extract`:
|
|
51
|
+
- All `proseHeading*` and `proseText*` style objects set `color` to the primary token by default, overridable in your
|
|
52
|
+
own styles ([#4262](https://github.com/porsche-design-system/porsche-design-system/pull/4262))
|
|
53
|
+
|
|
54
|
+
### Fixed
|
|
55
|
+
|
|
56
|
+
- `Accordion`: summary overlapping details when custom padding is applied
|
|
57
|
+
([#4263](https://github.com/porsche-design-system/porsche-design-system/pull/4263))
|
|
58
|
+
- `Scroller`: mask not rendering on ios when `scrollbar` set to `true`
|
|
59
|
+
([#4263](https://github.com/porsche-design-system/porsche-design-system/pull/4263))
|
|
60
|
+
- `Modal`, `Sheet`: visual bug in the corner when scrolled
|
|
61
|
+
([#4272](https://github.com/porsche-design-system/porsche-design-system/pull/4272))
|
|
62
|
+
- `Model Signature`: `--p-model-signature-color` not working with gradients
|
|
63
|
+
([#4272](https://github.com/porsche-design-system/porsche-design-system/pull/4272))
|
|
64
|
+
- `Tabs Bar`: flickering of active tab in certain cases
|
|
65
|
+
([#4263](https://github.com/porsche-design-system/porsche-design-system/pull/4263))
|
|
66
|
+
- Global Styles: missing individual export for `color-scheme.css`
|
|
67
|
+
([#4260](https://github.com/porsche-design-system/porsche-design-system/pull/4260))
|
|
68
|
+
- `Table`: double focus outline of sort buttons
|
|
69
|
+
([#4270](https://github.com/porsche-design-system/porsche-design-system/pull/4270))
|
|
70
|
+
|
|
71
|
+
### Deprecated
|
|
72
|
+
|
|
73
|
+
- `Banner`:
|
|
74
|
+
- CSS Variable `--p-banner-position-top` (use `--p-banner-top` instead)
|
|
75
|
+
([#4264](https://github.com/porsche-design-system/porsche-design-system/pull/4264))
|
|
76
|
+
- CSS Variable `--p-banner-position-bottom` (use `--p-banner-bottom` instead)
|
|
77
|
+
([#4264](https://github.com/porsche-design-system/porsche-design-system/pull/4264))
|
|
78
|
+
|
|
79
|
+
## [4.0.0-rc.0] - 2026-03-27
|
|
80
|
+
|
|
17
81
|
## [4.0.0-beta.4] - 2026-03-25
|
|
18
82
|
|
|
19
83
|
### Added
|
|
@@ -59,6 +123,9 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0),
|
|
|
59
123
|
|
|
60
124
|
### Added
|
|
61
125
|
|
|
126
|
+
- Storefront: documentation for integrating Porsche Design System with AI coding assistants like GitHub Copilot and
|
|
127
|
+
Cursor to generate accessible code that follows WCAG 2.2 AA standards.
|
|
128
|
+
([#4147](https://github.com/porsche-design-system/porsche-design-system/pull/4147))
|
|
62
129
|
- `Tokens`: `typescale3Xl`, `typescale4Xl`, `typescale5Xl`
|
|
63
130
|
([#4246](https://github.com/porsche-design-system/porsche-design-system/pull/4246))
|
|
64
131
|
- `Tailwind CSS`: `--text-3xl`, `--text-4xl`, `--text-5xl`, `.prose-heading-3xl`, `.prose-heading-4xl`,
|
|
@@ -3518,9 +3585,10 @@ major version.
|
|
|
3518
3585
|
|
|
3519
3586
|
##### Content Wrapper:
|
|
3520
3587
|
|
|
3521
|
-
- Component is deprecated and will be removed with the next major release. Please use
|
|
3522
|
-
|
|
3523
|
-
layout needs for a harmonic
|
|
3588
|
+
- Component is deprecated and will be removed with the next major release. Please use
|
|
3589
|
+
**[Porsche Grid](/tailwindcss/grid/examples/)** instead, which is based on
|
|
3590
|
+
[CSS Grid](https://css-tricks.com/snippets/css/complete-guide-grid) covering the specific layout needs for a harmonic
|
|
3591
|
+
appearance across all digital Porsche touch-points.
|
|
3524
3592
|
|
|
3525
3593
|
##### Flex:
|
|
3526
3594
|
|
|
@@ -3532,7 +3600,7 @@ major version.
|
|
|
3532
3600
|
|
|
3533
3601
|
- Component is deprecated and will be removed with the next major release. In general, please use native
|
|
3534
3602
|
[CSS Grid](https://css-tricks.com/snippets/css/complete-guide-grid) in combination with
|
|
3535
|
-
**[Porsche Grid](/
|
|
3603
|
+
**[Porsche Grid](/tailwindcss/grid/examples/)** instead for better performance and more standardized layout technique.
|
|
3536
3604
|
|
|
3537
3605
|
##### Headline:
|
|
3538
3606
|
|
|
@@ -6,14 +6,14 @@ var react = require('react');
|
|
|
6
6
|
var hooks = require('../../hooks.cjs');
|
|
7
7
|
var utils = require('../../utils.cjs');
|
|
8
8
|
|
|
9
|
-
const PBanner = /*#__PURE__*/ react.forwardRef(({ description = '', dismissButton = true, heading = '', headingTag = 'h5', onDismiss, open = false, state = 'info', className, ...rest }, ref) => {
|
|
9
|
+
const PBanner = /*#__PURE__*/ react.forwardRef(({ description = '', dismissButton = true, heading = '', headingTag = 'h5', onDismiss, open = false, position = { base: 'bottom', s: 'top' }, state = 'info', className, ...rest }, ref) => {
|
|
10
10
|
const elementRef = react.useRef(undefined);
|
|
11
11
|
hooks.useEventCallback(elementRef, 'dismiss', onDismiss);
|
|
12
12
|
const WebComponentTag = hooks.usePrefix('p-banner');
|
|
13
|
-
const propsToSync = [description, dismissButton, heading, headingTag, open, state];
|
|
13
|
+
const propsToSync = [description, dismissButton, heading, headingTag, open, position, state];
|
|
14
14
|
hooks.useBrowserLayoutEffect(() => {
|
|
15
15
|
const { current } = elementRef;
|
|
16
|
-
['description', 'dismissButton', 'heading', 'headingTag', 'open', 'state'].forEach((propName, i) => (current[propName] = propsToSync[i]));
|
|
16
|
+
['description', 'dismissButton', 'heading', 'headingTag', 'open', 'position', 'state'].forEach((propName, i) => (current[propName] = propsToSync[i]));
|
|
17
17
|
}, propsToSync);
|
|
18
18
|
const props = {
|
|
19
19
|
...rest,
|
|
@@ -3,10 +3,12 @@ import type { AccordionAlignMarker, AccordionBackground, AccordionHeadingTag, Ac
|
|
|
3
3
|
export type PAccordionProps = BaseProps & {
|
|
4
4
|
/**
|
|
5
5
|
* Aligns the marker within the summary section.
|
|
6
|
+
* @default 'end'
|
|
6
7
|
*/
|
|
7
8
|
alignMarker?: AccordionAlignMarker;
|
|
8
9
|
/**
|
|
9
10
|
* Defines the background color. Use `frosted` only on images, videos or gradients.
|
|
11
|
+
* @default 'none'
|
|
10
12
|
*/
|
|
11
13
|
background?: AccordionBackground;
|
|
12
14
|
/**
|
|
@@ -19,6 +21,7 @@ export type PAccordionProps = BaseProps & {
|
|
|
19
21
|
heading?: string;
|
|
20
22
|
/**
|
|
21
23
|
* @deprecated Will be removed in the next major release. Use the `summary` slot instead. Sets the heading tag for proper semantic structure within the page.
|
|
24
|
+
* @default 'h2'
|
|
22
25
|
*/
|
|
23
26
|
headingTag?: AccordionHeadingTag;
|
|
24
27
|
/**
|
|
@@ -31,6 +34,7 @@ export type PAccordionProps = BaseProps & {
|
|
|
31
34
|
open?: boolean;
|
|
32
35
|
/**
|
|
33
36
|
* @deprecated Will be removed in the next major release. Use the `summary` slot instead. Controls the heading size in the summary section (only applies when using the `heading` prop or `heading` slot).
|
|
37
|
+
* @default 'small'
|
|
34
38
|
*/
|
|
35
39
|
size?: BreakpointCustomizable<AccordionSize>;
|
|
36
40
|
/**
|
|
@@ -41,10 +45,12 @@ export type PAccordionProps = BaseProps & {
|
|
|
41
45
|
export declare const PAccordion: import("react").ForwardRefExoticComponent<Omit<import("react").DOMAttributes<{}>, "onChange" | "onInput" | "onToggle"> & Pick<import("react").HTMLAttributes<{}>, "suppressHydrationWarning" | "autoFocus" | "className" | "dir" | "hidden" | "id" | "inert" | "lang" | "slot" | "style" | "tabIndex" | "title" | "translate" | "role"> & {
|
|
42
46
|
/**
|
|
43
47
|
* Aligns the marker within the summary section.
|
|
48
|
+
* @default 'end'
|
|
44
49
|
*/
|
|
45
50
|
alignMarker?: AccordionAlignMarker;
|
|
46
51
|
/**
|
|
47
52
|
* Defines the background color. Use `frosted` only on images, videos or gradients.
|
|
53
|
+
* @default 'none'
|
|
48
54
|
*/
|
|
49
55
|
background?: AccordionBackground;
|
|
50
56
|
/**
|
|
@@ -57,6 +63,7 @@ export declare const PAccordion: import("react").ForwardRefExoticComponent<Omit<
|
|
|
57
63
|
heading?: string;
|
|
58
64
|
/**
|
|
59
65
|
* @deprecated Will be removed in the next major release. Use the `summary` slot instead. Sets the heading tag for proper semantic structure within the page.
|
|
66
|
+
* @default 'h2'
|
|
60
67
|
*/
|
|
61
68
|
headingTag?: AccordionHeadingTag;
|
|
62
69
|
/**
|
|
@@ -69,6 +76,7 @@ export declare const PAccordion: import("react").ForwardRefExoticComponent<Omit<
|
|
|
69
76
|
open?: boolean;
|
|
70
77
|
/**
|
|
71
78
|
* @deprecated Will be removed in the next major release. Use the `summary` slot instead. Controls the heading size in the summary section (only applies when using the `heading` prop or `heading` slot).
|
|
79
|
+
* @default 'small'
|
|
72
80
|
*/
|
|
73
81
|
size?: BreakpointCustomizable<AccordionSize>;
|
|
74
82
|
/**
|
|
@@ -1,62 +1,84 @@
|
|
|
1
1
|
import type { BaseProps } from '../../BaseProps';
|
|
2
|
-
import type { BannerHeadingTag, BannerState } from '../types';
|
|
2
|
+
import type { BannerHeadingTag, BreakpointCustomizable, BannerPosition, BannerState } from '../types';
|
|
3
3
|
export type PBannerProps = BaseProps & {
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
5
|
+
* Sets the description text of the banner.
|
|
6
|
+
* @default ''
|
|
6
7
|
*/
|
|
7
8
|
description?: string;
|
|
8
9
|
/**
|
|
9
|
-
*
|
|
10
|
+
* Shows a dismiss button allowing the banner to be closed.
|
|
11
|
+
* @default true
|
|
10
12
|
*/
|
|
11
13
|
dismissButton?: boolean;
|
|
12
14
|
/**
|
|
13
|
-
*
|
|
15
|
+
* Sets the heading text of the banner.
|
|
16
|
+
* @default ''
|
|
14
17
|
*/
|
|
15
18
|
heading?: string;
|
|
16
19
|
/**
|
|
17
|
-
* Sets
|
|
20
|
+
* Sets the heading tag for proper semantic structure within the page.
|
|
21
|
+
* @default 'h5'
|
|
18
22
|
*/
|
|
19
23
|
headingTag?: BannerHeadingTag;
|
|
20
24
|
/**
|
|
21
|
-
* Emitted when the
|
|
25
|
+
* Emitted when the banner is requested to be dismissed.
|
|
22
26
|
*/
|
|
23
27
|
onDismiss?: (event: CustomEvent<void>) => void;
|
|
24
28
|
/**
|
|
25
|
-
*
|
|
29
|
+
* Controls whether the banner is open or closed.
|
|
30
|
+
* @default false
|
|
26
31
|
*/
|
|
27
32
|
open: boolean;
|
|
28
33
|
/**
|
|
29
|
-
*
|
|
34
|
+
* Sets the position of the banner.
|
|
35
|
+
* @default { base: 'bottom', s: 'top' }
|
|
36
|
+
*/
|
|
37
|
+
position?: BreakpointCustomizable<BannerPosition>;
|
|
38
|
+
/**
|
|
39
|
+
* Defines the visual state of the banner.
|
|
40
|
+
* @default 'info'
|
|
30
41
|
*/
|
|
31
42
|
state?: BannerState;
|
|
32
43
|
};
|
|
33
44
|
export declare const PBanner: import("react").ForwardRefExoticComponent<Omit<import("react").DOMAttributes<{}>, "onChange" | "onInput" | "onToggle"> & Pick<import("react").HTMLAttributes<{}>, "suppressHydrationWarning" | "autoFocus" | "className" | "dir" | "hidden" | "id" | "inert" | "lang" | "slot" | "style" | "tabIndex" | "title" | "translate" | "role"> & {
|
|
34
45
|
/**
|
|
35
|
-
*
|
|
46
|
+
* Sets the description text of the banner.
|
|
47
|
+
* @default ''
|
|
36
48
|
*/
|
|
37
49
|
description?: string;
|
|
38
50
|
/**
|
|
39
|
-
*
|
|
51
|
+
* Shows a dismiss button allowing the banner to be closed.
|
|
52
|
+
* @default true
|
|
40
53
|
*/
|
|
41
54
|
dismissButton?: boolean;
|
|
42
55
|
/**
|
|
43
|
-
*
|
|
56
|
+
* Sets the heading text of the banner.
|
|
57
|
+
* @default ''
|
|
44
58
|
*/
|
|
45
59
|
heading?: string;
|
|
46
60
|
/**
|
|
47
|
-
* Sets
|
|
61
|
+
* Sets the heading tag for proper semantic structure within the page.
|
|
62
|
+
* @default 'h5'
|
|
48
63
|
*/
|
|
49
64
|
headingTag?: BannerHeadingTag;
|
|
50
65
|
/**
|
|
51
|
-
* Emitted when the
|
|
66
|
+
* Emitted when the banner is requested to be dismissed.
|
|
52
67
|
*/
|
|
53
68
|
onDismiss?: (event: CustomEvent<void>) => void;
|
|
54
69
|
/**
|
|
55
|
-
*
|
|
70
|
+
* Controls whether the banner is open or closed.
|
|
71
|
+
* @default false
|
|
56
72
|
*/
|
|
57
73
|
open: boolean;
|
|
58
74
|
/**
|
|
59
|
-
*
|
|
75
|
+
* Sets the position of the banner.
|
|
76
|
+
* @default { base: 'bottom', s: 'top' }
|
|
77
|
+
*/
|
|
78
|
+
position?: BreakpointCustomizable<BannerPosition>;
|
|
79
|
+
/**
|
|
80
|
+
* Defines the visual state of the banner.
|
|
81
|
+
* @default 'info'
|
|
60
82
|
*/
|
|
61
83
|
state?: BannerState;
|
|
62
84
|
} & {
|
|
@@ -4,14 +4,14 @@ import { forwardRef, useRef } from 'react';
|
|
|
4
4
|
import { useEventCallback, usePrefix, useBrowserLayoutEffect, useMergedClass } from '../../hooks.mjs';
|
|
5
5
|
import { syncRef } from '../../utils.mjs';
|
|
6
6
|
|
|
7
|
-
const PBanner = /*#__PURE__*/ forwardRef(({ description = '', dismissButton = true, heading = '', headingTag = 'h5', onDismiss, open = false, state = 'info', className, ...rest }, ref) => {
|
|
7
|
+
const PBanner = /*#__PURE__*/ forwardRef(({ description = '', dismissButton = true, heading = '', headingTag = 'h5', onDismiss, open = false, position = { base: 'bottom', s: 'top' }, state = 'info', className, ...rest }, ref) => {
|
|
8
8
|
const elementRef = useRef(undefined);
|
|
9
9
|
useEventCallback(elementRef, 'dismiss', onDismiss);
|
|
10
10
|
const WebComponentTag = usePrefix('p-banner');
|
|
11
|
-
const propsToSync = [description, dismissButton, heading, headingTag, open, state];
|
|
11
|
+
const propsToSync = [description, dismissButton, heading, headingTag, open, position, state];
|
|
12
12
|
useBrowserLayoutEffect(() => {
|
|
13
13
|
const { current } = elementRef;
|
|
14
|
-
['description', 'dismissButton', 'heading', 'headingTag', 'open', 'state'].forEach((propName, i) => (current[propName] = propsToSync[i]));
|
|
14
|
+
['description', 'dismissButton', 'heading', 'headingTag', 'open', 'position', 'state'].forEach((propName, i) => (current[propName] = propsToSync[i]));
|
|
15
15
|
}, propsToSync);
|
|
16
16
|
const props = {
|
|
17
17
|
...rest,
|
|
@@ -3,10 +3,12 @@ import type { BreakpointCustomizable, ButtonPureAlignLabel, SelectedAriaAttribut
|
|
|
3
3
|
export type PButtonPureProps = BaseProps & {
|
|
4
4
|
/**
|
|
5
5
|
* Displays the button in its active state.
|
|
6
|
+
* @default false
|
|
6
7
|
*/
|
|
7
8
|
active?: boolean;
|
|
8
9
|
/**
|
|
9
10
|
* Aligns the label.
|
|
11
|
+
* @default 'end'
|
|
10
12
|
*/
|
|
11
13
|
alignLabel?: BreakpointCustomizable<ButtonPureAlignLabel>;
|
|
12
14
|
/**
|
|
@@ -15,10 +17,12 @@ export type PButtonPureProps = BaseProps & {
|
|
|
15
17
|
aria?: SelectedAriaAttributes<ButtonPureAriaAttribute>;
|
|
16
18
|
/**
|
|
17
19
|
* The color.
|
|
20
|
+
* @default 'primary'
|
|
18
21
|
*/
|
|
19
22
|
color?: ButtonPureColor;
|
|
20
23
|
/**
|
|
21
24
|
* Disables the button. No events will be triggered while disabled state is active.
|
|
25
|
+
* @default false
|
|
22
26
|
*/
|
|
23
27
|
disabled?: boolean;
|
|
24
28
|
/**
|
|
@@ -27,10 +31,12 @@ export type PButtonPureProps = BaseProps & {
|
|
|
27
31
|
form?: string;
|
|
28
32
|
/**
|
|
29
33
|
* Shows or hides the label. For better accessibility, it is recommended to show the label.
|
|
34
|
+
* @default false
|
|
30
35
|
*/
|
|
31
36
|
hideLabel?: BreakpointCustomizable<boolean>;
|
|
32
37
|
/**
|
|
33
38
|
* The icon shown.
|
|
39
|
+
* @default 'arrow-right'
|
|
34
40
|
*/
|
|
35
41
|
icon?: ButtonPureIcon;
|
|
36
42
|
/**
|
|
@@ -39,6 +45,7 @@ export type PButtonPureProps = BaseProps & {
|
|
|
39
45
|
iconSource?: string;
|
|
40
46
|
/**
|
|
41
47
|
* Disables the button and shows a loading indicator. No events will be triggered while loading state is active.
|
|
48
|
+
* @default false
|
|
42
49
|
*/
|
|
43
50
|
loading?: boolean;
|
|
44
51
|
/**
|
|
@@ -47,18 +54,22 @@ export type PButtonPureProps = BaseProps & {
|
|
|
47
54
|
name?: string;
|
|
48
55
|
/**
|
|
49
56
|
* Size of the button.
|
|
57
|
+
* @default 'sm'
|
|
50
58
|
*/
|
|
51
59
|
size?: BreakpointCustomizable<ButtonPureSize>;
|
|
52
60
|
/**
|
|
53
61
|
* Stretches the area between icon and label to max available space.
|
|
62
|
+
* @default false
|
|
54
63
|
*/
|
|
55
64
|
stretch?: BreakpointCustomizable<boolean>;
|
|
56
65
|
/**
|
|
57
66
|
* Specifies the type of the button.
|
|
67
|
+
* @default 'submit'
|
|
58
68
|
*/
|
|
59
69
|
type?: ButtonPureType;
|
|
60
70
|
/**
|
|
61
71
|
* Shows an underline under the label.
|
|
72
|
+
* @default false
|
|
62
73
|
*/
|
|
63
74
|
underline?: boolean;
|
|
64
75
|
/**
|
|
@@ -69,10 +80,12 @@ export type PButtonPureProps = BaseProps & {
|
|
|
69
80
|
export declare const PButtonPure: import("react").ForwardRefExoticComponent<Omit<import("react").DOMAttributes<{}>, "onChange" | "onInput" | "onToggle"> & Pick<import("react").HTMLAttributes<{}>, "suppressHydrationWarning" | "autoFocus" | "className" | "dir" | "hidden" | "id" | "inert" | "lang" | "slot" | "style" | "tabIndex" | "title" | "translate" | "role"> & {
|
|
70
81
|
/**
|
|
71
82
|
* Displays the button in its active state.
|
|
83
|
+
* @default false
|
|
72
84
|
*/
|
|
73
85
|
active?: boolean;
|
|
74
86
|
/**
|
|
75
87
|
* Aligns the label.
|
|
88
|
+
* @default 'end'
|
|
76
89
|
*/
|
|
77
90
|
alignLabel?: BreakpointCustomizable<ButtonPureAlignLabel>;
|
|
78
91
|
/**
|
|
@@ -81,10 +94,12 @@ export declare const PButtonPure: import("react").ForwardRefExoticComponent<Omit
|
|
|
81
94
|
aria?: SelectedAriaAttributes<ButtonPureAriaAttribute>;
|
|
82
95
|
/**
|
|
83
96
|
* The color.
|
|
97
|
+
* @default 'primary'
|
|
84
98
|
*/
|
|
85
99
|
color?: ButtonPureColor;
|
|
86
100
|
/**
|
|
87
101
|
* Disables the button. No events will be triggered while disabled state is active.
|
|
102
|
+
* @default false
|
|
88
103
|
*/
|
|
89
104
|
disabled?: boolean;
|
|
90
105
|
/**
|
|
@@ -93,10 +108,12 @@ export declare const PButtonPure: import("react").ForwardRefExoticComponent<Omit
|
|
|
93
108
|
form?: string;
|
|
94
109
|
/**
|
|
95
110
|
* Shows or hides the label. For better accessibility, it is recommended to show the label.
|
|
111
|
+
* @default false
|
|
96
112
|
*/
|
|
97
113
|
hideLabel?: BreakpointCustomizable<boolean>;
|
|
98
114
|
/**
|
|
99
115
|
* The icon shown.
|
|
116
|
+
* @default 'arrow-right'
|
|
100
117
|
*/
|
|
101
118
|
icon?: ButtonPureIcon;
|
|
102
119
|
/**
|
|
@@ -105,6 +122,7 @@ export declare const PButtonPure: import("react").ForwardRefExoticComponent<Omit
|
|
|
105
122
|
iconSource?: string;
|
|
106
123
|
/**
|
|
107
124
|
* Disables the button and shows a loading indicator. No events will be triggered while loading state is active.
|
|
125
|
+
* @default false
|
|
108
126
|
*/
|
|
109
127
|
loading?: boolean;
|
|
110
128
|
/**
|
|
@@ -113,18 +131,22 @@ export declare const PButtonPure: import("react").ForwardRefExoticComponent<Omit
|
|
|
113
131
|
name?: string;
|
|
114
132
|
/**
|
|
115
133
|
* Size of the button.
|
|
134
|
+
* @default 'sm'
|
|
116
135
|
*/
|
|
117
136
|
size?: BreakpointCustomizable<ButtonPureSize>;
|
|
118
137
|
/**
|
|
119
138
|
* Stretches the area between icon and label to max available space.
|
|
139
|
+
* @default false
|
|
120
140
|
*/
|
|
121
141
|
stretch?: BreakpointCustomizable<boolean>;
|
|
122
142
|
/**
|
|
123
143
|
* Specifies the type of the button.
|
|
144
|
+
* @default 'submit'
|
|
124
145
|
*/
|
|
125
146
|
type?: ButtonPureType;
|
|
126
147
|
/**
|
|
127
148
|
* Shows an underline under the label.
|
|
149
|
+
* @default false
|
|
128
150
|
*/
|
|
129
151
|
underline?: boolean;
|
|
130
152
|
/**
|
|
@@ -3,6 +3,7 @@ import type { ButtonTileAlign, SelectedAriaAttributes, ButtonTileAriaAttribute,
|
|
|
3
3
|
export type PButtonTileProps = BaseProps & {
|
|
4
4
|
/**
|
|
5
5
|
* Alignment of button and description.
|
|
6
|
+
* @default 'bottom'
|
|
6
7
|
*/
|
|
7
8
|
align?: ButtonTileAlign;
|
|
8
9
|
/**
|
|
@@ -11,10 +12,12 @@ export type PButtonTileProps = BaseProps & {
|
|
|
11
12
|
aria?: SelectedAriaAttributes<ButtonTileAriaAttribute>;
|
|
12
13
|
/**
|
|
13
14
|
* Aspect ratio of the button-tile.
|
|
15
|
+
* @default '4/3'
|
|
14
16
|
*/
|
|
15
17
|
aspectRatio?: BreakpointCustomizable<ButtonTileAspectRatio>;
|
|
16
18
|
/**
|
|
17
19
|
* Displays the button-tile as compact version with description and button icon only.
|
|
20
|
+
* @default false
|
|
18
21
|
*/
|
|
19
22
|
compact?: BreakpointCustomizable<boolean>;
|
|
20
23
|
/**
|
|
@@ -23,14 +26,17 @@ export type PButtonTileProps = BaseProps & {
|
|
|
23
26
|
description: string;
|
|
24
27
|
/**
|
|
25
28
|
* Disables the button. No events will be triggered while disabled state is active.
|
|
29
|
+
* @default false
|
|
26
30
|
*/
|
|
27
31
|
disabled?: boolean;
|
|
28
32
|
/**
|
|
29
33
|
* Show gradient.
|
|
34
|
+
* @default false
|
|
30
35
|
*/
|
|
31
36
|
gradient?: boolean;
|
|
32
37
|
/**
|
|
33
38
|
* The icon shown. By choosing 'none', no icon is displayed.
|
|
39
|
+
* @default 'none'
|
|
34
40
|
*/
|
|
35
41
|
icon?: ButtonTileIcon;
|
|
36
42
|
/**
|
|
@@ -43,24 +49,29 @@ export type PButtonTileProps = BaseProps & {
|
|
|
43
49
|
label: string;
|
|
44
50
|
/**
|
|
45
51
|
* Disables the button-tile and shows a loading indicator. No events will be triggered while loading state is active.
|
|
52
|
+
* @default false
|
|
46
53
|
*/
|
|
47
54
|
loading?: boolean;
|
|
48
55
|
/**
|
|
49
56
|
* Font size of the description.
|
|
57
|
+
* @default 'medium'
|
|
50
58
|
*/
|
|
51
59
|
size?: BreakpointCustomizable<ButtonTileSize>;
|
|
52
60
|
/**
|
|
53
61
|
* Specifies the type of the button.
|
|
62
|
+
* @default 'submit'
|
|
54
63
|
*/
|
|
55
64
|
type?: ButtonTileType;
|
|
56
65
|
/**
|
|
57
66
|
* Font weight of the description.
|
|
67
|
+
* @default 'semi-bold'
|
|
58
68
|
*/
|
|
59
69
|
weight?: BreakpointCustomizable<ButtonTileWeight>;
|
|
60
70
|
};
|
|
61
71
|
export declare const PButtonTile: import("react").ForwardRefExoticComponent<Omit<import("react").DOMAttributes<{}>, "onChange" | "onInput" | "onToggle"> & Pick<import("react").HTMLAttributes<{}>, "suppressHydrationWarning" | "autoFocus" | "className" | "dir" | "hidden" | "id" | "inert" | "lang" | "slot" | "style" | "tabIndex" | "title" | "translate" | "role"> & {
|
|
62
72
|
/**
|
|
63
73
|
* Alignment of button and description.
|
|
74
|
+
* @default 'bottom'
|
|
64
75
|
*/
|
|
65
76
|
align?: ButtonTileAlign;
|
|
66
77
|
/**
|
|
@@ -69,10 +80,12 @@ export declare const PButtonTile: import("react").ForwardRefExoticComponent<Omit
|
|
|
69
80
|
aria?: SelectedAriaAttributes<ButtonTileAriaAttribute>;
|
|
70
81
|
/**
|
|
71
82
|
* Aspect ratio of the button-tile.
|
|
83
|
+
* @default '4/3'
|
|
72
84
|
*/
|
|
73
85
|
aspectRatio?: BreakpointCustomizable<ButtonTileAspectRatio>;
|
|
74
86
|
/**
|
|
75
87
|
* Displays the button-tile as compact version with description and button icon only.
|
|
88
|
+
* @default false
|
|
76
89
|
*/
|
|
77
90
|
compact?: BreakpointCustomizable<boolean>;
|
|
78
91
|
/**
|
|
@@ -81,14 +94,17 @@ export declare const PButtonTile: import("react").ForwardRefExoticComponent<Omit
|
|
|
81
94
|
description: string;
|
|
82
95
|
/**
|
|
83
96
|
* Disables the button. No events will be triggered while disabled state is active.
|
|
97
|
+
* @default false
|
|
84
98
|
*/
|
|
85
99
|
disabled?: boolean;
|
|
86
100
|
/**
|
|
87
101
|
* Show gradient.
|
|
102
|
+
* @default false
|
|
88
103
|
*/
|
|
89
104
|
gradient?: boolean;
|
|
90
105
|
/**
|
|
91
106
|
* The icon shown. By choosing 'none', no icon is displayed.
|
|
107
|
+
* @default 'none'
|
|
92
108
|
*/
|
|
93
109
|
icon?: ButtonTileIcon;
|
|
94
110
|
/**
|
|
@@ -101,18 +117,22 @@ export declare const PButtonTile: import("react").ForwardRefExoticComponent<Omit
|
|
|
101
117
|
label: string;
|
|
102
118
|
/**
|
|
103
119
|
* Disables the button-tile and shows a loading indicator. No events will be triggered while loading state is active.
|
|
120
|
+
* @default false
|
|
104
121
|
*/
|
|
105
122
|
loading?: boolean;
|
|
106
123
|
/**
|
|
107
124
|
* Font size of the description.
|
|
125
|
+
* @default 'medium'
|
|
108
126
|
*/
|
|
109
127
|
size?: BreakpointCustomizable<ButtonTileSize>;
|
|
110
128
|
/**
|
|
111
129
|
* Specifies the type of the button.
|
|
130
|
+
* @default 'submit'
|
|
112
131
|
*/
|
|
113
132
|
type?: ButtonTileType;
|
|
114
133
|
/**
|
|
115
134
|
* Font weight of the description.
|
|
135
|
+
* @default 'semi-bold'
|
|
116
136
|
*/
|
|
117
137
|
weight?: BreakpointCustomizable<ButtonTileWeight>;
|
|
118
138
|
} & {
|
|
@@ -7,10 +7,12 @@ export type PButtonProps = BaseProps & {
|
|
|
7
7
|
aria?: SelectedAriaAttributes<ButtonAriaAttribute>;
|
|
8
8
|
/**
|
|
9
9
|
* Displays the button in compact mode.
|
|
10
|
+
* @default false
|
|
10
11
|
*/
|
|
11
12
|
compact?: BreakpointCustomizable<boolean>;
|
|
12
13
|
/**
|
|
13
14
|
* Disables the button. No events will be triggered while disabled state is active.
|
|
15
|
+
* @default false
|
|
14
16
|
*/
|
|
15
17
|
disabled?: boolean;
|
|
16
18
|
/**
|
|
@@ -19,10 +21,12 @@ export type PButtonProps = BaseProps & {
|
|
|
19
21
|
form?: string;
|
|
20
22
|
/**
|
|
21
23
|
* Shows or hides the label. For better accessibility, it is recommended to show the label.
|
|
24
|
+
* @default false
|
|
22
25
|
*/
|
|
23
26
|
hideLabel?: BreakpointCustomizable<boolean>;
|
|
24
27
|
/**
|
|
25
28
|
* The icon shown. By choosing 'none', no icon is displayed.
|
|
29
|
+
* @default 'none'
|
|
26
30
|
*/
|
|
27
31
|
icon?: ButtonIcon;
|
|
28
32
|
/**
|
|
@@ -31,6 +35,7 @@ export type PButtonProps = BaseProps & {
|
|
|
31
35
|
iconSource?: string;
|
|
32
36
|
/**
|
|
33
37
|
* Disables the button and shows a loading indicator. No events will be triggered while loading state is active.
|
|
38
|
+
* @default false
|
|
34
39
|
*/
|
|
35
40
|
loading?: boolean;
|
|
36
41
|
/**
|
|
@@ -39,6 +44,7 @@ export type PButtonProps = BaseProps & {
|
|
|
39
44
|
name?: string;
|
|
40
45
|
/**
|
|
41
46
|
* Specifies the type of the button.
|
|
47
|
+
* @default 'submit'
|
|
42
48
|
*/
|
|
43
49
|
type?: ButtonType;
|
|
44
50
|
/**
|
|
@@ -47,6 +53,7 @@ export type PButtonProps = BaseProps & {
|
|
|
47
53
|
value?: string;
|
|
48
54
|
/**
|
|
49
55
|
* The style variant of the button.
|
|
56
|
+
* @default 'primary'
|
|
50
57
|
*/
|
|
51
58
|
variant?: ButtonVariant;
|
|
52
59
|
};
|
|
@@ -57,10 +64,12 @@ export declare const PButton: import("react").ForwardRefExoticComponent<Omit<imp
|
|
|
57
64
|
aria?: SelectedAriaAttributes<ButtonAriaAttribute>;
|
|
58
65
|
/**
|
|
59
66
|
* Displays the button in compact mode.
|
|
67
|
+
* @default false
|
|
60
68
|
*/
|
|
61
69
|
compact?: BreakpointCustomizable<boolean>;
|
|
62
70
|
/**
|
|
63
71
|
* Disables the button. No events will be triggered while disabled state is active.
|
|
72
|
+
* @default false
|
|
64
73
|
*/
|
|
65
74
|
disabled?: boolean;
|
|
66
75
|
/**
|
|
@@ -69,10 +78,12 @@ export declare const PButton: import("react").ForwardRefExoticComponent<Omit<imp
|
|
|
69
78
|
form?: string;
|
|
70
79
|
/**
|
|
71
80
|
* Shows or hides the label. For better accessibility, it is recommended to show the label.
|
|
81
|
+
* @default false
|
|
72
82
|
*/
|
|
73
83
|
hideLabel?: BreakpointCustomizable<boolean>;
|
|
74
84
|
/**
|
|
75
85
|
* The icon shown. By choosing 'none', no icon is displayed.
|
|
86
|
+
* @default 'none'
|
|
76
87
|
*/
|
|
77
88
|
icon?: ButtonIcon;
|
|
78
89
|
/**
|
|
@@ -81,6 +92,7 @@ export declare const PButton: import("react").ForwardRefExoticComponent<Omit<imp
|
|
|
81
92
|
iconSource?: string;
|
|
82
93
|
/**
|
|
83
94
|
* Disables the button and shows a loading indicator. No events will be triggered while loading state is active.
|
|
95
|
+
* @default false
|
|
84
96
|
*/
|
|
85
97
|
loading?: boolean;
|
|
86
98
|
/**
|
|
@@ -89,6 +101,7 @@ export declare const PButton: import("react").ForwardRefExoticComponent<Omit<imp
|
|
|
89
101
|
name?: string;
|
|
90
102
|
/**
|
|
91
103
|
* Specifies the type of the button.
|
|
104
|
+
* @default 'submit'
|
|
92
105
|
*/
|
|
93
106
|
type?: ButtonType;
|
|
94
107
|
/**
|
|
@@ -97,6 +110,7 @@ export declare const PButton: import("react").ForwardRefExoticComponent<Omit<imp
|
|
|
97
110
|
value?: string;
|
|
98
111
|
/**
|
|
99
112
|
* The style variant of the button.
|
|
113
|
+
* @default 'primary'
|
|
100
114
|
*/
|
|
101
115
|
variant?: ButtonVariant;
|
|
102
116
|
} & {
|