@porsche-design-system/components-react 2.16.3-rc.0 → 2.17.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +16 -0
- package/LICENSE +3 -3
- package/esm/public-api.js +19 -5
- package/hooks.d.ts +0 -1
- package/jsdom-polyfill/index.js +1 -1
- package/lib/components/index.d.ts +1 -0
- package/lib/components/link-tile.wrapper.d.ts +112 -0
- package/lib/types.d.ts +23 -0
- package/package.json +2 -2
- package/provider.d.ts +1 -4
- package/public-api.js +19 -4
package/CHANGELOG.md
CHANGED
|
@@ -9,6 +9,22 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
|
9
9
|
|
|
10
10
|
### [Unreleased]
|
|
11
11
|
|
|
12
|
+
### [2.17.0-rc.0] - 2022-10-31
|
|
13
|
+
|
|
14
|
+
#### Added
|
|
15
|
+
|
|
16
|
+
- `Link Tile`
|
|
17
|
+
|
|
18
|
+
#### Fixed
|
|
19
|
+
|
|
20
|
+
- `Scroller` bug where scrollable content was not fully hidden by the gradient, when zoomed into the page.
|
|
21
|
+
|
|
22
|
+
#### Changed
|
|
23
|
+
|
|
24
|
+
- Removed `!important` keyword from css property `display` of `Link Pure` and `Button Pure`
|
|
25
|
+
|
|
26
|
+
### [2.16.3] - 2022-10-21
|
|
27
|
+
|
|
12
28
|
### [2.16.3-rc.0] - 2022-10-21
|
|
13
29
|
|
|
14
30
|
#### Fixed
|
package/LICENSE
CHANGED
|
@@ -25,10 +25,10 @@ License Restrictions
|
|
|
25
25
|
You may not use the Porsche Design System Assets (i) to develop, test, or distribute an external, stand-alone Application (“External Application”) unless such External Application is not identical to and is dissimilar and visually distinct from Porsche products and services, as determined by Porsche in its sole discretion, (ii) to mislead consumers as to Porsche’s sponsorship of, affiliation with, or endorsement of you, your organization, or your Application, and (iii) for any purpose not expressly permitted by this License Agreement. For clarity, any Application that embeds directly inside the Porsche Admin or other Porsche interface that allows for the embedding of Applications (“Embedded Application”), as determined by Porsche in its sole discretion, may be visually similar, but not identical, to Porsche products and services. You may not modify, adapt, redistribute, or create derivative works of the Porsche Design System Assets or any part of the Porsche Design System Assets.
|
|
26
26
|
|
|
27
27
|
Ownership of Intellectual Property
|
|
28
|
-
You agree that Porsche owns all legal right, title and interest in and to the Porsche products and services, including the Porsche Design System and the Porsche Design System Assets, including any Intellectual Property Rights inherent therein and related thereto. “Intellectual Property Rights” means any and all rights under patent law, copyright law, trade secret law, trademark law, and any and all other proprietary rights.
|
|
28
|
+
You agree that Porsche owns all legal right, title and interest in and to the Porsche products and services, including the Porsche Design System and the Porsche Design System Assets, including any Intellectual Property Rights inherent therein and related thereto. “Intellectual Property Rights” means any and all rights under patent law, copyright law, trade secret law, trademark law, and any and all other proprietary rights. Porsche reserves all rights not expressly granted to you.
|
|
29
29
|
|
|
30
30
|
Termination
|
|
31
|
-
Porsche may terminate this Agreement: (a) if you breach any of the terms of this Agreement or (b) if
|
|
31
|
+
Porsche may terminate this Agreement: (a) if you breach any of the terms of this Agreement or (b) if Porsche ceases to make the Porsche Design System Assets generally available. Either party may terminate this Agreement at any time, with or without cause. Upon termination, your Porsche Design System Assets license will also terminate. This means that you must cease using the Porsche Design System Assets and delete all copies of the Porsche Design System Assets. All terms of this Agreement will survive the termination or expiration of this Agreement, except for your license right granted in Section 1.
|
|
32
32
|
|
|
33
33
|
No Warranty
|
|
34
34
|
THE Porsche Design System Assets ARE PROVIDED “AS IS” AND “WITH ALL FAULTS”. PORSCHE AND ITS THIRD PARTY LICENSORS DISCLAIM ALL REPRESENTATIONS, WARRANTIES AND GUARANTEES, WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING IMPLIED WARRANTIES OF MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR ANY PURPOSE. PORSCHE MAKES NO REPRESENTATION, WARRANTY OR GUARANTEE RELATED TO RELIABILITY, ACCURACY, OR COMPLETENESS OF THE Porsche Design System Assets OR THAT YOUR USE OF THE Porsche Design System Assets WILL BE SECURE, TIMELY, UNINTERRUPTED OR ERROR-FREE. THE Porsche Design System Assets MAY NOT MEET YOUR REQUIREMENTS OR EXPECTATIONS.
|
|
@@ -51,7 +51,7 @@ The failure of either party to insist upon or enforce strict performance by the
|
|
|
51
51
|
This Agreement, including all guidelines and other documents linked or otherwise incorporated or referenced herein, sets forth the entire agreement and supersedes any and all prior agreements, written or oral, of the parties with respect to the subject matter hereof (including any prior version of this Agreement).
|
|
52
52
|
|
|
53
53
|
4. Assignment
|
|
54
|
-
All the terms and provisions of this Agreement shall be binding upon and inure to the benefit of the parties to the Agreement and to their respective heirs, successors, permitted assigns and legal representatives.
|
|
54
|
+
All the terms and provisions of this Agreement shall be binding upon and inure to the benefit of the parties to the Agreement and to their respective heirs, successors, permitted assigns and legal representatives. Porsche shall be permitted to assign this Agreement without notice to or consent from you. You shall have no right to assign or otherwise transfer the Agreement, or any of your rights or obligations hereunder, to any third party without Porsche’s prior written consent, to be given or withheld in Porsche’s sole discretion.
|
|
55
55
|
|
|
56
56
|
5. Applicable Law
|
|
57
57
|
This Agreement will be governed by and construed in accordance with the laws of Germany, excluding conflicts of law rules and principles. Each party submits to the personal and exclusive jurisdiction of the courts located in Stuttgart, Germany. Nothing in this Agreement limits Porsche’s rights to seek equitable relief.
|
package/esm/public-api.js
CHANGED
|
@@ -6,14 +6,12 @@ import { createContext, useEffect, useContext, useRef, useMemo, useLayoutEffect,
|
|
|
6
6
|
// to warn users about missing PorscheDesignSystemProvider, we set the default values as undefined
|
|
7
7
|
const PorscheDesignSystemContext = createContext({
|
|
8
8
|
prefix: undefined,
|
|
9
|
-
usesSkeletons: undefined,
|
|
10
9
|
});
|
|
11
|
-
const
|
|
12
|
-
const PorscheDesignSystemProvider = ({ prefix = '', usesSkeletons = hasSkeleton(), ...props }) => {
|
|
10
|
+
const PorscheDesignSystemProvider = ({ prefix = '', ...props }) => {
|
|
13
11
|
useEffect(() => {
|
|
14
12
|
load({ prefix });
|
|
15
13
|
}, [prefix]);
|
|
16
|
-
return jsx(PorscheDesignSystemContext.Provider, { value: { prefix
|
|
14
|
+
return jsx(PorscheDesignSystemContext.Provider, { value: { prefix }, ...props });
|
|
17
15
|
};
|
|
18
16
|
|
|
19
17
|
const splitToArray = (str) => str.split(' ').filter((str) => str);
|
|
@@ -423,6 +421,22 @@ const PLinkSocial = /*#__PURE__*/ forwardRef(({ hideLabel = false, href, icon, i
|
|
|
423
421
|
return jsx(Tag, { ...props });
|
|
424
422
|
});
|
|
425
423
|
|
|
424
|
+
const PLinkTile = /*#__PURE__*/ forwardRef(({ align = 'bottom', aria, aspectRatio = '4:3', compact = false, description, download, gradient = true, href, label, rel, size = 'default', target = '_self', weight = 'semibold', className, ...rest }, ref) => {
|
|
425
|
+
const elementRef = useRef();
|
|
426
|
+
const Tag = usePrefix('p-link-tile');
|
|
427
|
+
const propsToSync = [align, aria, aspectRatio, compact, description, download, gradient, href, label, rel, size, target, weight];
|
|
428
|
+
useBrowserLayoutEffect(() => {
|
|
429
|
+
const { current } = elementRef;
|
|
430
|
+
['align', 'aria', 'aspectRatio', 'compact', 'description', 'download', 'gradient', 'href', 'label', 'rel', 'size', 'target', 'weight'].forEach((propName, i) => (current[propName] = propsToSync[i]));
|
|
431
|
+
}, propsToSync);
|
|
432
|
+
const props = {
|
|
433
|
+
...rest,
|
|
434
|
+
class: useMergedClass(elementRef, className),
|
|
435
|
+
ref: syncRef(elementRef, ref)
|
|
436
|
+
};
|
|
437
|
+
return jsx(Tag, { ...props });
|
|
438
|
+
});
|
|
439
|
+
|
|
426
440
|
const PMarque = /*#__PURE__*/ forwardRef(({ aria, href, size = 'responsive', target = '_self', trademark = true, className, ...rest }, ref) => {
|
|
427
441
|
const elementRef = useRef();
|
|
428
442
|
const Tag = usePrefix('p-marque');
|
|
@@ -895,4 +909,4 @@ const PToast = /*#__PURE__*/ forwardRef(({ theme = 'light', className, ...rest }
|
|
|
895
909
|
return jsx(Tag, { ...props });
|
|
896
910
|
});
|
|
897
911
|
|
|
898
|
-
export { PAccordion, PBanner, PButton, PButtonGroup, PButtonPure, PCarousel, PCheckboxWrapper, PContentWrapper, PDivider, PFieldsetWrapper, PFlex, PFlexItem, PGrid, PGridItem, PHeadline, PIcon, PInlineNotification, PLink, PLinkPure, PLinkSocial, PMarque, PModal, PPagination, PPopover, PRadioButtonWrapper, PScroller, PSegmentedControl, PSegmentedControlItem, PSelectWrapper, PSpinner, PStepperHorizontal, PStepperHorizontalItem, PSwitch, PTable, PTableBody, PTableCell, PTableHead, PTableHeadCell, PTableHeadRow, PTableRow, PTabs, PTabsBar, PTabsItem, PTag, PTagDismissible, PText, PTextFieldWrapper, PTextList, PTextListItem, PTextareaWrapper, PToast, PorscheDesignSystemProvider, skipCheckForPorscheDesignSystemProviderDuringTests, skipPorscheDesignSystemCDNRequestsDuringTests, useToastManager };
|
|
912
|
+
export { PAccordion, PBanner, PButton, PButtonGroup, PButtonPure, PCarousel, PCheckboxWrapper, PContentWrapper, PDivider, PFieldsetWrapper, PFlex, PFlexItem, PGrid, PGridItem, PHeadline, PIcon, PInlineNotification, PLink, PLinkPure, PLinkSocial, PLinkTile, PMarque, PModal, PPagination, PPopover, PRadioButtonWrapper, PScroller, PSegmentedControl, PSegmentedControlItem, PSelectWrapper, PSpinner, PStepperHorizontal, PStepperHorizontalItem, PSwitch, PTable, PTableBody, PTableCell, PTableHead, PTableHeadCell, PTableHeadRow, PTableRow, PTabs, PTabsBar, PTabsItem, PTag, PTagDismissible, PText, PTextFieldWrapper, PTextList, PTextListItem, PTextareaWrapper, PToast, PorscheDesignSystemProvider, skipCheckForPorscheDesignSystemProviderDuringTests, skipPorscheDesignSystemCDNRequestsDuringTests, useToastManager };
|
package/hooks.d.ts
CHANGED
|
@@ -7,7 +7,6 @@ import type { ToastMessage } from './lib/types';
|
|
|
7
7
|
*/
|
|
8
8
|
export declare const skipCheckForPorscheDesignSystemProviderDuringTests: () => void;
|
|
9
9
|
export declare const usePrefix: (tagName: string) => string;
|
|
10
|
-
export declare const useSkeleton: () => boolean;
|
|
11
10
|
export declare const useEventCallback: (ref: MutableRefObject<HTMLElement>, eventName: string, eventHandler: (e: Event) => void) => void;
|
|
12
11
|
export declare const useMergedClass: (ref: MutableRefObject<HTMLElement>, className: string) => string;
|
|
13
12
|
export declare const useBrowserLayoutEffect: typeof useEffect;
|